/frameworks/base/tools/obbtool/ |
pbkdf2gen.cpp | 29 * Will print out the salt and key in hex. 50 unsigned char salt[SALT_LEN]; local 52 if (read(fd, &salt, SALT_LEN) != SALT_LEN) { 53 fprintf(stderr, "Could not read salt from /dev/urandom: %s\n", strerror(errno)); 61 if (PKCS5_PBKDF2_HMAC_SHA1(argv[1], strlen(argv[1]), salt, SALT_LEN, 67 printf("salt="); 69 printf("%02x", salt[i]);
|
Main.cpp | 44 {"salt", required_argument, NULL, 's'}, 57 memset(&salt, 0, sizeof(salt)); 64 unsigned char salt[SALT_LEN]; member in class:PackageInfo 82 " -s <8 byte hex salt> sets the crypto key salt (if encrypted)\n" 103 obb->setSalt(info->salt, SALT_LEN); 142 printf(" Salt: "); 145 const unsigned char* salt = obb->getSalt(&saltLen); local 146 if (salt != NULL) [all...] |
/external/openssl/crypto/pkcs12/ |
p12_crpt.c | 74 unsigned char *salt; local 93 salt = pbe->salt->data; 94 saltlen = pbe->salt->length; 95 if (!PKCS12_key_gen (pass, passlen, salt, saltlen, PKCS12_KEY_ID, 101 if (!PKCS12_key_gen (pass, passlen, salt, saltlen, PKCS12_IV_ID,
|
p12_mutl.c | 72 unsigned char key[EVP_MAX_MD_SIZE], *salt; local 82 salt = p12->mac->salt->data; 83 saltlen = p12->mac->salt->length; 94 if(!PKCS12_key_gen (pass, passlen, salt, saltlen, PKCS12_MAC_ID, iter, 129 unsigned char *salt, int saltlen, int iter, const EVP_MD *md_type) 135 if (PKCS12_setup_mac (p12, iter, salt, saltlen, md_type) == 152 int PKCS12_setup_mac(PKCS12 *p12, int iter, unsigned char *salt, int saltlen, 167 p12->mac->salt->length = saltlen; 168 if (!(p12->mac->salt->data = OPENSSL_malloc (saltlen))) [all...] |
/libcore/luni/src/main/java/javax/crypto/spec/ |
PBEParameterSpec.java | 32 private final byte[] salt; field in class:PBEParameterSpec 36 * Creates a new <code>PBEParameterSpec</code> with the specified salt and 39 * @param salt 40 * the salt. 44 * if salt is null. 46 public PBEParameterSpec(byte[] salt, int iterationCount) { 47 if (salt == null) { 48 throw new NullPointerException("salt == null"); 50 this.salt = new byte[salt.length] [all...] |
PBEKeySpec.java | 33 private final byte[] salt; field in class:PBEKeySpec 50 salt = null; 56 * Creates a new <code>PBEKeySpec</code> with the specified password, salt, 61 * @param salt 62 * the salt. 68 * if the salt is null. 70 * if the salt is empty, iteration count is zero or negative or 73 public PBEKeySpec(char[] password, byte[] salt, int iterationCount, 75 if (salt == null) { 76 throw new NullPointerException("salt == null") [all...] |
/external/bouncycastle/src/main/java/org/bouncycastle/asn1/pkcs/ |
PBEParameter.java | 18 ASN1OctetString salt; field in class:PBEParameter 21 byte[] salt, 24 if (salt.length != 8) 26 throw new IllegalArgumentException("salt length must be 8"); 28 this.salt = new DEROctetString(salt); 35 salt = (ASN1OctetString)seq.getObjectAt(0); 61 return salt.getOctets(); 68 v.add(salt);
|
MacData.java | 21 byte[] salt; field in class:MacData 44 this.salt = ((ASN1OctetString)seq.getObjectAt(1)).getOctets(); 58 byte[] salt, 62 this.salt = salt; 73 return salt; 97 v.add(new DEROctetString(salt));
|
/external/bouncycastle/src/main/java/org/bouncycastle/crypto/ |
PBEParametersGenerator.java | 11 protected byte[] salt; field in class:PBEParametersGenerator 25 * @param salt the salt to be mixed with the password. 31 byte[] salt, 35 this.salt = salt; 50 * return the salt byte array. 52 * @return the salt byte array. 56 return salt;
|
/external/chromium/crypto/ |
symmetric_key_unittest.cc | 71 const char* salt; member in struct:PBKDF2TestVector 84 // The OS X crypto libraries have minimum salt and iteration requirements 86 if (strlen(test_data.salt) < 8 || test_data.rounds < 1000) { 95 test_data.password, test_data.salt, 113 "salt", 121 "salt", 129 "salt", 139 "salt",
|
/external/dropbear/libtomcrypt/src/pk/pkcs1/ |
pkcs_1_pss_decode.c | 26 @param saltlen The length of the salt used (octets) 37 unsigned char *DB, *mask, *salt, *hash; local 62 /* allocate ram for DB/mask/salt/hash of size modulus_len */ 65 salt = XMALLOC(modulus_len); 67 if (DB == NULL || mask == NULL || salt == NULL || hash == NULL) { 74 if (salt != NULL) { 75 XFREE(salt); 117 /* DB = PS || 0x01 || salt, PS == modulus_len - saltlen - hLen - 2 zero bytes */ 133 /* M = (eight) 0x00 || msghash || salt, mask = H(M) */ 161 zeromem(salt, modulus_len); [all...] |
pkcs_1_pss_encode.c | 24 @param saltlen The length of the salt desired (octets) 39 unsigned char *DB, *mask, *salt, *hash; local 64 /* allocate ram for DB/mask/salt/hash of size modulus_len */ 67 salt = XMALLOC(modulus_len); 69 if (DB == NULL || mask == NULL || salt == NULL || hash == NULL) { 76 if (salt != NULL) { 77 XFREE(salt); 86 /* generate random salt */ 88 if (prng_descriptor[prng_idx].read(salt, saltlen, prng) != saltlen) { 94 /* M = (eight) 0x00 || msghash || salt, hash = H(M) * [all...] |
/external/openssl/crypto/evp/ |
p5_crpt.c | 82 unsigned char *salt; local 101 salt = pbe->salt->data; 102 saltlen = pbe->salt->length; 110 EVP_DigestUpdate(&ctx, salt, saltlen);
|
p5_crpt2.c | 80 const unsigned char *salt, int saltlen, int iter, 114 HMAC_Update(&hctx, salt, saltlen); 133 fprintf(stderr, "Salt:\n"); 134 h__dump (salt, saltlen); 143 const unsigned char *salt, int saltlen, int iter, 146 return PKCS5_PBKDF2_HMAC(pass, passlen, salt, saltlen, iter, EVP_sha1(), 154 unsigned char salt[] = {0x12, 0x34, 0x56, 0x78}; local 155 PKCS5_PBKDF2_HMAC_SHA1("password", -1, salt, 4, 5, 4, out); 171 unsigned char *salt, key[EVP_MAX_KEY_LENGTH]; local 268 if(kdf->salt->type != V_ASN1_OCTET_STRING) [all...] |
/external/openssl/crypto/rsa/ |
rsa_pss.c | 90 * -2 salt length is autorecovered from signature 179 unsigned char *H, *salt = NULL, *p; local 188 * -2 salt length is maximized 218 salt = OPENSSL_malloc(sLen); 219 if (!salt) 225 if (RAND_bytes(salt, sLen) <= 0) 235 EVP_DigestUpdate(&ctx, salt, sLen); 254 *p++ ^= salt[i]; 266 if (salt) 267 OPENSSL_free(salt); [all...] |
/external/chromium/chrome/common/ |
visitedlink_common.h | 15 // number of bytes in the salt 42 // a salt value for the links on one computer so that an attacker can not 90 uint8 salt[LINK_SALT_LENGTH]; member in struct:VisitedLinkCommon::SharedHeader 104 // pass the salt as a parameter. See the non-static version above if you 105 // want to use the current class' salt. 108 const uint8 salt[LINK_SALT_LENGTH]); 128 // salt used for each URL when computing the fingerprint
|
/external/srtp/test/ |
dtls_srtp_driver.c | 126 uint8_t salt[SRTP_MAX_KEY_LEN]; local 176 memset(salt, 0xee, salt_len); 177 append_salt_to_key(key, key_len, salt, salt_len);
|
/frameworks/base/core/java/android/content/res/ |
ObbInfo.java | 52 * The salt for the encryption algorithm. 56 public byte[] salt; field in class:ObbInfo 85 dest.writeByteArray(salt); 104 salt = source.createByteArray();
|
/frameworks/base/core/jni/ |
android_content_res_ObbScanner.cpp | 36 jfieldID salt; member in struct:android::__anon14307 66 const unsigned char* salt = obb->getSalt(&saltLen); local 69 env->SetByteArrayRegion(saltArray, 0, saltLen, (jbyte*)salt); 70 env->SetObjectField(obbInfo, gObbInfoClassInfo.salt, saltArray); 102 GET_FIELD_ID(gObbInfoClassInfo.salt, clazz, 103 "salt", "[B");
|
/frameworks/base/libs/utils/tests/ |
ObbFile_test.cpp | 68 unsigned char salt[SALT_SIZE] = {0x01, 0x10, 0x55, 0xAA, 0xFF, 0x00, 0x5A, 0xA5}; local 69 EXPECT_TRUE(mObbFile->setSalt(salt, SALT_SIZE)) 70 << "Salt should be successfully set"; 89 EXPECT_EQ(sizeof(salt), saltLen) 90 << "salt sizes were not the same"; 92 for (int i = 0; i < sizeof(salt); i++) { 93 EXPECT_EQ(salt[i], newSalt[i]) 94 << "salt character " << i << " should be equal"; 96 EXPECT_TRUE(memcmp(newSalt, salt, sizeof(salt)) == 0 [all...] |
/external/wpa_supplicant_8/src/tls/ |
pkcs5.c | 29 u8 salt[8]; member in struct:pkcs5_params 83 * salt OCTET STRING SIZE(8), 98 /* salt OCTET STRING SIZE(8) */ 104 "(salt) - found class %d tag 0x%x size %d", 109 os_memcpy(params->salt, hdr.payload, hdr.length); 111 wpa_hexdump(MSG_DEBUG, "PKCS #5: salt", 112 params->salt, params->salt_len); 158 addr[1] = params->salt;
|
/external/chromium/chrome/browser/autofill/ |
autofill_ie_toolbar_import_win.cc | 37 const wchar_t* const kSaltValue = L"salt"; 53 bool IsEmptySalt(std::wstring const& salt) { 54 // Empty salt in IE Toolbar is \x1\x2...\x14 55 if (salt.length() != 20) 57 for (size_t i = 0; i < salt.length(); ++i) { 58 if (salt[i] != i + 1) 231 string16 salt; local 235 salt = ReadAndDecryptValue(&cc_key, kSaltValue); 239 if (password_hash.empty() && IsEmptySalt(salt)) {
|
/external/chromium/chrome/browser/chromeos/cros/ |
cryptohome_library.cc | 344 CryptohomeBlob salt = CryptohomeBlob(); local 345 salt.push_back(0); 346 salt.push_back(0); 347 return salt;
|
/external/chromium/chrome/browser/sync/util/ |
user_settings.cc | 69 static const char SALT[] = "salt2"; 356 const string salt = APEncode(string(binary_salt, sizeof(binary_salt))); local 358 md5.AddData(salt.data(), salt.size()); 381 statement.bind_string(1, SALT); 382 statement.bind_string(2, salt); 401 query.bind_string(2, SALT); 403 string salt; local 407 if (key == SALT) 408 salt = query.column_string(1) [all...] |
/external/grub/stage2/ |
md5.c | 205 CRYPTED must have a salt. */ 210 char *salt = crypted + 3; /* skip $1$ header */ local 224 saltlen = strstr (salt, "$") - salt; 228 char *end = strstr (salt, "$"); 229 if (end && end - salt < 8) 230 saltlen = end - salt; 234 salt[saltlen] = '$'; 239 md5_update (salt, saltlen); 268 md5_update (salt, saltlen) [all...] |