Home
last modified time | relevance | path

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

12

/third_party/mbedtls/include/psa/
Dcrypto_sizes.h167 #define PSA_AEAD_TAG_LENGTH(key_type, key_bits, alg) \ argument
170 ((void) (key_bits), 0))
266 #define PSA_MAC_LENGTH(key_type, key_bits, alg) \ argument
270 ((void)(key_type), (void)(key_bits), 0))
584 #define PSA_SIGN_OUTPUT_SIZE(key_type, key_bits, alg) \ argument
585 (PSA_KEY_TYPE_IS_RSA(key_type) ? ((void)alg, PSA_BITS_TO_BYTES(key_bits)) : \
586 PSA_KEY_TYPE_IS_ECC(key_type) ? PSA_ECDSA_SIGNATURE_SIZE(key_bits) : \
629 #define PSA_ASYMMETRIC_ENCRYPT_OUTPUT_SIZE(key_type, key_bits, alg) \ argument
631 ((void)alg, PSA_BITS_TO_BYTES(key_bits)) : \
668 #define PSA_ASYMMETRIC_DECRYPT_OUTPUT_SIZE(key_type, key_bits, alg) \ argument
[all …]
Dcrypto_extra.h561 #define PSA_KEY_DOMAIN_PARAMETERS_SIZE(key_type, key_bits) \ argument
563 PSA_KEY_TYPE_IS_DH(key_type) ? PSA_DH_KEY_DOMAIN_PARAMETERS_SIZE(key_bits) : \
564 PSA_KEY_TYPE_IS_DSA(key_type) ? PSA_DSA_KEY_DOMAIN_PARAMETERS_SIZE(key_bits) : \
566 #define PSA_DH_KEY_DOMAIN_PARAMETERS_SIZE(key_bits) \ argument
567 (4 + (PSA_BITS_TO_BYTES(key_bits) + 5) * 3 /*without optional parts*/)
568 #define PSA_DSA_KEY_DOMAIN_PARAMETERS_SIZE(key_bits) \ argument
569 (4 + (PSA_BITS_TO_BYTES(key_bits) + 5) * 2 /*p, g*/ + 34 /*q*/)
/third_party/openssl/crypto/evp/
De_rc2.c36 int key_bits; /* effective key bits */ member
96 key, data(ctx)->key_bits); in rc2_init_key()
134 int key_bits; in rc2_get_asn1_type_and_iv() local
144 key_bits = rc2_magic_to_meth((int)num); in rc2_get_asn1_type_and_iv()
145 if (!key_bits) in rc2_get_asn1_type_and_iv()
149 if (EVP_CIPHER_CTX_ctrl(c, EVP_CTRL_SET_RC2_KEY_BITS, key_bits, in rc2_get_asn1_type_and_iv()
151 || EVP_CIPHER_CTX_set_key_length(c, key_bits / 8) <= 0) in rc2_get_asn1_type_and_iv()
174 data(c)->key_bits = EVP_CIPHER_CTX_get_key_length(c) * 8; in rc2_ctrl()
178 *(int *)ptr = data(c)->key_bits; in rc2_ctrl()
183 data(c)->key_bits = arg; in rc2_ctrl()
/third_party/harfbuzz/src/
Dhb-cache.hh35 template <unsigned int key_bits, unsigned int value_bits, unsigned int cache_bits>
38 static_assert ((key_bits >= cache_bits), "");
39 static_assert ((key_bits + value_bits - cache_bits <= 8 * sizeof (hb_atomic_int_t)), "");
55 …if ((key_bits + value_bits - cache_bits == 8 * sizeof (hb_atomic_int_t) && v == (unsigned int) -1)… in get()
64 if (unlikely ((key >> key_bits) || (value >> value_bits))) in set()
/third_party/flutter/skia/third_party/externals/harfbuzz/src/
Dhb-cache.hh35 template <unsigned int key_bits, unsigned int value_bits, unsigned int cache_bits>
38 static_assert ((key_bits >= cache_bits), "");
39 static_assert ((key_bits + value_bits - cache_bits <= 8 * sizeof (hb_atomic_int_t)), "");
55 …if ((key_bits + value_bits - cache_bits == 8 * sizeof (hb_atomic_int_t) && v == (unsigned int) -1)… in get()
64 if (unlikely ((key >> key_bits) || (value >> value_bits))) in set()
/third_party/skia/third_party/externals/harfbuzz/src/
Dhb-cache.hh35 template <unsigned int key_bits, unsigned int value_bits, unsigned int cache_bits>
38 static_assert ((key_bits >= cache_bits), "");
39 static_assert ((key_bits + value_bits - cache_bits <= 8 * sizeof (hb_atomic_int_t)), "");
55 …if ((key_bits + value_bits - cache_bits == 8 * sizeof (hb_atomic_int_t) && v == (unsigned int) -1)… in get()
64 if (unlikely ((key >> key_bits) || (value >> value_bits))) in set()
/third_party/ffmpeg/libavutil/
Dcamellia.c46 int key_bits; member
194 if (cs->key_bits == 128) { in generate_round_keys()
261 if (cs->key_bits != 128) { in camellia_encrypt()
284 if (cs->key_bits != 128) { in camellia_decrypt()
352 av_cold int av_camellia_init(AVCAMELLIA *cs, const uint8_t *key, int key_bits) in av_camellia_init() argument
356 if (key_bits != 128 && key_bits != 192 && key_bits != 256) in av_camellia_init()
360 cs->key_bits = key_bits; in av_camellia_init()
363 if (key_bits == 192) { in av_camellia_init()
366 } else if (key_bits == 256) { in av_camellia_init()
381 if (key_bits != 128) { in av_camellia_init()
Drc4.c33 int av_rc4_init(AVRC4 *r, const uint8_t *key, int key_bits, int decrypt) { in av_rc4_init() argument
37 int keylen = key_bits >> 3; in av_rc4_init()
38 if (key_bits & 7) in av_rc4_init()
Dtwofish.c269 av_cold int av_twofish_init(AVTWOFISH *cs, const uint8_t *key, int key_bits) in av_twofish_init() argument
275 if (key_bits < 0) in av_twofish_init()
277 if (key_bits <= 128) { in av_twofish_init()
279 } else if (key_bits <= 192) { in av_twofish_init()
285 if (key_bits <= 256) { in av_twofish_init()
286 memcpy(keypad, key, key_bits >> 3); in av_twofish_init()
305 if (cs->ksize << 6 != key_bits) { in av_twofish_init()
Ddes.c278 int av_des_init(AVDES *d, const uint8_t *key, int key_bits, av_unused int decrypt) { in av_des_init() argument
279 if (key_bits != 64 && key_bits != 192) in av_des_init()
281 d->triple_des = key_bits > 64; in av_des_init()
Daes.c195 int av_aes_init(AVAES *a, const uint8_t *key, int key_bits, int decrypt) in av_aes_init() argument
199 int KC = key_bits >> 5; in av_aes_init()
228 if (key_bits != 128 && key_bits != 192 && key_bits != 256) in av_aes_init()
Dcast5.c456 av_cold int av_cast5_init(AVCAST5* cs, const uint8_t *key, int key_bits) in av_cast5_init() argument
461 if (key_bits % 8 || key_bits < 40 || key_bits > 128) in av_cast5_init()
464 memcpy(newKey, key, key_bits >> 3); in av_cast5_init()
466 cs->rounds = key_bits <= 80 ? 12 : 16; in av_cast5_init()
Dtwofish.h53 int av_twofish_init(struct AVTWOFISH *ctx, const uint8_t *key, int key_bits);
Dcamellia.h53 int av_camellia_init(struct AVCAMELLIA *ctx, const uint8_t *key, int key_bits);
/third_party/mbedtls/library/
Dpsa_crypto_cipher.c37 size_t key_bits, in mbedtls_cipher_info_from_psa() argument
103 if( key_bits == 64 ) in mbedtls_cipher_info_from_psa()
110 if( key_bits == 128 ) in mbedtls_cipher_info_from_psa()
111 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.c49 size_t key_bits; in psa_aead_setup() local
56 key_bits = attributes->core.bits; in psa_aead_setup()
59 attributes->core.type, key_bits, in psa_aead_setup()
79 key_buffer, (unsigned int) key_bits ) ); in psa_aead_setup()
98 key_buffer, (unsigned int) key_bits ) ); in psa_aead_setup()
128 key_bits, alg ) in psa_aead_setup()
135 key_bits, in psa_aead_setup()
/third_party/openssl/providers/implementations/ciphers/
Dcipher_rc2.c116 if (p != NULL && !OSSL_PARAM_set_size_t(p, ctx->key_bits)) { in rc2_get_ctx_params()
138 num = rc2_keybits_to_magic(ctx->key_bits); in rc2_get_ctx_params()
174 if (!OSSL_PARAM_get_size_t(p, &ctx->key_bits)) { in rc2_set_ctx_params()
194 || (ctx->key_bits = rc2_magic_to_keybits(num)) == 0) { in rc2_set_ctx_params()
206 ctx->base.keylen = ctx->key_bits / 8; in rc2_set_ctx_params()
242 ctx->key_bits = kbits; \
/third_party/mbedtls/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()
/third_party/mesa3d/src/amd/vulkan/radix_sort/
Dradix_sort_vk.c507 if ((info->count <= 1) || (info->key_bits == 0)) in radix_sort_vk_sort_devaddr()
577 uint32_t const key_bits = MIN_MACRO(uint32_t, info->key_bits, keyval_bits); in radix_sort_vk_sort_devaddr() local
578 uint32_t const passes = (key_bits + RS_RADIX_LOG2 - 1) / RS_RADIX_LOG2; in radix_sort_vk_sort_devaddr()
835 if (info->key_bits == 0) in radix_sort_vk_sort_indirect_devaddr()
906 uint32_t const key_bits = MIN_MACRO(uint32_t, info->key_bits, keyval_bits); in radix_sort_vk_sort_indirect_devaddr() local
907 uint32_t const passes = (key_bits + RS_RADIX_LOG2 - 1) / RS_RADIX_LOG2; in radix_sort_vk_sort_indirect_devaddr()
1195 .key_bits = info->key_bits, in radix_sort_vk_sort()
1239 .key_bits = info->key_bits, in radix_sort_vk_sort_indirect()
Dradix_sort_vk_devaddr.h52 uint32_t key_bits; member
76 uint32_t key_bits; member
Dradix_sort_vk.h297 uint32_t key_bits; member
357 uint32_t key_bits; member
/third_party/ffmpeg/libavutil/tests/
Dcast5.c46 static const int key_bits[3] = {128, 80, 40}; in main() local
54 av_cast5_init(cs, Key[j], key_bits[j]); in main()
89 av_cast5_init(cs, Key[j], key_bits[j]); in main()
/third_party/mbedtls/tests/suites/
Dtest_suite_psa_crypto_metadata.function192 psa_key_type_t key_type, size_t key_bits,
208 TEST_EQUAL( length, PSA_MAC_LENGTH( key_type, key_bits, alg ) );
218 psa_key_type_t key_type, size_t key_bits,
234 TEST_EQUAL( tag_length, PSA_AEAD_TAG_LENGTH( key_type, key_bits, alg ) );
299 size_t key_bits = key_bits_arg;
302 key_type, key_bits, length );
311 key_type, key_bits, n );
343 key_type, key_bits, n );
428 size_t key_bits = key_bits_arg;
431 key_type, key_bits, tag_length );
[all …]
/third_party/mbedtls/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 ) ) \
/third_party/mbedtls/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()

12