Lines Matching refs:sparam
161 SCRYPT_PARAMS *sparam = SCRYPT_PARAMS_new(); in pkcs5_scrypt_set() local
163 if (sparam == NULL) { in pkcs5_scrypt_set()
172 if (ASN1_STRING_set(sparam->salt, salt, saltlen) == 0) { in pkcs5_scrypt_set()
177 if (salt == NULL && RAND_bytes(sparam->salt->data, saltlen) <= 0) in pkcs5_scrypt_set()
180 if (ASN1_INTEGER_set_uint64(sparam->costParameter, N) == 0) { in pkcs5_scrypt_set()
185 if (ASN1_INTEGER_set_uint64(sparam->blockSize, r) == 0) { in pkcs5_scrypt_set()
190 if (ASN1_INTEGER_set_uint64(sparam->parallelizationParameter, p) == 0) { in pkcs5_scrypt_set()
198 sparam->keyLength = ASN1_INTEGER_new(); in pkcs5_scrypt_set()
199 if (sparam->keyLength == NULL) { in pkcs5_scrypt_set()
203 if (ASN1_INTEGER_set_int64(sparam->keyLength, keylen) == 0) { in pkcs5_scrypt_set()
221 if (ASN1_TYPE_pack_sequence(ASN1_ITEM_rptr(SCRYPT_PARAMS), sparam, in pkcs5_scrypt_set()
227 SCRYPT_PARAMS_free(sparam); in pkcs5_scrypt_set()
231 SCRYPT_PARAMS_free(sparam); in pkcs5_scrypt_set()
246 SCRYPT_PARAMS *sparam = NULL; in PKCS5_v2_scrypt_keyivgen_ex() local
255 sparam = ASN1_TYPE_unpack_sequence(ASN1_ITEM_rptr(SCRYPT_PARAMS), param); in PKCS5_v2_scrypt_keyivgen_ex()
257 if (sparam == NULL) { in PKCS5_v2_scrypt_keyivgen_ex()
271 if (sparam->keyLength) { in PKCS5_v2_scrypt_keyivgen_ex()
273 if ((ASN1_INTEGER_get_uint64(&spkeylen, sparam->keyLength) == 0) in PKCS5_v2_scrypt_keyivgen_ex()
280 if (ASN1_INTEGER_get_uint64(&N, sparam->costParameter) == 0 in PKCS5_v2_scrypt_keyivgen_ex()
281 || ASN1_INTEGER_get_uint64(&r, sparam->blockSize) == 0 in PKCS5_v2_scrypt_keyivgen_ex()
282 || ASN1_INTEGER_get_uint64(&p, sparam->parallelizationParameter) == 0 in PKCS5_v2_scrypt_keyivgen_ex()
291 salt = sparam->salt->data; in PKCS5_v2_scrypt_keyivgen_ex()
292 saltlen = sparam->salt->length; in PKCS5_v2_scrypt_keyivgen_ex()
300 SCRYPT_PARAMS_free(sparam); in PKCS5_v2_scrypt_keyivgen_ex()