Home
last modified time | relevance | path

Searched refs:prv (Results 1 – 15 of 15) sorted by relevance

/net-tools-3.6.0/mbedtls-2.4.0/library/
Dssl_cache.c145 mbedtls_ssl_cache_entry *cur, *prv; in mbedtls_ssl_cache_set() local
154 prv = NULL; in mbedtls_ssl_cache_set()
180 prv = cur; in mbedtls_ssl_cache_set()
216 prv->next = cur; in mbedtls_ssl_cache_set()
231 if( prv == NULL ) in mbedtls_ssl_cache_set()
234 prv->next = cur; in mbedtls_ssl_cache_set()
303 mbedtls_ssl_cache_entry *cur, *prv; in mbedtls_ssl_cache_free() local
309 prv = cur; in mbedtls_ssl_cache_free()
312 mbedtls_ssl_session_free( &prv->session ); in mbedtls_ssl_cache_free()
315 mbedtls_free( prv->peer_cert.p ); in mbedtls_ssl_cache_free()
[all …]
Dpk.c303 int mbedtls_pk_check_pair( const mbedtls_pk_context *pub, const mbedtls_pk_context *prv ) in mbedtls_pk_check_pair() argument
306 prv == NULL || prv->pk_info == NULL || in mbedtls_pk_check_pair()
307 prv->pk_info->check_pair_func == NULL ) in mbedtls_pk_check_pair()
312 if( prv->pk_info->type == MBEDTLS_PK_RSA_ALT ) in mbedtls_pk_check_pair()
319 if( pub->pk_info != prv->pk_info ) in mbedtls_pk_check_pair()
323 return( prv->pk_info->check_pair_func( pub->pk_ctx, prv->pk_ctx ) ); in mbedtls_pk_check_pair()
Dpk_wrap.c128 static int rsa_check_pair_wrap( const void *pub, const void *prv ) in rsa_check_pair_wrap() argument
131 (const mbedtls_rsa_context *) prv ) ); in rsa_check_pair_wrap()
244 static int eckey_check_pair( const void *pub, const void *prv ) in eckey_check_pair() argument
247 (const mbedtls_ecp_keypair *) prv ) ); in eckey_check_pair()
429 static int rsa_alt_check_pair( const void *pub, const void *prv ) in rsa_alt_check_pair() argument
436 if( rsa_alt_get_bitlen( prv ) != rsa_get_bitlen( pub ) ) in rsa_alt_check_pair()
441 if( ( ret = rsa_alt_sign_wrap( (void *) prv, MBEDTLS_MD_NONE, in rsa_alt_check_pair()
Ddes.c877 unsigned char prv[8]; in mbedtls_des_self_test() local
970 memcpy( prv, des3_test_iv, 8 ); in mbedtls_des_self_test()
1024 memcpy( tmp, prv, 8 ); in mbedtls_des_self_test()
1025 memcpy( prv, buf, 8 ); in mbedtls_des_self_test()
1029 memcpy( buf, prv, 8 ); in mbedtls_des_self_test()
Decp.c1922 int mbedtls_ecp_check_pub_priv( const mbedtls_ecp_keypair *pub, const mbedtls_ecp_keypair *prv ) in mbedtls_ecp_check_pub_priv() argument
1929 pub->grp.id != prv->grp.id || in mbedtls_ecp_check_pub_priv()
1930 mbedtls_mpi_cmp_mpi( &pub->Q.X, &prv->Q.X ) || in mbedtls_ecp_check_pub_priv()
1931 mbedtls_mpi_cmp_mpi( &pub->Q.Y, &prv->Q.Y ) || in mbedtls_ecp_check_pub_priv()
1932 mbedtls_mpi_cmp_mpi( &pub->Q.Z, &prv->Q.Z ) ) in mbedtls_ecp_check_pub_priv()
1941 mbedtls_ecp_group_copy( &grp, &prv->grp ); in mbedtls_ecp_check_pub_priv()
1944 MBEDTLS_MPI_CHK( mbedtls_ecp_mul( &grp, &Q, &prv->d, &prv->grp.G, NULL, NULL ) ); in mbedtls_ecp_check_pub_priv()
1946 if( mbedtls_mpi_cmp_mpi( &Q.X, &prv->Q.X ) || in mbedtls_ecp_check_pub_priv()
1947 mbedtls_mpi_cmp_mpi( &Q.Y, &prv->Q.Y ) || in mbedtls_ecp_check_pub_priv()
1948 mbedtls_mpi_cmp_mpi( &Q.Z, &prv->Q.Z ) ) in mbedtls_ecp_check_pub_priv()
Dmemory_buffer_alloc.c185 memory_header *prv = heap.first, *cur = heap.first->next; in verify_chain() local
216 if( cur->prev != prv ) in verify_chain()
225 prv = cur; in verify_chain()
Drsa.c258 int mbedtls_rsa_check_pub_priv( const mbedtls_rsa_context *pub, const mbedtls_rsa_context *prv ) in mbedtls_rsa_check_pub_priv() argument
261 mbedtls_rsa_check_privkey( prv ) != 0 ) in mbedtls_rsa_check_pub_priv()
266 if( mbedtls_mpi_cmp_mpi( &pub->N, &prv->N ) != 0 || in mbedtls_rsa_check_pub_priv()
267 mbedtls_mpi_cmp_mpi( &pub->E, &prv->E ) != 0 ) in mbedtls_rsa_check_pub_priv()
Daes.c1229 unsigned char prv[16]; in mbedtls_aes_self_test() local
1312 memset( prv, 0, 16 ); in mbedtls_aes_self_test()
1341 memcpy( tmp, prv, 16 ); in mbedtls_aes_self_test()
1342 memcpy( prv, buf, 16 ); in mbedtls_aes_self_test()
1346 if( memcmp( prv, aes_test_cbc_enc[u], 16 ) != 0 ) in mbedtls_aes_self_test()
/net-tools-3.6.0/mbedtls-2.4.0/tests/suites/
Dtest_suite_rsa.function603 mbedtls_rsa_context pub, prv;
606 mbedtls_rsa_init( &prv, MBEDTLS_RSA_PKCS_V15, 0 );
609 prv.len = mod / 8;
622 TEST_ASSERT( mbedtls_mpi_read_string( &prv.P, radix_P, input_P ) == 0 );
626 TEST_ASSERT( mbedtls_mpi_read_string( &prv.Q, radix_Q, input_Q ) == 0 );
630 TEST_ASSERT( mbedtls_mpi_read_string( &prv.N, radix_N, input_N ) == 0 );
634 TEST_ASSERT( mbedtls_mpi_read_string( &prv.E, radix_E, input_E ) == 0 );
638 TEST_ASSERT( mbedtls_mpi_read_string( &prv.D, radix_D, input_D ) == 0 );
642 TEST_ASSERT( mbedtls_mpi_read_string( &prv.DP, radix_DP, input_DP ) == 0 );
646 TEST_ASSERT( mbedtls_mpi_read_string( &prv.DQ, radix_DQ, input_DQ ) == 0 );
[all …]
Dtest_suite_ecp.function438 mbedtls_ecp_keypair pub, prv;
441 mbedtls_ecp_keypair_init( &prv );
448 TEST_ASSERT( mbedtls_ecp_group_load( &prv.grp, id ) == 0 );
449 TEST_ASSERT( mbedtls_ecp_point_read_string( &prv.Q, 16, Qx, Qy ) == 0 );
450 TEST_ASSERT( mbedtls_mpi_read_string( &prv.d, 16, d ) == 0 );
452 TEST_ASSERT( mbedtls_ecp_check_pub_priv( &pub, &prv ) == ret );
456 mbedtls_ecp_keypair_free( &prv );
Dtest_suite_pk.function90 mbedtls_pk_context pub, prv, alt;
93 mbedtls_pk_init( &prv );
97 TEST_ASSERT( mbedtls_pk_parse_keyfile( &prv, prv_file, NULL ) == 0 );
99 TEST_ASSERT( mbedtls_pk_check_pair( &pub, &prv ) == ret );
102 if( mbedtls_pk_get_type( &prv ) == MBEDTLS_PK_RSA )
104 TEST_ASSERT( mbedtls_pk_setup_rsa_alt( &alt, mbedtls_pk_rsa( prv ),
111 mbedtls_pk_free( &prv );
/net-tools-3.6.0/mbedtls-2.4.0/include/mbedtls/
Dpk_internal.h74 int (*check_pair_func)( const void *pub, const void *prv );
Drsa.h197 int mbedtls_rsa_check_pub_priv( const mbedtls_rsa_context *pub, const mbedtls_rsa_context *prv );
Dpk.h400 int mbedtls_pk_check_pair( const mbedtls_pk_context *pub, const mbedtls_pk_context *prv );
Decp.h654 int mbedtls_ecp_check_pub_priv( const mbedtls_ecp_keypair *pub, const mbedtls_ecp_keypair *prv );