Home
last modified time | relevance | path

Searched refs:key_bits (Results 1 – 20 of 20) sorted by relevance

/openthread-3.5.0/third_party/mbedtls/repo/include/psa/
Dcrypto_sizes.h175 #define PSA_AEAD_TAG_LENGTH(key_type, key_bits, alg) \ argument
178 ((void) (key_bits), 0))
274 #define PSA_MAC_LENGTH(key_type, key_bits, alg) \ argument
278 ((void)(key_type), (void)(key_bits), 0))
592 #define PSA_SIGN_OUTPUT_SIZE(key_type, key_bits, alg) \ argument
593 (PSA_KEY_TYPE_IS_RSA(key_type) ? ((void)alg, PSA_BITS_TO_BYTES(key_bits)) : \
594 PSA_KEY_TYPE_IS_ECC(key_type) ? PSA_ECDSA_SIGNATURE_SIZE(key_bits) : \
637 #define PSA_ASYMMETRIC_ENCRYPT_OUTPUT_SIZE(key_type, key_bits, alg) \ argument
639 ((void)alg, PSA_BITS_TO_BYTES(key_bits)) : \
676 #define PSA_ASYMMETRIC_DECRYPT_OUTPUT_SIZE(key_type, key_bits, alg) \ argument
[all …]
Dcrypto_extra.h558 #define PSA_KEY_DOMAIN_PARAMETERS_SIZE(key_type, key_bits) \ argument
560 PSA_KEY_TYPE_IS_DH(key_type) ? PSA_DH_KEY_DOMAIN_PARAMETERS_SIZE(key_bits) : \
561 PSA_KEY_TYPE_IS_DSA(key_type) ? PSA_DSA_KEY_DOMAIN_PARAMETERS_SIZE(key_bits) : \
563 #define PSA_DH_KEY_DOMAIN_PARAMETERS_SIZE(key_bits) \ argument
564 (4 + (PSA_BITS_TO_BYTES(key_bits) + 5) * 3 /*without optional parts*/)
565 #define PSA_DSA_KEY_DOMAIN_PARAMETERS_SIZE(key_bits) \ argument
566 (4 + (PSA_BITS_TO_BYTES(key_bits) + 5) * 2 /*p, g*/ + 34 /*q*/)
Dcrypto_compat.h111 #define PSA_ASYMMETRIC_SIGN_OUTPUT_SIZE( key_type, key_bits, alg ) \ argument
112 MBEDTLS_DEPRECATED_CONSTANT( size_t, PSA_SIGN_OUTPUT_SIZE( key_type, key_bits, alg ) )
113 #define PSA_KEY_EXPORT_MAX_SIZE( key_type, key_bits ) \ argument
114 MBEDTLS_DEPRECATED_CONSTANT( size_t, PSA_EXPORT_KEY_OUTPUT_SIZE( key_type, key_bits ) )
121 #define PSA_MAC_FINAL_SIZE( key_type, key_bits, alg ) \ argument
122 MBEDTLS_DEPRECATED_CONSTANT( size_t, PSA_MAC_LENGTH( key_type, key_bits, alg ) )
/openthread-3.5.0/third_party/mbedtls/repo/tests/src/drivers/
Dtest_driver_size.c73 const size_t key_bits ) in mbedtls_test_size_function() argument
81 ? PSA_EXPORT_KEY_OUTPUT_SIZE( key_type, key_bits ) : 0 ); in mbedtls_test_size_function()
96 ( ( key_bits + 7 ) / 8 ) ); in mbedtls_test_size_function()
/openthread-3.5.0/third_party/mbedtls/repo/library/
Dpsa_crypto_cipher.c37 size_t key_bits, in mbedtls_cipher_info_from_psa() argument
100 if( key_bits == 64 ) in mbedtls_cipher_info_from_psa()
107 if( key_bits == 128 ) in mbedtls_cipher_info_from_psa()
108 key_bits = 192; in mbedtls_cipher_info_from_psa()
126 (int) key_bits, mode ) ); in mbedtls_cipher_info_from_psa()
139 size_t key_bits; in psa_cipher_setup() local
148 key_bits = attributes->core.bits; in psa_cipher_setup()
150 key_bits, NULL ); in psa_cipher_setup()
159 if( key_type == PSA_KEY_TYPE_DES && key_bits == 128 ) in psa_cipher_setup()
173 (int) key_bits, cipher_operation ); in psa_cipher_setup()
Dpsa_crypto_aead.c83 size_t key_bits; in psa_aead_setup() local
88 key_bits = attributes->core.bits; in psa_aead_setup()
91 attributes->core.type, key_bits, in psa_aead_setup()
111 key_buffer, (unsigned int) key_bits ) ); in psa_aead_setup()
130 key_buffer, (unsigned int) key_bits ) ); in psa_aead_setup()
160 key_bits, alg ) in psa_aead_setup()
165 key_bits, in psa_aead_setup()
Dpsa_crypto_cipher.h40 psa_algorithm_t alg, psa_key_type_t key_type, size_t key_bits,
Dpsa_crypto_core.h266 psa_algorithm_t alg, psa_key_type_t key_type, size_t key_bits,
Dpsa_crypto_driver_wrappers.c441 size_t key_bits = attributes->core.bits; in psa_driver_wrapper_get_key_buffer_size() local
458 *key_buffer_size = mbedtls_test_size_function( key_type, key_bits ); in psa_driver_wrapper_get_key_buffer_size()
465 (void)key_bits; in psa_driver_wrapper_get_key_buffer_size()
Dpsa_crypto.c2344 size_t key_bits = psa_get_key_bits( attributes ); in psa_mac_finalize_alg_and_key_validation() local
2355 *mac_size = PSA_MAC_LENGTH( key_type, key_bits, alg ); in psa_mac_finalize_alg_and_key_validation()
2366 if( *mac_size > PSA_MAC_LENGTH( key_type, key_bits, in psa_mac_finalize_alg_and_key_validation()
/openthread-3.5.0/third_party/mbedtls/repo/programs/psa/
Dcrypto_examples.c163 key_bits = 256, in cipher_example_encrypt_decrypt_aes_cbc_nopad_1_block() enumerator
184 psa_set_key_bits( &attributes, key_bits ); in cipher_example_encrypt_decrypt_aes_cbc_nopad_1_block()
211 key_bits = 256, in cipher_example_encrypt_decrypt_aes_cbc_pkcs7_multi() enumerator
232 psa_set_key_bits( &attributes, key_bits ); in cipher_example_encrypt_decrypt_aes_cbc_pkcs7_multi()
259 key_bits = 256, in cipher_example_encrypt_decrypt_aes_ctr_multi() enumerator
279 psa_set_key_bits( &attributes, key_bits ); in cipher_example_encrypt_decrypt_aes_ctr_multi()
/openthread-3.5.0/third_party/mbedtls/repo/tests/include/test/
Dpsa_crypto_helpers.h223 #define MBEDTLS_TEST_PSA_SKIP_IF_ALT_AES_192( key_type, key_bits ) \ argument
228 ( key_bits == 192 ) ) \
/openthread-3.5.0/third_party/mbedtls/repo/tests/include/test/drivers/
Dsize.h34 const size_t key_bits );
/openthread-3.5.0/third_party/mbedtls/repo/tests/suites/
Dtest_suite_psa_crypto_metadata.function192 psa_key_type_t key_type, size_t key_bits,
207 TEST_EQUAL( length, PSA_MAC_LENGTH( key_type, key_bits, alg ) );
217 psa_key_type_t key_type, size_t key_bits,
232 TEST_EQUAL( tag_length, PSA_AEAD_TAG_LENGTH( key_type, key_bits, alg ) );
296 size_t key_bits = key_bits_arg;
299 key_type, key_bits, length );
308 key_type, key_bits, n );
340 key_type, key_bits, n );
424 size_t key_bits = key_bits_arg;
427 key_type, key_bits, tag_length );
[all …]
Dtest_suite_psa_crypto.function1043 size_t key_bits;
1062 key_bits = psa_get_key_bits( &attributes );
1063 buffer_length = PSA_ASYMMETRIC_ENCRYPT_OUTPUT_SIZE( key_type, key_bits,
3296 size_t key_bits;
3315 key_bits = psa_get_key_bits( &attributes );
3317 output_size = input_data->len + PSA_AEAD_TAG_LENGTH( key_type, key_bits,
3394 size_t key_bits;
3410 key_bits = psa_get_key_bits( &attributes );
3412 output_size = input_data->len + PSA_AEAD_TAG_LENGTH( key_type, key_bits,
3461 size_t key_bits;
[all …]
Dtest_suite_psa_crypto_persistent_key.function44 int key_lifetime, int key_type, int key_bits,
54 psa_set_key_bits( &attributes, key_bits );
Dtest_suite_psa_crypto_driver_wrappers.function1075 size_t key_bits;
1093 key_bits = psa_get_key_bits( &attributes );
1095 output_size = input_data->len + PSA_AEAD_TAG_LENGTH( key_type, key_bits,
1144 size_t key_bits;
1162 key_bits = psa_get_key_bits( &attributes );
1164 output_size = input_data->len - PSA_AEAD_TAG_LENGTH( key_type, key_bits,
/openthread-3.5.0/third_party/mbedtls/repo/tests/src/
Dpsa_exercise_key.c509 size_t key_bits; in mbedtls_test_psa_key_agreement_with_self() local
520 key_bits = psa_get_key_bits( &attributes ); in mbedtls_test_psa_key_agreement_with_self()
522 public_key_length = PSA_EXPORT_PUBLIC_KEY_OUTPUT_SIZE( public_key_type, key_bits ); in mbedtls_test_psa_key_agreement_with_self()
549 size_t key_bits; in mbedtls_test_psa_raw_key_agreement_with_self() local
562 key_bits = psa_get_key_bits( &attributes ); in mbedtls_test_psa_raw_key_agreement_with_self()
564 public_key_length = PSA_EXPORT_PUBLIC_KEY_OUTPUT_SIZE( public_key_type, key_bits ); in mbedtls_test_psa_raw_key_agreement_with_self()
577 key_bits ) ); in mbedtls_test_psa_raw_key_agreement_with_self()
/openthread-3.5.0/third_party/mbedtls/repo/docs/
Dgetting_started.md845 key_bits = 256,
849 static uint8_t exported[PSA_KEY_EXPORT_ECC_PUBLIC_KEY_MAX_SIZE(key_bits)];
869 psa_set_key_bits(&attributes, key_bits);
/openthread-3.5.0/third_party/mbedtls/repo/docs/proposed/
Dpsa-driver-interface.md618 size_function(key_type, key_bits)
620 …amed in the `"size_function"` property, `key_type` is the key type and `key_bits` is the key size …
622 size_t size_function(psa_key_type_t key_type, size_t key_bits);
627 … property, the size of the key context for a key of type `key_type` and of size `key_bits` bits is:
633 …where `public_key_overhead = PSA_EXPORT_PUBLIC_KEY_MAX_SIZE(key_type, key_bits)` if the `"store_pu…
644 where `key_bytes = ((key_bits + 7) / 8)` is the key size in bytes.