Home
last modified time | relevance | path

Searched refs:md_size (Results 1 – 25 of 31) sorted by relevance

12

/openssl/crypto/evp/
H A Dbio_ok.c437 int md_size; in sig_out() local
446 if (md_size <= 0) in sig_out()
461 ctx->buf_len += md_size; in sig_out()
467 ctx->buf_len += md_size; in sig_out()
483 int md_size; in sig_in() local
501 ctx->buf_off += md_size; in sig_in()
508 ctx->buf_off += md_size; in sig_in()
532 int md_size; in block_out() local
538 if (md_size <= 0) in block_out()
565 int md_size; in block_in() local
[all …]
H A Dlegacy_sha.c32 return fn##_init(EVP_MD_CTX_get0_md_data(ctx), tag, ctx->digest->md_size * 8); \
41 return fn##_final(kctx, md, kctx->md_size); \
46 return fn##_init(EVP_MD_CTX_get0_md_data(ctx), tag, ctx->digest->md_size * 8); \
83 ctx->md_size = p1; in shake_ctrl()
/openssl/ssl/record/methods/
H A Dssl3_cbc.c142 size_t md_size, md_block_size = 64; in ssl3_cbc_digest_record() local
179 md_size = 16; in ssl3_cbc_digest_record()
189 md_size = 20; in ssl3_cbc_digest_record()
196 md_size = 224 / 8; in ssl3_cbc_digest_record()
203 md_size = 32; in ssl3_cbc_digest_record()
210 md_size = 384 / 8; in ssl3_cbc_digest_record()
219 md_size = 64; in ssl3_cbc_digest_record()
234 || !ossl_assert(md_size <= EVP_MAX_MD_SIZE)) in ssl3_cbc_digest_record()
274 max_mac_bytes = len - md_size - 1; in ssl3_cbc_digest_record()
451 for (j = 0; j < md_size; j++) in ssl3_cbc_digest_record()
[all …]
H A Dssl3_meth.c224 size_t md_size; in ssl3_mac() local
234 md_size = t; in ssl3_mac()
235 npad = (48 / md_size) * md_size; in ssl3_mac()
259 memcpy(header + j, mac_sec, md_size); in ssl3_mac()
260 j += md_size; in ssl3_mac()
271 md, &md_size, in ssl3_mac()
274 mac_sec, md_size, 1) <= 0) in ssl3_mac()
289 || EVP_DigestUpdate(md_ctx, mac_sec, md_size) <= 0 in ssl3_mac()
297 || EVP_DigestUpdate(md_ctx, mac_sec, md_size) <= 0 in ssl3_mac()
299 || EVP_DigestUpdate(md_ctx, md, md_size) <= 0 in ssl3_mac()
H A Dtls1_meth.c469 size_t md_size; in tls1_mac() local
480 md_size = t; in tls1_mac()
530 || EVP_DigestSignFinal(mac_ctx, md, &md_size) <= 0) in tls1_mac()
547 BIO_dump_indent(trc_out, md, md_size, 4); in tls1_mac()
/openssl/crypto/dsa/
H A Ddsa_pmeth.c81 int ret, md_size; in pkey_dsa_sign() local
92 md_size = EVP_MD_get_size(dctx->md); in pkey_dsa_sign()
93 if (md_size <= 0) in pkey_dsa_sign()
95 if (tbslen != (size_t)md_size) in pkey_dsa_sign()
111 int ret, md_size; in pkey_dsa_verify() local
121 md_size = EVP_MD_get_size(dctx->md); in pkey_dsa_verify()
122 if (md_size <= 0) in pkey_dsa_verify()
124 if (tbslen != (size_t)md_size) in pkey_dsa_verify()
/openssl/crypto/rsa/
H A Drsa_pmeth.c147 int md_size; in pkey_rsa_sign() local
150 md_size = EVP_MD_get_size(rctx->md); in pkey_rsa_sign()
151 if (md_size <= 0) { in pkey_rsa_sign()
156 if (tbslen != (size_t)md_size) { in pkey_rsa_sign()
276 int md_size; in pkey_rsa_verify() local
283 if (md_size <= 0) { in pkey_rsa_verify()
287 if (tbslen != (size_t)md_size) { in pkey_rsa_verify()
452 int md_size; in pkey_rsa_ctrl() local
503 if (md_size <= 0) { in pkey_rsa_ctrl()
886 md_size = EVP_MD_get_size(md); in pkey_pss_init()
[all …]
H A Drsa_ameth.c457 int md_size; in rsa_ctx_to_pss() local
461 md_size = EVP_MD_get_size(sigmd); in rsa_ctx_to_pss()
462 if (md_size <= 0) in rsa_ctx_to_pss()
469 saltlen = md_size; in rsa_ctx_to_pss()
479 saltlenMax = md_size; in rsa_ctx_to_pss()
482 saltlen = EVP_PKEY_get_size(pk) - md_size - 2; in rsa_ctx_to_pss()
726 int mdnid, saltlen, md_size; in rsa_sig_info_set() local
739 md_size = EVP_MD_get_size(md); in rsa_sig_info_set()
740 if (md_size <= 0) in rsa_sig_info_set()
749 && saltlen == md_size) in rsa_sig_info_set()
[all …]
/openssl/crypto/x509/
H A Dx509_set.c215 int pknid, mdnid, md_size; in x509_sig_info_init() local
282 md_size = EVP_MD_get_size(md); in x509_sig_info_init()
283 if (md_size <= 0) in x509_sig_info_init()
285 siginf->secbits = md_size * 4; in x509_sig_info_init()
/openssl/providers/implementations/kdfs/
H A Dhmacdrbg_kdf.c186 int md_size; in hmac_drbg_kdf_set_ctx_params() local
224 md_size = EVP_MD_get_size(md); in hmac_drbg_kdf_set_ctx_params()
225 if (md_size <= 0) in hmac_drbg_kdf_set_ctx_params()
227 drbg->blocklen = (size_t)md_size; in hmac_drbg_kdf_set_ctx_params()
/openssl/providers/implementations/digests/
H A Dsha3_prov.c118 if (ctx->md_size == SIZE_MAX) { in keccak_final()
123 ret = ctx->meth.final(ctx, out, ctx->md_size); in keccak_final()
125 *outl = ctx->md_size; in keccak_final()
510 ctx->md_size = SIZE_MAX; \
596 if (p != NULL && !OSSL_PARAM_set_size_t(p, ctx->md_size)) { in shake_get_ctx_params()
602 if (p != NULL && !OSSL_PARAM_set_size_t(p, ctx->md_size)) { in shake_get_ctx_params()
635 if (p != NULL && !OSSL_PARAM_get_size_t(p, &ctx->md_size)) { in shake_set_ctx_params()
/openssl/crypto/sm2/
H A Dsm2_sign.c156 const int md_size = EVP_MD_get_size(digest); in sm2_compute_msg_hash() local
163 if (md_size <= 0) { in sm2_compute_msg_hash()
172 z = OPENSSL_zalloc(md_size); in sm2_compute_msg_hash()
188 || !EVP_DigestUpdate(hash, z, md_size) in sm2_compute_msg_hash()
196 e = BN_bin2bn(z, md_size, NULL); in sm2_compute_msg_hash()
H A Dsm2_crypt.c91 const int md_size = EVP_MD_get_size(digest); in ossl_sm2_ciphertext_size() local
94 if (field_size == 0 || md_size <= 0) in ossl_sm2_ciphertext_size()
99 + ASN1_object_size(0, md_size, V_ASN1_OCTET_STRING) in ossl_sm2_ciphertext_size()
/openssl/test/
H A Dbad_dtls_test.c373 int md_size; in send_finished() local
385 md_size = EVP_MD_CTX_get_size(handshake_md); in send_finished()
386 if (md_size <= 0) in send_finished()
389 handshake_hash, md_size, in send_finished()
/openssl/providers/implementations/rands/
H A Ddrbg_hmac.c416 int md_size; in drbg_hmac_set_ctx_params_locked() local
435 md_size = EVP_MD_get_size(md); in drbg_hmac_set_ctx_params_locked()
436 if (md_size <= 0) in drbg_hmac_set_ctx_params_locked()
438 hmac->blocklen = (size_t)md_size; in drbg_hmac_set_ctx_params_locked()
H A Ddrbg_hash.c513 int md_size; in drbg_hash_set_ctx_params_locked() local
528 md_size = EVP_MD_get_size(md); in drbg_hash_set_ctx_params_locked()
529 if (md_size <= 0) in drbg_hash_set_ctx_params_locked()
531 hash->blocklen = md_size; in drbg_hash_set_ctx_params_locked()
/openssl/crypto/sha/
H A Dsha3.c35 ctx->md_size = bitlen / 8; in ossl_sha3_init()
48 ctx->md_size = mdlen / 8; in ossl_keccak_init()
/openssl/providers/implementations/signature/
H A Dsm2_sig.c321 int md_size; in sm2sig_digest_verify_final() local
326 md_size = EVP_MD_get_size(psm2ctx->md); in sm2sig_digest_verify_final()
327 if (md_size <= 0 || md_size > (int)sizeof(digest)) in sm2sig_digest_verify_final()
H A Decdsa_sig.c172 int md_nid, md_size; in ecdsa_setup_md() local
193 md_size = EVP_MD_get_size(md); in ecdsa_setup_md()
194 if (md_size <= 0) { in ecdsa_setup_md()
196 "%s has invalid md size %d", mdname, md_size); in ecdsa_setup_md()
253 ctx->mdsize = (size_t)md_size; in ecdsa_setup_md()
/openssl/providers/implementations/macs/
H A Dkmac_prov.c192 int md_size; in kmac_fetch_new() local
202 md_size = EVP_MD_get_size(ossl_prov_digest_md(&kctx->digest)); in kmac_fetch_new()
203 if (md_size <= 0) { in kmac_fetch_new()
207 kctx->out_len = (size_t)md_size; in kmac_fetch_new()
/openssl/include/internal/
H A Dsha3.h44 size_t md_size; /* output length, variable in XOF */ member
/openssl/crypto/store/
H A Dstore_lib.c936 int md_size; in OSSL_STORE_SEARCH_by_key_fingerprint() local
941 md_size = EVP_MD_get_size(digest); in OSSL_STORE_SEARCH_by_key_fingerprint()
942 if (md_size <= 0) { in OSSL_STORE_SEARCH_by_key_fingerprint()
947 if (digest != NULL && len != (size_t)md_size) { in OSSL_STORE_SEARCH_by_key_fingerprint()
951 EVP_MD_get0_name(digest), md_size, len); in OSSL_STORE_SEARCH_by_key_fingerprint()
/openssl/crypto/ffc/
H A Dffc_params_generate.c820 int md_size; in ossl_ffc_params_FIPS186_2_gen_verify() local
849 md_size = EVP_MD_get_size(md); in ossl_ffc_params_FIPS186_2_gen_verify()
850 if (md_size <= 0) in ossl_ffc_params_FIPS186_2_gen_verify()
853 N = md_size * 8; in ossl_ffc_params_FIPS186_2_gen_verify()
/openssl/crypto/ts/
H A Dts_rsp_sign.c448 int i, md_size; in ts_RESP_check_request() local
473 md_size = EVP_MD_get_size(md); in ts_RESP_check_request()
474 if (md_size <= 0) in ts_RESP_check_request()
485 if (digest->length != md_size) { in ts_RESP_check_request()
/openssl/ssl/
H A Dtls13_enc.c250 int md_size; in tls13_generate_master_secret() local
252 md_size = EVP_MD_get_size(md); in tls13_generate_master_secret()
253 if (md_size <= 0) { in tls13_generate_master_secret()
257 *secret_size = (size_t)md_size; in tls13_generate_master_secret()

Completed in 229 milliseconds

12