Home
last modified time | relevance | path

Searched refs:md_alg (Results 1 – 25 of 30) sorted by relevance

12

/AliOS-Things-master/components/mbedtls/library/
A Dpk_wrap.c72 static int rsa_verify_wrap( void *ctx, mbedtls_md_type_t md_alg, in rsa_verify_wrap() argument
81 if( md_alg == MBEDTLS_MD_NONE && UINT_MAX < hash_len ) in rsa_verify_wrap()
89 MBEDTLS_RSA_PUBLIC, md_alg, in rsa_verify_wrap()
104 static int rsa_sign_wrap( void *ctx, mbedtls_md_type_t md_alg, in rsa_sign_wrap() argument
112 if( md_alg == MBEDTLS_MD_NONE && UINT_MAX < hash_len ) in rsa_sign_wrap()
119 md_alg, (unsigned int) hash_len, hash, sig ) ); in rsa_sign_wrap()
232 static int ecdsa_sign_wrap( void *ctx, mbedtls_md_type_t md_alg,
254 static int eckey_sign_wrap( void *ctx, mbedtls_md_type_t md_alg, in eckey_sign_wrap() argument
480 ((void) md_alg); in ecdsa_verify_wrap()
507 ((void) md_alg); in ecdsa_verify_rs_wrap()
[all …]
A Dpk.c206 if( ( md_info = mbedtls_md_info_from_type( md_alg ) ) == NULL ) in pk_hashlen_helper()
241 mbedtls_md_type_t md_alg, in mbedtls_pk_verify_restartable() argument
247 PK_VALIDATE_RET( ( md_alg == MBEDTLS_MD_NONE && hash_len == 0 ) || in mbedtls_pk_verify_restartable()
252 pk_hashlen_helper( md_alg, &hash_len ) != 0 ) in mbedtls_pk_verify_restartable()
300 mbedtls_pk_context *ctx, mbedtls_md_type_t md_alg, in mbedtls_pk_verify_ext() argument
322 if( md_alg == MBEDTLS_MD_NONE && UINT_MAX < hash_len ) in mbedtls_pk_verify_ext()
336 md_alg, (unsigned int) hash_len, hash, in mbedtls_pk_verify_ext()
363 mbedtls_md_type_t md_alg, in mbedtls_pk_sign_restartable() argument
375 pk_hashlen_helper( md_alg, &hash_len ) != 0 ) in mbedtls_pk_sign_restartable()
389 ret = ctx->pk_info->sign_rs_func( ctx->pk_ctx, md_alg, in mbedtls_pk_sign_restartable()
[all …]
A Dpkcs11.c169 mbedtls_md_type_t md_alg, in mbedtls_pkcs11_sign() argument
184 if( md_alg != MBEDTLS_MD_NONE ) in mbedtls_pkcs11_sign()
186 const mbedtls_md_info_t *md_info = mbedtls_md_info_from_type( md_alg ); in mbedtls_pkcs11_sign()
190 if( mbedtls_oid_get_oid_by_md( md_alg, &oid, &oid_size ) != 0 ) in mbedtls_pkcs11_sign()
204 if( md_alg != MBEDTLS_MD_NONE ) in mbedtls_pkcs11_sign()
A Dx509write_csr.c60 void mbedtls_x509write_csr_set_md_alg( mbedtls_x509write_csr *ctx, mbedtls_md_type_t md_alg ) in mbedtls_x509write_csr_set_md_alg() argument
62 ctx->md_alg = md_alg; in mbedtls_x509write_csr_set_md_alg()
191 mbedtls_md( mbedtls_md_info_from_type( ctx->md_alg ), c, len, hash ); in mbedtls_x509write_csr_der()
193 if( ( ret = mbedtls_pk_sign( ctx->key, ctx->md_alg, hash, 0, sig, &sig_len, in mbedtls_x509write_csr_der()
206 if( ( ret = mbedtls_oid_get_oid_by_sig_alg( pk_alg, ctx->md_alg, in mbedtls_x509write_csr_der()
A Doid.c311 mbedtls_md_type_t md_alg; member
411 FN_OID_GET_ATTR2(mbedtls_oid_get_sig_alg, oid_sig_alg_t, sig_alg, mbedtls_md_type_t, md_alg, mbedtl…
412 …t_oid_by_sig_alg, oid_sig_alg_t, oid_sig_alg, mbedtls_pk_type_t, pk_alg, mbedtls_md_type_t, md_alg)
570 mbedtls_md_type_t md_alg; member
625 FN_OID_TYPED_FROM_ASN1(oid_md_alg_t, md_alg, oid_md_alg)
626 FN_OID_GET_ATTR1(mbedtls_oid_get_md_alg, oid_md_alg_t, md_alg, mbedtls_md_type_t, md_alg)
627 …ID_GET_OID_BY_ATTR1(mbedtls_oid_get_oid_by_md, oid_md_alg_t, oid_md_alg, mbedtls_md_type_t, md_alg)
681 mbedtls_md_type_t md_alg; member
702 …pkcs12_pbe_alg, oid_pkcs12_pbe_alg_t, pkcs12_pbe_alg, mbedtls_md_type_t, md_alg, mbedtls_cipher_ty… in FN_OID_TYPED_FROM_ASN1()
A Drsa.c1759 mbedtls_md_type_t md_alg, in mbedtls_rsa_rsassa_pss_sign() argument
1775 RSA_VALIDATE_RET( ( md_alg == MBEDTLS_MD_NONE && in mbedtls_rsa_rsassa_pss_sign()
1788 if( md_alg != MBEDTLS_MD_NONE ) in mbedtls_rsa_rsassa_pss_sign()
1911 if( md_alg != MBEDTLS_MD_NONE ) in rsa_rsassa_pkcs1_v15_encode()
1966 if( md_alg == MBEDTLS_MD_NONE ) in rsa_rsassa_pkcs1_v15_encode()
2029 RSA_VALIDATE_RET( ( md_alg == MBEDTLS_MD_NONE && in mbedtls_rsa_rsassa_pkcs1_v15_sign()
2098 mbedtls_md_type_t md_alg, in mbedtls_rsa_pkcs1_sign() argument
2185 if( md_alg != MBEDTLS_MD_NONE ) in mbedtls_rsa_rsassa_pss_verify_ext()
2288 mbedtls_md_type_t md_alg, in mbedtls_rsa_rsassa_pss_verify() argument
2304 : md_alg; in mbedtls_rsa_rsassa_pss_verify()
[all …]
A Dx509.c142 static int x509_get_hash_alg( const mbedtls_x509_buf *alg, mbedtls_md_type_t *md_alg ) in x509_get_hash_alg() argument
172 if( ( ret = mbedtls_oid_get_md_alg( &md_oid, md_alg ) ) != 0 ) in x509_get_hash_alg()
202 mbedtls_md_type_t *md_alg, mbedtls_md_type_t *mgf_md, in mbedtls_x509_get_rsassa_pss_params() argument
212 *md_alg = MBEDTLS_MD_SHA1; in mbedtls_x509_get_rsassa_pss_params()
239 if( ( ret = mbedtls_oid_get_md_alg( &alg_id, md_alg ) ) != 0 ) in mbedtls_x509_get_rsassa_pss_params()
647 mbedtls_md_type_t *md_alg, mbedtls_pk_type_t *pk_alg, in mbedtls_x509_get_sig_alg() argument
655 if( ( ret = mbedtls_oid_get_sig_alg( sig_oid, md_alg, pk_alg ) ) != 0 ) in mbedtls_x509_get_sig_alg()
668 md_alg, in mbedtls_x509_get_sig_alg()
833 mbedtls_pk_type_t pk_alg, mbedtls_md_type_t md_alg, in mbedtls_x509_sig_alg_gets() argument
856 md_info = mbedtls_md_info_from_type( md_alg ); in mbedtls_x509_sig_alg_gets()
[all …]
A Decdsa.c407 mbedtls_md_type_t md_alg, in ecdsa_sign_det_restartable() argument
418 if( ( md_info = mbedtls_md_info_from_type( md_alg ) ) == NULL ) in ecdsa_sign_det_restartable()
472 mbedtls_md_type_t md_alg ) in mbedtls_ecdsa_sign_det() argument
480 return( ecdsa_sign_det_restartable( grp, r, s, d, buf, blen, md_alg, NULL ) ); in mbedtls_ecdsa_sign_det()
641 mbedtls_md_type_t md_alg, in mbedtls_ecdsa_write_signature_restartable() argument
663 hash, hlen, md_alg, rs_ctx ) ); in mbedtls_ecdsa_write_signature_restartable()
665 (void) md_alg; in mbedtls_ecdsa_write_signature_restartable()
689 mbedtls_md_type_t md_alg, in mbedtls_ecdsa_write_signature() argument
700 ctx, md_alg, hash, hlen, sig, slen, f_rng, p_rng, NULL ) ); in mbedtls_ecdsa_write_signature()
708 mbedtls_md_type_t md_alg ) in mbedtls_ecdsa_write_signature_det() argument
[all …]
A Dx509write_crt.c72 void mbedtls_x509write_crt_set_md_alg( mbedtls_x509write_cert *ctx, mbedtls_md_type_t md_alg ) in mbedtls_x509write_crt_set_md_alg() argument
74 ctx->md_alg = md_alg; in mbedtls_x509write_crt_set_md_alg()
328 if( ( ret = mbedtls_oid_get_oid_by_sig_alg( pk_alg, ctx->md_alg, in mbedtls_x509write_crt_der()
419 if( ( ret = mbedtls_md( mbedtls_md_info_from_type( ctx->md_alg ), c, in mbedtls_x509write_crt_der()
425 if( ( ret = mbedtls_pk_sign( ctx->issuer_key, ctx->md_alg, hash, 0, sig, &sig_len, in mbedtls_x509write_crt_der()
A Dssl_cli.c2238 *md_alg = MBEDTLS_MD_NONE; in ssl_parse_signature_algorithm()
2512 mbedtls_md_type_t md_alg = MBEDTLS_MD_NONE; in ssl_parse_server_key_exchange() local
2551 md_alg = MBEDTLS_MD_SHA1; in ssl_parse_server_key_exchange()
2589 if( md_alg == MBEDTLS_MD_NONE ) in ssl_parse_server_key_exchange()
2602 if( md_alg != MBEDTLS_MD_NONE ) in ssl_parse_server_key_exchange()
3222 mbedtls_md_type_t md_alg = MBEDTLS_MD_NONE; in ssl_write_certificate_verify() local
3295 md_alg = MBEDTLS_MD_NONE; in ssl_write_certificate_verify()
3304 md_alg = MBEDTLS_MD_SHA1; in ssl_write_certificate_verify()
3331 md_alg = MBEDTLS_MD_SHA384; in ssl_write_certificate_verify()
3336 md_alg = MBEDTLS_MD_SHA256; in ssl_write_certificate_verify()
[all …]
A Dssl_srv.c3102 mbedtls_md_type_t md_alg; in ssl_prepare_server_key_exchange() local
3128 md_alg = MBEDTLS_MD_SHA1; in ssl_prepare_server_key_exchange()
3135 md_alg = MBEDTLS_MD_NONE; in ssl_prepare_server_key_exchange()
3145 if( md_alg == MBEDTLS_MD_NONE ) in ssl_prepare_server_key_exchange()
3159 if( md_alg != MBEDTLS_MD_NONE ) in ssl_prepare_server_key_exchange()
3201 mbedtls_ssl_hash_from_md_alg( md_alg ); in ssl_prepare_server_key_exchange()
4026 mbedtls_md_type_t md_alg; in ssl_parse_certificate_verify() local
4074 md_alg = MBEDTLS_MD_NONE; in ssl_parse_certificate_verify()
4083 md_alg = MBEDTLS_MD_SHA1; in ssl_parse_certificate_verify()
4111 if( MBEDTLS_MD_SHA1 == md_alg ) in ssl_parse_certificate_verify()
[all …]
/AliOS-Things-master/components/mbedtls/platform/yoc/
A Drsa_alt.c401 if (md_alg != MBEDTLS_MD_NONE) { in mbedtls_rsa_pkcs1_sign()
407 if (md_alg == MBEDTLS_MD_MD5) { in mbedtls_rsa_pkcs1_sign()
409 } else if (md_alg == MBEDTLS_MD_SHA1) { in mbedtls_rsa_pkcs1_sign()
411 } else if (md_alg == MBEDTLS_MD_SHA256) { in mbedtls_rsa_pkcs1_sign()
418 if (md_alg == MBEDTLS_MD_MD5) { in mbedtls_rsa_pkcs1_sign()
420 } else if (md_alg == MBEDTLS_MD_SHA1) { in mbedtls_rsa_pkcs1_sign()
490 if (md_alg != MBEDTLS_MD_NONE) { in mbedtls_rsa_pkcs1_verify()
496 if (md_alg == MBEDTLS_MD_MD5) { in mbedtls_rsa_pkcs1_verify()
498 } else if (md_alg == MBEDTLS_MD_SHA1) { in mbedtls_rsa_pkcs1_verify()
507 if (md_alg == MBEDTLS_MD_MD5) { in mbedtls_rsa_pkcs1_verify()
[all …]
/AliOS-Things-master/components/mbedtls/programs/x509/
A Dcert_req.c127 mbedtls_md_type_t md_alg; /* Hash algorithm used for signature. */ member
194 opt.md_alg = DFL_MD_ALG; in main()
224 opt.md_alg = MBEDTLS_MD_SHA256; in main()
228 opt.md_alg = MBEDTLS_MD_SHA224; in main()
234 opt.md_alg = MBEDTLS_MD_MD5; in main()
241 opt.md_alg = MBEDTLS_MD_MD4; in main()
248 opt.md_alg = MBEDTLS_MD_SHA1; in main()
255 opt.md_alg = MBEDTLS_MD_SHA384; in main()
260 opt.md_alg = MBEDTLS_MD_SHA512; in main()
326 mbedtls_x509write_csr_set_md_alg( &req, opt.md_alg ); in main()
/AliOS-Things-master/components/mbedtls/include/mbedtls/
A Dpk_internal.h51 int (*verify_func)( void *ctx, mbedtls_md_type_t md_alg,
56 int (*sign_func)( void *ctx, mbedtls_md_type_t md_alg,
64 int (*verify_rs_func)( void *ctx, mbedtls_md_type_t md_alg,
70 int (*sign_rs_func)( void *ctx, mbedtls_md_type_t md_alg,
A Drsa.h916 mbedtls_md_type_t md_alg,
963 mbedtls_md_type_t md_alg,
1024 mbedtls_md_type_t md_alg,
1077 mbedtls_md_type_t md_alg,
1123 mbedtls_md_type_t md_alg,
1180 mbedtls_md_type_t md_alg,
1228 mbedtls_md_type_t md_alg,
A Dpk.h185 int mode, mbedtls_md_type_t md_alg, unsigned int hashlen,
331 int mbedtls_pk_verify( mbedtls_pk_context *ctx, mbedtls_md_type_t md_alg,
356 mbedtls_md_type_t md_alg,
391 mbedtls_pk_context *ctx, mbedtls_md_type_t md_alg,
420 int mbedtls_pk_sign( mbedtls_pk_context *ctx, mbedtls_md_type_t md_alg,
449 mbedtls_md_type_t md_alg,
A Decdsa.h196 mbedtls_md_type_t md_alg );
284 mbedtls_md_type_t md_alg,
330 mbedtls_md_type_t md_alg,
390 mbedtls_md_type_t md_alg ) MBEDTLS_DEPRECATED;
A Dpkcs11.h137 mbedtls_md_type_t md_alg,
155 int mode, mbedtls_md_type_t md_alg, unsigned int hashlen, in mbedtls_ssl_pkcs11_sign() argument
160 return mbedtls_pkcs11_sign( (mbedtls_pkcs11_context *) ctx, mode, md_alg, in mbedtls_ssl_pkcs11_sign()
A Doid.h507 mbedtls_md_type_t *md_alg, mbedtls_pk_type_t *pk_alg );
529 int mbedtls_oid_get_oid_by_sig_alg( mbedtls_pk_type_t pk_alg, mbedtls_md_type_t md_alg,
540 int mbedtls_oid_get_md_alg( const mbedtls_asn1_buf *oid, mbedtls_md_type_t *md_alg );
572 int mbedtls_oid_get_oid_by_md( mbedtls_md_type_t md_alg, const char **oid, size_t *olen );
597 int mbedtls_oid_get_pkcs12_pbe_alg( const mbedtls_asn1_buf *oid, mbedtls_md_type_t *md_alg,
A Dx509.h291 mbedtls_md_type_t *md_alg, mbedtls_md_type_t *mgf_md,
296 mbedtls_md_type_t *md_alg, mbedtls_pk_type_t *pk_alg,
305 mbedtls_pk_type_t pk_alg, mbedtls_md_type_t md_alg,
A Dx509_csr.h78 mbedtls_md_type_t md_alg; member
198 void mbedtls_x509write_csr_set_md_alg( mbedtls_x509write_csr *ctx, mbedtls_md_type_t md_alg );
A Dssl_internal.h493 mbedtls_md_type_t md_alg );
496 mbedtls_md_type_t md_alg );
768 mbedtls_md_type_t md_alg );
A Dx509_crt.h139 mbedtls_md_type_t md_alg; member
663 void mbedtls_x509write_crt_set_md_alg( mbedtls_x509write_cert *ctx, mbedtls_md_type_t md_alg );
/AliOS-Things-master/components/mbedtls/platform/yoc/include/
A Drsa_alt.h201 mbedtls_md_type_t md_alg,
232 mbedtls_md_type_t md_alg,
/AliOS-Things-master/components/mbedtls/programs/ssl/
A Dssl_server2.c979 mbedtls_md_type_t md_alg; member
988 mbedtls_md_type_t md_alg, in ssl_async_start() argument
1038 ctx->md_alg = md_alg; in ssl_async_start()
1052 mbedtls_md_type_t md_alg, in ssl_async_sign() argument
1057 ASYNC_OP_SIGN, md_alg, in ssl_async_sign()
1101 ctx->md_alg, in ssl_async_resume()

Completed in 50 milliseconds

12