Home
last modified time | relevance | path

Searched refs:salt_len (Results 1 – 25 of 33) sorted by relevance

12

/external/boringssl/src/crypto/pkcs8/
Dpkcs8.c100 size_t salt_len, uint8_t id, unsigned iterations, in pkcs12_key_gen() argument
140 if (salt_len + block_size - 1 < salt_len || in pkcs12_key_gen()
145 size_t S_len = block_size * ((salt_len + block_size - 1) / block_size); in pkcs12_key_gen()
160 I[i] = salt[i % salt_len]; in pkcs12_key_gen()
226 const uint8_t *salt, size_t salt_len, in pkcs12_pbe_cipher_init() argument
233 if (!pkcs12_key_gen(pass, pass_len, salt, salt_len, PKCS12_KEY_ID, iterations, in pkcs12_pbe_cipher_init()
235 !pkcs12_key_gen(pass, pass_len, salt, salt_len, PKCS12_IV_ID, iterations, in pkcs12_pbe_cipher_init()
323 size_t salt_len) { in pkcs12_pbe_encrypt_init() argument
337 !CBB_add_bytes(&salt_cbb, salt, salt_len) || in pkcs12_pbe_encrypt_init()
344 salt_len, 1 /* encrypt */); in pkcs12_pbe_encrypt_init()
[all …]
Dp5_pbev2.c145 size_t salt_len, const uint8_t *iv, in pkcs5_pbe2_cipher_init() argument
153 int ret = PKCS5_PBKDF2_HMAC_SHA1(pass, pass_len, salt, salt_len, iterations, in pkcs5_pbe2_cipher_init()
163 const uint8_t *salt, size_t salt_len) { in PKCS5_pbe2_encrypt_init() argument
188 !CBB_add_bytes(&salt_cbb, salt, salt_len) || in PKCS5_pbe2_encrypt_init()
205 salt_len, iv, EVP_CIPHER_iv_length(cipher), in PKCS5_pbe2_encrypt_init()
Dinternal.h83 size_t salt_len, uint8_t id, unsigned iterations,
113 const uint8_t *salt, size_t salt_len);
Dpkcs8_test.cc182 size_t salt_len, int iterations) { in TestRoundTrip() argument
205 pbe_nid, cipher, password, -1, salt, salt_len, iterations, key.get())); in TestRoundTrip()
/external/f2fs-tools/tools/
Df2fscrypt.c232 size_t salt_len; member
239 static struct salt *find_by_salt(unsigned char *salt, size_t salt_len) in find_by_salt() argument
245 if ((p->salt_len == salt_len) && in find_by_salt()
246 !memcmp(p->salt, salt, salt_len)) in find_by_salt()
251 static void add_salt(unsigned char *salt, size_t salt_len) in add_salt() argument
253 if (find_by_salt(salt, salt_len)) in add_salt()
264 salt_list[num_salt].salt_len = salt_len; in add_salt()
323 int fd, ret, salt_len = 0; in parse_salt() local
329 salt_len = strlen(cp); in parse_salt()
330 if (salt_len >= F2FS_MAX_SALT_SIZE) in parse_salt()
[all …]
/external/e2fsprogs/misc/
De4crypt.c185 size_t salt_len; member
192 static struct salt *find_by_salt(unsigned char *salt, size_t salt_len) in find_by_salt() argument
198 if ((p->salt_len == salt_len) && in find_by_salt()
199 !memcmp(p->salt, salt, salt_len)) in find_by_salt()
204 static void add_salt(unsigned char *salt, size_t salt_len) in add_salt() argument
206 if (find_by_salt(salt, salt_len)) in add_salt()
217 salt_list[num_salt].salt_len = salt_len; in add_salt()
278 int fd, ret, salt_len = 0; in parse_salt() local
284 salt_len = strlen(cp); in parse_salt()
285 if (salt_len >= EXT4_MAX_SALT_SIZE) in parse_salt()
[all …]
/external/syslinux/gpxe/src/crypto/
Dsha1extra.c95 const void *salt, size_t salt_len, in pbkdf2_sha1_f() argument
99 u8 in[salt_len + 4]; /* input buffer to first round */ in pbkdf2_sha1_f()
109 memcpy ( in, salt, salt_len ); in pbkdf2_sha1_f()
110 memcpy ( in + salt_len, &blocknr, 4 ); in pbkdf2_sha1_f()
146 const void *salt, size_t salt_len, in pbkdf2_sha1() argument
154 pbkdf2_sha1_f ( passphrase, pass_len, salt, salt_len, in pbkdf2_sha1()
/external/syslinux/com32/libutil/
Dsha256crypt.c300 size_t salt_len; in sha256_crypt_r() local
330 salt_len = MIN(strcspn(salt, "$"), SALT_LEN_MAX); in sha256_crypt_r()
341 char *tmp = (char *)alloca(salt_len + __alignof__(uint32_t)); in sha256_crypt_r()
344 salt, salt_len); in sha256_crypt_r()
356 sha256_process_bytes(salt, salt_len, &ctx); in sha256_crypt_r()
366 sha256_process_bytes(salt, salt_len, &alt_ctx); in sha256_crypt_r()
412 sha256_process_bytes(salt, salt_len, &alt_ctx); in sha256_crypt_r()
418 cp = s_bytes = alloca(salt_len); in sha256_crypt_r()
419 for (cnt = salt_len; cnt >= 32; cnt -= 32) in sha256_crypt_r()
437 sha256_process_bytes(s_bytes, salt_len, &ctx); in sha256_crypt_r()
[all …]
Dsha512crypt.c335 size_t salt_len; in sha512_crypt_r() local
365 salt_len = MIN(strcspn(salt, "$"), SALT_LEN_MAX); in sha512_crypt_r()
376 char *tmp = (char *)alloca(salt_len + __alignof__(uint64_t)); in sha512_crypt_r()
379 salt, salt_len); in sha512_crypt_r()
391 sha512_process_bytes(salt, salt_len, &ctx); in sha512_crypt_r()
401 sha512_process_bytes(salt, salt_len, &alt_ctx); in sha512_crypt_r()
447 sha512_process_bytes(salt, salt_len, &alt_ctx); in sha512_crypt_r()
453 cp = s_bytes = alloca(salt_len); in sha512_crypt_r()
454 for (cnt = salt_len; cnt >= 64; cnt -= 64) in sha512_crypt_r()
472 sha512_process_bytes(s_bytes, salt_len, &ctx); in sha512_crypt_r()
[all …]
/external/wpa_supplicant_8/src/tls/
Dpkcs5.c27 size_t salt_len; member
187 params->salt_len = hdr.length; in pkcs5_get_params_pbes2()
188 wpa_hexdump(MSG_DEBUG, "PKCS #5: salt", params->salt, params->salt_len); in pkcs5_get_params_pbes2()
348 params->salt_len = hdr.length; in pkcs5_get_params()
350 params->salt, params->salt_len); in pkcs5_get_params()
395 params->salt, params->salt_len); in pkcs5_crypto_init_pbes2()
398 if (pbkdf2_sha1(passwd, params->salt, params->salt_len, in pkcs5_crypto_init_pbes2()
423 size_t salt_len, u8 id, unsigned int iter, in pkcs12_key_gen() argument
441 S_len = v * ((salt_len + v - 1) / v); in pkcs12_key_gen()
447 if (salt_len) { in pkcs12_key_gen()
[all …]
/external/boringssl/src/crypto/evp/
Dpbkdf.c66 const uint8_t *salt, size_t salt_len, unsigned iterations, in PKCS5_PBKDF2_HMAC() argument
94 !HMAC_Update(&hctx, salt, salt_len) || in PKCS5_PBKDF2_HMAC()
141 const uint8_t *salt, size_t salt_len, in PKCS5_PBKDF2_HMAC_SHA1() argument
144 return PKCS5_PBKDF2_HMAC(password, password_len, salt, salt_len, iterations, in PKCS5_PBKDF2_HMAC_SHA1()
Dpbkdf_test.cc129 const size_t salt_len = sizeof(kSalt); in TEST() local
136 ASSERT_TRUE(PKCS5_PBKDF2_HMAC(kPassword, password_len, kSalt, salt_len, in TEST()
144 ASSERT_FALSE(PKCS5_PBKDF2_HMAC(kPassword, password_len, kSalt, salt_len, in TEST()
/external/boringssl/src/crypto/hkdf/
Dhkdf.c28 size_t salt_len, const uint8_t *info, size_t info_len) { in HKDF() argument
34 salt_len) || in HKDF()
44 size_t salt_len) { in HKDF_extract() argument
50 if (HMAC(digest, salt, salt_len, secret, secret_len, out_key, &len) == NULL) { in HKDF_extract()
Dhkdf_test.cc29 const size_t salt_len; member
255 test->ikm_len, test->salt, test->salt_len)); in TEST()
264 test->ikm_len, test->salt, test->salt_len, test->info, in TEST()
/external/avb/libavb/
Davb_hash_descriptor.c45 dest->salt_len = avb_be32toh(dest->salt_len); in avb_hash_descriptor_validate_and_byteswap()
52 !avb_safe_add_to(&expected_size, dest->salt_len) || in avb_hash_descriptor_validate_and_byteswap()
Davb_hashtree_descriptor.c53 dest->salt_len = avb_be32toh(dest->salt_len); in avb_hashtree_descriptor_validate_and_byteswap()
60 !avb_safe_add_to(&expected_size, dest->salt_len) || in avb_hashtree_descriptor_validate_and_byteswap()
Davb_hash_descriptor.h69 uint32_t salt_len; member
Davb_hashtree_descriptor.h79 uint32_t salt_len; member
/external/boringssl/src/include/openssl/
Dhkdf.h37 const uint8_t *salt, size_t salt_len,
47 size_t salt_len);
Dpkcs8.h87 const uint8_t *salt, size_t salt_len,
96 size_t pass_len, const uint8_t *salt, size_t salt_len, int iterations,
Devp.h420 const uint8_t *salt, size_t salt_len,
428 const uint8_t *salt, size_t salt_len,
441 const uint8_t *salt, size_t salt_len,
656 int salt_len);
/external/avb/test/
Davb_util_unittest.cc167 h.salt_len = htobe32(10); in TEST_F()
219 EXPECT_EQ(10UL, s.salt_len); in TEST_F()
234 bad.salt_len = htobe32(30); in TEST_F()
254 h.salt_len = htobe32(10); in TEST_F()
262 EXPECT_EQ(10UL, s.salt_len); in TEST_F()
277 bad.salt_len = htobe32(30); in TEST_F()
Davbtool_unittest.cc578 EXPECT_EQ(4UL, d.salt_len); in AddHashFooterTest()
587 EXPECT_EQ("d00df00d", mem_to_hexstring(desc_end + o, d.salt_len)); in AddHashFooterTest()
588 o += d.salt_len; in AddHashFooterTest()
1056 EXPECT_EQ(4UL, d.salt_len); in AddHashtreeFooterTest()
1065 EXPECT_EQ("d00df00d", mem_to_hexstring(desc_end + o, d.salt_len)); in AddHashtreeFooterTest()
1066 o += d.salt_len; in AddHashtreeFooterTest()
1285 EXPECT_EQ(4UL, d.salt_len); in AddHashtreeFooterFECTest()
1294 EXPECT_EQ("d00df00d", mem_to_hexstring(desc_end + o, d.salt_len)); in AddHashtreeFooterFECTest()
1295 o += d.salt_len; in AddHashtreeFooterFECTest()
/external/syslinux/gpxe/src/include/gpxe/
Dsha1.h21 const void *salt, size_t salt_len,
/external/libchrome/crypto/
Dsignature_verifier.h79 int salt_len,

12