/openssl/crypto/stack/ |
H A D | stack.c | 273 st->data[st->num] = data; in OPENSSL_sk_insert() 324 if (st == NULL || st->num == 0) in internal_find() 362 r = ossl_bsearch(&data, st->data, st->num, sizeof(void *), st->comp, in internal_find() 411 if (st == NULL || st->num == 0) in OPENSSL_sk_shift() 418 if (st == NULL || st->num == 0) in OPENSSL_sk_pop() 425 if (st == NULL || st->num == 0) in OPENSSL_sk_zero() 427 memset(st->data, 0, sizeof(*st->data) * st->num); in OPENSSL_sk_zero() 453 return st == NULL ? -1 : st->num; in OPENSSL_sk_num() 481 if (st != NULL && !st->sorted && st->comp != NULL) { in OPENSSL_sk_sort() 483 qsort(st->data, st->num, sizeof(void *), st->comp); in OPENSSL_sk_sort() [all …]
|
/openssl/crypto/ |
H A D | self_test_core.c | 79 if (st->cb != NULL) { in self_test_setparams() 80 st->params[n++] = in self_test_setparams() 111 OPENSSL_free(st); in OSSL_SELF_TEST_free() 118 if (st != NULL && st->cb != NULL) { in OSSL_SELF_TEST_onbegin() 120 st->type = type; in OSSL_SELF_TEST_onbegin() 123 (void)st->cb(st->params, st->cb_arg); in OSSL_SELF_TEST_onbegin() 133 if (st != NULL && st->cb != NULL) { in OSSL_SELF_TEST_onend() 134 st->phase = in OSSL_SELF_TEST_onend() 137 (void)st->cb(st->params, st->cb_arg); in OSSL_SELF_TEST_onend() 155 if (st != NULL && st->cb != NULL) { in OSSL_SELF_TEST_oncorrupt_byte() [all …]
|
/openssl/crypto/poly1305/ |
H A D | poly1305_ieee754.c | 170 st->s[0] = st->r[2] * (5.0/TWO130); in poly1305_init() 171 st->s[2] = st->r[4] * (5.0/TWO130); in poly1305_init() 172 st->s[4] = st->r[6] * (5.0/TWO130); in poly1305_init() 177 st->r[1] = (st->r[0] + TWO(52)*TWO(16)*TWO0) - in poly1305_init() 179 st->r[0] -= st->r[1]; in poly1305_init() 183 st->r[2] -= st->r[3]; in poly1305_init() 187 st->r[4] -= st->r[5]; in poly1305_init() 191 st->r[6] -= st->r[7]; in poly1305_init() 195 st->s[0] -= st->s[1]; in poly1305_init() 199 st->s[2] -= st->s[3]; in poly1305_init() [all …]
|
H A D | poly1305_base2_44.c | 63 st->h[0] = 0; in poly1305_init() 64 st->h[1] = 0; in poly1305_init() 65 st->h[2] = 0; in poly1305_init() 75 st->s[0] = (st->r[1] + (st->r[1] << 2)) << 2; in poly1305_init() 76 st->s[1] = (st->r[2] + (st->r[2] << 2)) << 2; in poly1305_init() 91 r0 = st->r[0]; in poly1305_blocks() 92 r1 = st->r[1]; in poly1305_blocks() 93 r2 = st->r[2]; in poly1305_blocks() 95 s1 = st->s[0]; in poly1305_blocks() 96 s2 = st->s[1]; in poly1305_blocks() [all …]
|
H A D | poly1305.c | 138 st->h[0] = 0; in poly1305_init() 139 st->h[1] = 0; in poly1305_init() 140 st->h[2] = 0; in poly1305_init() 156 r0 = st->r[0]; in poly1305_blocks() 157 r1 = st->r[1]; in poly1305_blocks() 161 h0 = st->h[0]; in poly1305_blocks() 276 st->h[0] = 0; in poly1305_init() 277 st->h[1] = 0; in poly1305_init() 278 st->h[2] = 0; in poly1305_init() 279 st->h[3] = 0; in poly1305_init() [all …]
|
/openssl/include/openssl/ |
H A D | stack.h | 37 int OPENSSL_sk_reserve(OPENSSL_STACK *st, int n); 44 void *OPENSSL_sk_delete(OPENSSL_STACK *st, int loc); 46 int OPENSSL_sk_find(OPENSSL_STACK *st, const void *data); 47 int OPENSSL_sk_find_ex(OPENSSL_STACK *st, const void *data); 49 int OPENSSL_sk_push(OPENSSL_STACK *st, const void *data); 51 void *OPENSSL_sk_shift(OPENSSL_STACK *st); 52 void *OPENSSL_sk_pop(OPENSSL_STACK *st); 53 void OPENSSL_sk_zero(OPENSSL_STACK *st); 56 OPENSSL_STACK *OPENSSL_sk_dup(const OPENSSL_STACK *st); 57 void OPENSSL_sk_sort(OPENSSL_STACK *st); [all …]
|
/openssl/ssl/statem/ |
H A D | statem.c | 358 OSSL_STATEM *st = &s->statem; in state_machine() local 374 st->in_handshake++; in state_machine() 511 st->in_handshake--; in state_machine() 539 OSSL_STATEM *st = &s->statem; in init_read_state_machine() local 587 OSSL_STATEM *st = &s->statem; in read_state_machine() local 618 switch (st->read_state) { in read_state_machine() 715 st->read_state_work = post_process_message(s, st->read_state_work); in read_state_machine() 750 OSSL_STATEM *st = &s->statem; in statem_do_write() local 768 OSSL_STATEM *st = &s->statem; in init_write_state_machine() local 862 switch (st->write_state_work = pre_work(s, st->write_state_work)) { in write_state_machine() [all …]
|
H A D | statem_srvr.c | 69 OSSL_STATEM *st = &s->statem; in ossl_statem_server13_read_transition() local 76 switch (st->hand_state) { in ossl_statem_server13_read_transition() 192 switch (st->hand_state) { in ossl_statem_server_read_transition() 476 switch (st->hand_state) { in ossl_statem_server13_write_transition() 618 switch (st->hand_state) { in ossl_statem_server_write_transition() 751 switch (st->hand_state) { in ossl_statem_server_pre_work() 881 switch (st->hand_state) { in ossl_statem_server_post_work() 1098 switch (st->hand_state) { in ossl_statem_server_construct_message() 1223 switch (st->hand_state) { in ossl_statem_server_max_message_size() 1268 switch (st->hand_state) { in ossl_statem_server_process_message() [all …]
|
H A D | statem_clnt.c | 99 OSSL_STATEM *st = &s->statem; in ossl_statem_client13_read_transition() local 107 switch (st->hand_state) { in ossl_statem_client13_read_transition() 245 switch (st->hand_state) { in ossl_statem_client_read_transition() 449 switch (st->hand_state) { in ossl_statem_client13_write_transition() 554 switch (st->hand_state) { in ossl_statem_client_write_transition() 717 switch (st->hand_state) { in ossl_statem_client_pre_work() 801 switch (st->hand_state) { in ossl_statem_client_post_work() 942 switch (st->hand_state) { in ossl_statem_client_construct_message() 1021 switch (st->hand_state) { in ossl_statem_client_max_message_size() 1084 switch (st->hand_state) { in ossl_statem_client_process_message() [all …]
|
/openssl/test/ |
H A D | ssl_handshake_rtt_test.c | 51 OSSL_STATEM *st = NULL; in test_handshake_rtt() local 80 st->hand_state = TLS_ST_CW_CLNT_HELLO; in test_handshake_rtt() 83 st->hand_state = TLS_ST_CR_SRVR_DONE; in test_handshake_rtt() 87 st->hand_state = TLS_ST_SW_SRVR_DONE; in test_handshake_rtt() 90 st->hand_state = TLS_ST_SR_FINISHED; in test_handshake_rtt() 94 st->hand_state = TLS_ST_CW_CLNT_HELLO; in test_handshake_rtt() 97 st->hand_state = TLS_ST_CR_SRVR_DONE; in test_handshake_rtt() 101 st->hand_state = TLS_ST_SW_SRVR_DONE; in test_handshake_rtt() 104 st->hand_state = TLS_ST_SR_FINISHED; in test_handshake_rtt() 108 st->hand_state = TLS_ST_EARLY_DATA; in test_handshake_rtt() [all …]
|
H A D | bntest.c | 124 st = 1; in getint() 127 return st; in getint() 230 st = 1; in test_swap() 268 st = 1; in test_sub() 311 st = 1; in test_div_recip() 418 st = 1; in test_mod() 719 st = 1; in test_modexp_mont5() 761 st = 1; in test_gf2m_add() 798 st = 1; in test_gf2m_mod() 847 st = 1; in test_gf2m_mul() [all …]
|
H A D | exdatatest.c | 130 int st; member 140 obj->st = CRYPTO_new_ex_data(CRYPTO_EX_INDEX_APP, obj, &obj->ex_data); in MYOBJ_new() 147 obj->st = CRYPTO_set_ex_data(&obj->ex_data, saved_idx, cp); in MYOBJ_sethello() 148 if (!TEST_int_eq(obj->st, 1)) in MYOBJ_sethello() 164 obj->st = gbl_result = 0; in MYOBJ_sethello2() 174 obj->st = gbl_result = 0; in MYOBJ_gethello2() 188 obj->st = gbl_result = 0; in MYOBJ_allochello3() 198 obj->st = gbl_result = 0; in MYOBJ_gethello3() 215 obj->st |= CRYPTO_dup_ex_data(CRYPTO_EX_INDEX_APP, &obj->ex_data, in MYOBJ_dup() 243 if (!TEST_int_eq(t1->st, 1) || !TEST_int_eq(t2->st, 1)) in test_exdata() [all …]
|
/openssl/crypto/bn/ |
H A D | bn_ctx.c | 250 st->indexes = NULL; in BN_STACK_init() 251 st->depth = st->size = 0; in BN_STACK_init() 256 OPENSSL_free(st->indexes); in BN_STACK_finish() 257 st->indexes = NULL; in BN_STACK_finish() 263 if (st->depth == st->size) { in BN_STACK_push() 266 st->size ? (st->size * 3 / 2) : BN_CTX_START_FRAMES; in BN_STACK_push() 271 if (st->depth) in BN_STACK_push() 272 memcpy(newitems, st->indexes, sizeof(*newitems) * st->depth); in BN_STACK_push() 275 st->size = newsize; in BN_STACK_push() 277 st->indexes[(st->depth)++] = idx; in BN_STACK_push() [all …]
|
/openssl/providers/fips/ |
H A D | self_test_kats.c | 47 OSSL_SELF_TEST_oncorrupt_byte(st, out); in self_test_digest() 56 OSSL_SELF_TEST_onend(st, ok); in self_test_digest() 153 OSSL_SELF_TEST_onend(st, ret); in self_test_cipher() 253 OSSL_SELF_TEST_onend(st, ret); in self_test_kdf() 364 OSSL_SELF_TEST_onend(st, ret); in self_test_drbg() 444 OSSL_SELF_TEST_onend(st, ret); in self_test_ka() 559 OSSL_SELF_TEST_onend(st, ret); in self_test_digest_sign() 798 if (!self_test_digests(st, libctx)) in SELF_TEST_kats() 804 if (!self_test_kdfs(st, libctx)) in SELF_TEST_kats() 806 if (!self_test_drbgs(st, libctx)) in SELF_TEST_kats() [all …]
|
H A D | self_test.c | 305 int SELF_TEST_post(SELF_TEST_POST_PARAMS *st, int on_demand_test) in SELF_TEST_post() argument 348 if (st == NULL in SELF_TEST_post() 349 || st->module_checksum_data == NULL) { in SELF_TEST_post() 354 ev = OSSL_SELF_TEST_new(st->cb, st->cb_arg); in SELF_TEST_post() 358 module_checksum = OPENSSL_hexstr2buf(st->module_checksum_data, in SELF_TEST_post() 364 bio_module = (*st->bio_new_file_cb)(st->module_filename, "rb"); in SELF_TEST_post() 368 || !verify_integrity(bio_module, st->bio_read_ex_cb, in SELF_TEST_post() 375 if (!SELF_TEST_kats(ev, st->libctx)) { in SELF_TEST_post() 381 rng = ossl_rand_get0_private_noncreating(st->libctx); in SELF_TEST_post() 396 if (st != NULL) in SELF_TEST_post() [all …]
|
/openssl/crypto/dsa/ |
H A D | dsa_key.c | 79 OSSL_SELF_TEST *st = NULL; in dsa_keygen_knownanswer_test() local 86 st = OSSL_SELF_TEST_new(cb, cbarg); in dsa_keygen_knownanswer_test() 87 if (st == NULL) in dsa_keygen_knownanswer_test() 104 OSSL_SELF_TEST_onend(st, ret); in dsa_keygen_knownanswer_test() 105 OSSL_SELF_TEST_free(st); in dsa_keygen_knownanswer_test() 120 OSSL_SELF_TEST *st = NULL; in dsa_keygen_pairwise_test() local 122 st = OSSL_SELF_TEST_new(cb, cbarg); in dsa_keygen_pairwise_test() 123 if (st == NULL) in dsa_keygen_pairwise_test() 133 OSSL_SELF_TEST_oncorrupt_byte(st, dgst); in dsa_keygen_pairwise_test() 140 OSSL_SELF_TEST_onend(st, ret); in dsa_keygen_pairwise_test() [all …]
|
/openssl/crypto/aes/ |
H A D | aes_local.h | 21 # define PUTU32(ct, st) { *((u32 *)(ct)) = SWAP((st)); } argument 24 # define PUTU32(ct, st) { (ct)[0] = (u8)((st) >> 24); (ct)[1] = (u8)((st) >> 16); (ct)[2] = (u8)((… argument
|
/openssl/apps/ |
H A D | testdsa.h | 202 #define set_dsa_ptr(st, bits) \ argument 204 st.priv = dsa##bits##_priv; \ 205 st.pub = dsa##bits##_pub; \ 206 st.p = dsa##bits##_p; \ 207 st.g = dsa##bits##_g; \ 208 st.q = dsa##bits##_q; \ 209 st.priv_l = sizeof(dsa##bits##_priv); \ 210 st.pub_l = sizeof(dsa##bits##_pub); \ 211 st.p_l = sizeof(dsa##bits##_p); \ 212 st.g_l = sizeof(dsa##bits##_g); \ [all …]
|
/openssl/doc/man3/ |
H A D | SSL_CTX_set1_verify_cert_store.pod | 17 int SSL_CTX_set0_verify_cert_store(SSL_CTX *ctx, X509_STORE *st); 18 int SSL_CTX_set1_verify_cert_store(SSL_CTX *ctx, X509_STORE *st); 19 int SSL_CTX_set0_chain_cert_store(SSL_CTX *ctx, X509_STORE *st); 20 int SSL_CTX_set1_chain_cert_store(SSL_CTX *ctx, X509_STORE *st); 24 int SSL_set0_verify_cert_store(SSL *ctx, X509_STORE *st); 25 int SSL_set1_verify_cert_store(SSL *ctx, X509_STORE *st); 26 int SSL_set0_chain_cert_store(SSL *ctx, X509_STORE *st); 27 int SSL_set1_chain_cert_store(SSL *ctx, X509_STORE *st); 28 int SSL_get0_verify_cert_store(SSL *ctx, X509_STORE **st); 29 int SSL_get0_chain_cert_store(SSL *ctx, X509_STORE **st); [all …]
|
H A D | OSSL_SELF_TEST_new.pod | 16 void OSSL_SELF_TEST_free(OSSL_SELF_TEST *st); 18 void OSSL_SELF_TEST_onbegin(OSSL_SELF_TEST *st, const char *type, 21 void OSSL_SELF_TEST_onend(OSSL_SELF_TEST *st, int ret); 44 =item "st-phase" (B<OSSL_PROV_PARAM_SELF_TEST_PHASE>) <UTF8 string> 91 =item "st-type" (B<OSSL_PROV_PARAM_SELF_TEST_TYPE>) <UTF8 string> 96 =item "st-desc" (B<OSSL_PROV_PARAM_SELF_TEST_DESC>) <UTF8 string> 115 OSSL_SELF_TEST *st = NULL; 130 st = OSSL_SELF_TEST_new(cb, cb_arg); 133 OSSL_SELF_TEST_onbegin(st, OSSL_SELF_TEST_TYPE_KAT_DIGEST, 142 OSSL_SELF_TEST_oncorrupt_byte(st, out); [all …]
|
/openssl/demos/smime/ |
H A D | smver.c | 18 X509_STORE *st = NULL; in main() local 28 st = X509_STORE_new(); in main() 29 if (st == NULL) in main() 43 if (!X509_STORE_add_cert(st, cacert)) in main() 64 if (!PKCS7_verify(p7, NULL, st, cont, out, 0)) { in main() 78 X509_STORE_free(st); in main()
|
/openssl/crypto/bn/asm/ |
H A D | sparcv8.S | 67 st %o4,[%o0] 78 st %o4,[%o0+4] 89 st %o4,[%o0+8] 99 st %o4,[%o0-4] 123 st %o4,[%o0] 178 st %g2,[%o0] 222 st %g2,[%o0] 267 st %o4,[%o0] 305 st %o4,[%o0] 377 st %o5,[%o0] [all …]
|
/openssl/fuzz/ |
H A D | test-corpus.c | 39 struct stat st; in testfile() local 44 if (stat(pathname, &st) < 0 || !S_ISREG(st.st_mode)) in testfile() 51 buf = malloc(st.st_size); in testfile() 53 s = fread(buf, 1, st.st_size, f); in testfile() 54 OPENSSL_assert(s == (size_t)st.st_size); in testfile()
|
/openssl/crypto/hpke/ |
H A D | hpke_util.c | 454 char *st = NULL, *instrcp = NULL; in ossl_hpke_str2suite() local 476 for (st = (char *)suitestr; *st != '\0'; st++) { in ossl_hpke_str2suite() 477 if (*st == OSSL_HPKE_STR_DELIMCHAR) in ossl_hpke_str2suite() 489 st = instrcp; in ossl_hpke_str2suite() 491 while (st != NULL && labels < 3) { in ossl_hpke_str2suite() 492 char *cp = strchr(st, OSSL_HPKE_STR_DELIMCHAR); in ossl_hpke_str2suite() 500 && (kem = synonyms_name2id(st, kemstrtab, in ossl_hpke_str2suite() 504 && (kdf = synonyms_name2id(st, kdfstrtab, in ossl_hpke_str2suite() 513 st = NULL; in ossl_hpke_str2suite() 515 st = cp + 1; in ossl_hpke_str2suite() [all …]
|
/openssl/demos/cms/ |
H A D | cms_ver.c | 61 X509_STORE *st = NULL; in main() local 71 st = X509_STORE_new(); in main() 72 if (st == NULL) in main() 86 if (!X509_STORE_add_cert(st, cacert)) in main() 109 if (!CMS_verify(cms, NULL, st, cont, out, 0)) { in main() 124 X509_STORE_free(st); in main()
|