Searched refs:salt (Results 1 - 25 of 119) sorted by relevance

12345

/freebsd-10.1-release/lib/libcrypt/
H A Dcrypt.h35 char *crypt_des(const char *pw, const char *salt);
36 char *crypt_md5(const char *pw, const char *salt);
37 char *crypt_nthash(const char *pw, const char *salt);
38 char *crypt_blowfish(const char *pw, const char *salt);
39 char *crypt_sha256 (const char *pw, const char *salt);
40 char *crypt_sha512 (const char *pw, const char *salt);
H A Dcrypt.c102 * Hash the given password with the given salt. If the salt begins with a
107 crypt(const char *passwd, const char *salt) argument
115 if (cf->magic != NULL && strstr(salt, cf->magic) == salt)
116 return (cf->func(passwd, salt));
118 len = strlen(salt);
119 if ((len == 13 || len == 2) && strspn(salt, DES_SALT_ALPHABET) == len)
120 return (crypt_des(passwd, salt));
122 return (crypt_format->func(passwd, salt));
[all...]
/freebsd-10.1-release/crypto/heimdal/lib/kadm5/
H A Dkeys.c60 keys[i].salt = NULL;
77 if ((keys1[i].salt != NULL && keys2[j].salt == NULL)
78 || (keys1[i].salt == NULL && keys2[j].salt != NULL))
81 if (keys1[i].salt != NULL) {
82 if (keys1[i].salt->type != keys2[j].salt->type)
84 if (keys1[i].salt->salt
[all...]
H A Ddefault_keys.c58 if (keys[i].salt) {
59 printf(" salt: ");
61 switch (keys[i].salt->type) {
63 printf("pw-salt:");
66 printf("afs3-salt:");
69 printf("unknown salt: %d", keys[i].salt->type);
72 if (keys[i].salt->salt.length)
73 printf("%.*s", (int)keys[i].salt
[all...]
H A Drename_s.c64 /* fix salt */
66 Salt salt; local
68 memset(&salt, 0, sizeof(salt));
70 salt.type = hdb_pw_salt;
71 salt.salt = salt2.saltvalue;
73 if(ent.entry.keys.val[i].salt == NULL){
74 ent.entry.keys.val[i].salt =
75 malloc(sizeof(*ent.entry.keys.val[i].salt));
[all...]
/freebsd-10.1-release/crypto/heimdal/lib/hdb/
H A Dkeys.c49 if (keys[i].salt != NULL) {
50 free_Salt(keys[i].salt);
51 free(keys[i].salt);
52 keys[i].salt = NULL;
61 * of etype:salttype:salt, syntax of this if something like:
62 * [(des|des3|etype):](pw-salt|afs3)[:string], if etype is omitted it
65 * v5 == pw-salt, and
66 * v4 == des:pw-salt:
67 * afs or afs3 == des:afs3-salt
85 krb5_salt *salt, krb5_principa
83 parse_key_set(krb5_context context, const char *key, krb5_enctype **ret_enctypes, size_t *ret_num_enctypes, krb5_salt *salt, krb5_principal principal) argument
200 add_enctype_to_key_set(Key **key_set, size_t *nkeyset, krb5_enctype enctype, krb5_salt *salt) argument
279 krb5_salt salt; local
375 krb5_salt salt; local
[all...]
/freebsd-10.1-release/sys/geom/eli/
H A Dpkcs5v2.h31 void pkcs5v2_genkey(uint8_t *key, unsigned keylen, const uint8_t *salt,
/freebsd-10.1-release/crypto/openssl/crypto/asn1/
H A Dp5_pbe.c69 ASN1_SIMPLE(PBEPARAM, salt, ASN1_OCTET_STRING),
78 const unsigned char *salt, int saltlen)
97 if (!ASN1_STRING_set(pbe->salt, NULL, saltlen)) {
101 sstr = ASN1_STRING_data(pbe->salt);
102 if (salt)
103 memcpy(sstr, salt, saltlen);
129 const unsigned char *salt, int saltlen)
138 if (PKCS5_pbe_set0_algor(ret, alg, iter, salt, saltlen))
/freebsd-10.1-release/crypto/openssh/openbsd-compat/
H A Dxcrypt.c66 xcrypt(const char *password, const char *salt) argument
71 if (is_md5_salt(salt))
72 crypted = md5_crypt(password, salt);
74 crypted = crypt(password, salt);
77 crypted = bigcrypt(password, salt);
79 crypted = crypt(password, salt);
81 crypted = bigcrypt(password, salt);
83 crypted = crypt(password, salt);
H A Dport-uw.c56 char *salt; local
66 /* Encrypt the candidate password using the proper salt. */
67 salt = (pw_password[0] && pw_password[1]) ? pw_password : "xx";
75 result = ((strcmp(bigcrypt(password, salt), pw_password) == 0)
76 || (strcmp(osr5bigcrypt(password, salt), pw_password) == 0));
80 result = (strcmp(xcrypt(password, salt), pw_password) == 0);
/freebsd-10.1-release/contrib/ntp/lib/isc/
H A Diterated_hash.c29 const unsigned char *salt, int saltlength,
41 isc_sha1_update(&ctx, salt, saltlength);
27 isc_iterated_hash(unsigned char out[ISC_SHA1_DIGESTLENGTH], unsigned int hashalg, int iterations, const unsigned char *salt, int saltlength, const unsigned char *in, int inlength) argument
/freebsd-10.1-release/crypto/openssl/crypto/pkcs12/
H A Dp12_crpt.c76 unsigned char *salt; local
97 salt = pbe->salt->data;
98 saltlen = pbe->salt->length;
99 if (!PKCS12_key_gen(pass, passlen, salt, saltlen, PKCS12_KEY_ID,
105 if (!PKCS12_key_gen(pass, passlen, salt, saltlen, PKCS12_IV_ID,
H A Dp12_mutl.c74 unsigned char key[EVP_MAX_MD_SIZE], *salt; local
83 salt = p12->mac->salt->data;
84 saltlen = p12->mac->salt->length;
96 if (!PKCS12_key_gen(pass, passlen, salt, saltlen, PKCS12_MAC_ID, iter,
135 unsigned char *salt, int saltlen, int iter,
143 if (PKCS12_setup_mac(p12, iter, salt, saltlen, md_type) == PKCS12_ERROR) {
159 int PKCS12_setup_mac(PKCS12 *p12, int iter, unsigned char *salt, int saltlen, argument
176 p12->mac->salt->length = saltlen;
177 if (!(p12->mac->salt
134 PKCS12_set_mac(PKCS12 *p12, const char *pass, int passlen, unsigned char *salt, int saltlen, int iter, const EVP_MD *md_type) argument
[all...]
H A Dp12_p8e.c66 unsigned char *salt, int saltlen, int iter,
78 pbe = PKCS5_pbe2_set(cipher, iter, salt, saltlen);
80 pbe = PKCS5_pbe_set(pbe_nid, iter, salt, saltlen);
64 PKCS8_encrypt(int pbe_nid, const EVP_CIPHER *cipher, const char *pass, int passlen, unsigned char *salt, int saltlen, int iter, PKCS8_PRIV_KEY_INFO *p8inf) argument
/freebsd-10.1-release/secure/lib/libcrypt/
H A Dcrypt-blowfish.c40 * 2. state := ExpandKey (state, salt, password)
43 * state := ExpandKey (state, 0, salt)
47 * 6. RETURN Concatenate (salt, ctext);
72 #define BCRYPT_MINLOGROUNDS 4 /* we have log2(rounds) in salt */
135 /* We handle $Vers$log2(NumRounds)$salt+passwd$
139 crypt_blowfish(const char *key, const char *salt) argument
156 if (*salt == '$') {
158 salt++;
160 if (*salt > BCRYPT_VERSION) {
166 if (salt[
[all...]
/freebsd-10.1-release/crypto/heimdal/kdc/
H A Dstring2key.c74 krb5_salt salt,
82 ret = krb5_string_to_key_salt(context, enctype, pw, salt, &key);
102 krb5_salt salt; local
167 krb5_get_pw_salt(context, princ, &salt);
168 tokey(context, etype, password, salt, "Kerberos 5 (%s)");
169 krb5_free_salt(context, salt);
172 salt.salttype = KRB5_PW_SALT;
173 salt.saltvalue.length = 0;
174 salt.saltvalue.data = NULL;
175 tokey(context, ETYPE_DES_CBC_MD5, password, salt, "Kerbero
71 tokey(krb5_context context, krb5_enctype enctype, const char *pw, krb5_salt salt, const char *label) argument
[all...]
H A Dmit_dump.c62 foreach version 0 to key data version - 1 (a key or a salt)
155 Salt *salt = ent->keys.val[key_num].salt; local
156 /* fix salt type */
157 switch((int)salt->type) {
159 salt->type = KRB5_PADATA_PW_SALT;
162 krb5_data_free(&salt->salt);
163 salt->type = KRB5_PADATA_PW_SALT;
174 ret = krb5_data_alloc (&salt
[all...]
/freebsd-10.1-release/release/picobsd/tinyware/passwd/
H A Dlocal_passwd.c106 char buf[_PASSWORD_LEN+1], salt[32]; local
170 salt[0] = _PASSWORD_EFMT1;
171 to64(&salt[1], (long)(29 * 25), 4);
172 to64(&salt[5], random(), 4);
173 salt[9] = '\0';
175 /* Make a good size salt for algorithms that can use it. */
185 to64(&salt[0], random(), 3);
186 to64(&salt[3], tv.tv_usec, 3);
187 to64(&salt[6], tv.tv_sec, 2);
188 to64(&salt[
[all...]
/freebsd-10.1-release/contrib/subversion/subversion/libsvn_subr/
H A Dcrypto.h64 The salt used for PBKDF2 is returned in SALT, and the IV used for
77 const svn_string_t **salt,
93 const svn_string_t *salt,
103 Set *IV and *SALT to the initialization vector and salt used for
114 const svn_string_t **salt,
133 const svn_string_t *salt,
/freebsd-10.1-release/contrib/ntp/lib/isc/include/isc/
H A Diterated_hash.h41 const unsigned char *salt, int saltlength,
/freebsd-10.1-release/crypto/heimdal/lib/krb5/
H A Dsalt.c99 krb5_salt *salt)
106 salt->salttype = KRB5_PW_SALT;
110 ret = krb5_data_alloc (&salt->saltvalue, len);
113 p = salt->saltvalue.data;
127 krb5_salt salt)
129 krb5_data_free(&salt.saltvalue);
141 krb5_salt salt; local
143 ret = krb5_get_pw_salt(context, principal, &salt);
146 ret = krb5_string_to_key_data_salt(context, enctype, password, salt, key);
147 krb5_free_salt(context, salt);
97 krb5_get_pw_salt(krb5_context context, krb5_const_principal principal, krb5_salt *salt) argument
126 krb5_free_salt(krb5_context context, krb5_salt salt) argument
165 krb5_string_to_key_data_salt(krb5_context context, krb5_enctype enctype, krb5_data password, krb5_salt salt, krb5_keyblock *key) argument
184 krb5_string_to_key_data_salt_opaque(krb5_context context, krb5_enctype enctype, krb5_data password, krb5_salt salt, krb5_data opaque, krb5_keyblock *key) argument
216 krb5_string_to_key_salt(krb5_context context, krb5_enctype enctype, const char *password, krb5_salt salt, krb5_keyblock *key) argument
229 krb5_string_to_key_salt_opaque(krb5_context context, krb5_enctype enctype, const char *password, krb5_salt salt, krb5_data opaque, krb5_keyblock *key) argument
[all...]
H A Dsalt-des3.c41 krb5_salt salt,
51 len = password.length + salt.saltvalue.length;
58 memcpy(str + password.length, salt.saltvalue.data, salt.saltvalue.length);
106 krb5_salt salt,
111 size_t len = password.length + salt.saltvalue.length;
120 memcpy(s + password.length, salt.saltvalue.data, salt.saltvalue.length);
136 "pw-salt",
146 "pw-salt",
38 DES3_string_to_key(krb5_context context, krb5_enctype enctype, krb5_data password, krb5_salt salt, krb5_data opaque, krb5_keyblock *key) argument
103 DES3_string_to_key_derived(krb5_context context, krb5_enctype enctype, krb5_data password, krb5_salt salt, krb5_data opaque, krb5_keyblock *key) argument
[all...]
/freebsd-10.1-release/crypto/openssl/crypto/evp/
H A Dp5_crpt2.c83 const unsigned char *salt, int saltlen, int iter,
123 if (!HMAC_Update(&hctx, salt, saltlen)
156 h__dump(salt, saltlen);
165 const unsigned char *salt, int saltlen, int iter,
168 return PKCS5_PBKDF2_HMAC(pass, passlen, salt, saltlen, iter, EVP_sha1(),
176 unsigned char salt[] = { 0x12, 0x34, 0x56, 0x78 }; local
177 PKCS5_PBKDF2_HMAC_SHA1("password", -1, salt, 4, 5, 4, out);
251 unsigned char *salt, key[EVP_MAX_KEY_LENGTH]; local
307 if (kdf->salt->type != V_ASN1_OCTET_STRING) {
313 salt
82 PKCS5_PBKDF2_HMAC(const char *pass, int passlen, const unsigned char *salt, int saltlen, int iter, const EVP_MD *digest, int keylen, unsigned char *out) argument
164 PKCS5_PBKDF2_HMAC_SHA1(const char *pass, int passlen, const unsigned char *salt, int saltlen, int iter, int keylen, unsigned char *out) argument
[all...]
/freebsd-10.1-release/crypto/openssl/crypto/des/
H A Dfcrypt.c28 * Added more values to handle illegal salt values the way normal crypt()
61 char *DES_crypt(const char *buf, const char *salt) argument
66 return (DES_fcrypt(buf, salt, buff));
72 /* Copy at most 2 chars of salt */
73 if ((e_salt[0] = salt[0]) != '\0')
74 e_salt[1] = salt[1];
98 char *DES_fcrypt(const char *buf, const char *salt, char *ret) argument
118 x = ret[0] = ((salt[0] == '\0') ? 'A' : salt[0]);
120 x = ret[1] = ((salt[
[all...]
/freebsd-10.1-release/contrib/apr-util/include/
H A Dapr_md5.h135 * @param salt The salt string to use for the encoding
139 APU_DECLARE(apr_status_t) apr_md5_encode(const char *password, const char *salt,
146 * @param salt Pointer to binary data to be used as salt for the encoding
147 * @param salt_len The size of the salt data (must be >= 16)
153 const unsigned char *salt,

Completed in 389 milliseconds

12345