Searched refs:priv_key (Results 1 - 25 of 33) sorted by relevance

12

/external/boringssl/src/crypto/dh/
H A Ddh_impl.c184 BIGNUM *pub_key = NULL, *priv_key = NULL; local
192 if (dh->priv_key == NULL) {
193 priv_key = BN_new();
194 if (priv_key == NULL) {
199 priv_key = dh->priv_key;
220 if (!BN_rand_range(priv_key, dh->q)) {
223 } while (BN_is_zero(priv_key) || BN_is_one(priv_key));
228 if (!BN_rand(priv_key,
[all...]
H A Ddh.c138 if (dh->priv_key != NULL) BN_clear_free(dh->priv_key);
H A Ddh_test.cc155 BN_print_fp(stdout, a->priv_key);
164 BN_print_fp(stdout, b->priv_key);
441 dhA->priv_key = BN_bin2bn(td->xA, td->xA_len, nullptr);
444 dhB->priv_key = BN_bin2bn(td->xB, td->xB_len, nullptr);
447 if (!dhA->priv_key || !dhA->pub_key || !dhB->priv_key || !dhB->pub_key) {
/external/boringssl/src/crypto/ec/
H A Dec_key.c159 BN_clear_free(r->priv_key);
192 if (src->priv_key) {
193 if (dest->priv_key == NULL) {
194 dest->priv_key = BN_new();
195 if (dest->priv_key == NULL) {
199 if (!BN_copy(dest->priv_key, src->priv_key)) {
256 return key->priv_key;
259 int EC_KEY_set_private_key(EC_KEY *key, const BIGNUM *priv_key) { argument
260 BN_clear_free(key->priv_key);
421 BIGNUM *priv_key = NULL, *order = NULL; local
[all...]
H A Dec_asn1.c287 EC_PRIVATEKEY *priv_key = NULL; local
289 priv_key = d2i_EC_PRIVATEKEY(NULL, in, len);
290 if (priv_key == NULL) {
305 if (priv_key->parameters) {
307 ret->group = ec_asn1_pkparameters2group(priv_key->parameters);
315 ret->version = priv_key->version;
317 if (priv_key->privateKey) {
318 ret->priv_key =
319 BN_bin2bn(M_ASN1_STRING_data(priv_key->privateKey),
320 M_ASN1_STRING_length(priv_key
387 EC_PRIVATEKEY *priv_key = NULL; local
[all...]
H A Dinternal.h330 BIGNUM *priv_key; member in struct:ec_key_st
/external/boringssl/include/openssl/
H A Decdh.h82 /* ECDH_compute_key calculates the shared key between |pub_key| and |priv_key|.
89 const EC_POINT *pub_key, EC_KEY *priv_key,
H A Ddh.h239 BIGNUM *priv_key; /* x */ member in struct:dh_st
H A Ddsa.h348 BIGNUM *priv_key; /* x private key */ member in struct:dsa_st
/external/boringssl/src/include/openssl/
H A Decdh.h82 /* ECDH_compute_key calculates the shared key between |pub_key| and |priv_key|.
89 const EC_POINT *pub_key, EC_KEY *priv_key,
H A Ddh.h239 BIGNUM *priv_key; /* x */ member in struct:dh_st
H A Ddsa.h348 BIGNUM *priv_key; /* x private key */ member in struct:dsa_st
/external/boringssl/src/crypto/ecdh/
H A Decdh.c78 EC_KEY *priv_key, void *(*KDF)(const void *in, size_t inlen,
96 priv = EC_KEY_get0_private_key(priv_key);
102 group = EC_KEY_get0_group(priv_key);
77 ECDH_compute_key(void *out, size_t outlen, const EC_POINT *pub_key, EC_KEY *priv_key, void *(*KDF)(const void *in, size_t inlen, void *out, size_t *outlen)) argument
/external/boringssl/src/crypto/dsa/
H A Ddsa_impl.c114 ok = BN_generate_dsa_nonce(&k, dsa->q, dsa->priv_key, digest, digest_len,
239 if (!BN_mod_mul(&xr, dsa->priv_key, r, dsa->q, ctx)) {
397 BIGNUM *pub_key = NULL, *priv_key = NULL; local
405 priv_key = dsa->priv_key;
406 if (priv_key == NULL) {
407 priv_key = BN_new();
408 if (priv_key == NULL) {
414 if (!BN_rand_range(priv_key, dsa->q)) {
417 } while (BN_is_zero(priv_key));
[all...]
H A Ddsa.c141 BN_clear_free(dsa->priv_key);
339 (r->priv_key != NULL && (ret->priv_key = BN_dup(r->priv_key)) == NULL)) {
H A Ddsa_asn1.c118 ASN1_SIMPLE(DSA, priv_key, BIGNUM)} ASN1_SEQUENCE_END_cb(DSA,
H A Ddsa_test.c177 dsa->priv_key = BN_bin2bn(fips_x, sizeof(fips_x), NULL);
179 dsa->pub_key == NULL || dsa->priv_key == NULL) {
/external/boringssl/src/crypto/evp/
H A Dp_ec_asn1.c241 const BIGNUM *priv_key; local
257 priv_key = EC_KEY_get0_private_key(eckey);
258 if (!EC_POINT_mul(group, pub_key, priv_key, NULL, NULL, NULL)) {
393 const BIGNUM *priv_key; local
434 priv_key = EC_KEY_get0_private_key(x);
435 if (priv_key && (i = (size_t)BN_num_bytes(priv_key)) > buf_len) {
439 priv_key = NULL;
466 if ((priv_key != NULL) &&
467 !ASN1_bn_print(bp, "priv:", priv_key, buffe
[all...]
H A Dp_dsa_asn1.c191 * SEQUENCE {parameters, priv_key}
192 * SEQUENCE {pub_key, priv_key}. */
237 dsa->priv_key = ASN1_INTEGER_to_BN(privkey, NULL);
238 if (dsa->priv_key == NULL) {
254 if (!BN_mod_exp(dsa->pub_key, dsa->g, dsa->priv_key, dsa->p, ctx)) {
283 if (!pkey->pkey.dsa || !pkey->pkey.dsa->priv_key) {
302 prkey = BN_to_ASN1_INTEGER(pkey->pkey.dsa->priv_key, NULL);
397 const BIGNUM *priv_key, *pub_key; local
399 priv_key = NULL;
401 priv_key
[all...]
/external/bouncycastle/bcprov/src/main/java/org/bouncycastle/jce/netscape/
H A DNetscapeCertRequest.java216 public void sign(PrivateKey priv_key) throws NoSuchAlgorithmException, argument
220 sign(priv_key, null);
223 public void sign(PrivateKey priv_key, SecureRandom rand) argument
233 sig.initSign(priv_key, rand);
237 sig.initSign(priv_key);
/external/boringssl/src/crypto/ecdsa/
H A Decdsa.c365 const BIGNUM *priv_key; local
373 priv_key = EC_KEY_get0_private_key(eckey);
375 if (group == NULL || priv_key == NULL) {
415 if (!BN_mod_mul(tmp, priv_key, ret->r, order, ctx)) {
/external/openssh/
H A Ddh.c274 BN_clear_free(dh->priv_key);
/external/wpa_supplicant_8/hostapd/src/crypto/
H A Dcrypto_openssl.c558 privlen = BN_num_bytes(dh->priv_key);
564 BN_bn2bin(dh->priv_key, wpabuf_put(privkey, privlen));
594 dh->priv_key = BN_bin2bn(wpabuf_head(priv), wpabuf_len(priv), NULL);
595 if (dh->priv_key == NULL)
/external/wpa_supplicant_8/src/crypto/
H A Dcrypto_openssl.c558 privlen = BN_num_bytes(dh->priv_key);
564 BN_bn2bin(dh->priv_key, wpabuf_put(privkey, privlen));
594 dh->priv_key = BN_bin2bn(wpabuf_head(priv), wpabuf_len(priv), NULL);
595 if (dh->priv_key == NULL)
/external/wpa_supplicant_8/wpa_supplicant/src/crypto/
H A Dcrypto_openssl.c558 privlen = BN_num_bytes(dh->priv_key);
564 BN_bn2bin(dh->priv_key, wpabuf_put(privkey, privlen));
594 dh->priv_key = BN_bin2bn(wpabuf_head(priv), wpabuf_len(priv), NULL);
595 if (dh->priv_key == NULL)

Completed in 307 milliseconds

12