/third_party/node/deps/openssl/openssl/crypto/rsa/ |
H A D | rsa_lib.c | 165 BN_clear_free(r->iqmp); in RSA_free() 444 int RSA_set0_crt_params(RSA *r, BIGNUM *dmp1, BIGNUM *dmq1, BIGNUM *iqmp) in RSA_set0_crt_params() argument 446 /* If the fields dmp1, dmq1 and iqmp in r are NULL, the corresponding input in RSA_set0_crt_params() 451 || (r->iqmp == NULL && iqmp == NULL)) in RSA_set0_crt_params() 464 if (iqmp != NULL) { in RSA_set0_crt_params() 465 BN_clear_free(r->iqmp); in RSA_set0_crt_params() 466 r->iqmp = iqmp; in RSA_set0_crt_params() 467 BN_set_flags(r->iqmp, BN_FLG_CONSTTIM in RSA_set0_crt_params() 596 RSA_get0_crt_params(const RSA *r, const BIGNUM **dmp1, const BIGNUM **dmq1, const BIGNUM **iqmp) RSA_get0_crt_params() argument [all...] |
H A D | rsa_sp800_56b_gen.c | 303 BN_free(rsa->iqmp); in ossl_rsa_sp800_56b_derive_params_from_pq() 304 rsa->iqmp = BN_secure_new(); in ossl_rsa_sp800_56b_derive_params_from_pq() 305 if (rsa->iqmp == NULL) in ossl_rsa_sp800_56b_derive_params_from_pq() 307 BN_set_flags(rsa->iqmp, BN_FLG_CONSTTIME); in ossl_rsa_sp800_56b_derive_params_from_pq() 308 if (BN_mod_inverse(rsa->iqmp, rsa->q, rsa->p, ctx) == NULL) in ossl_rsa_sp800_56b_derive_params_from_pq() 321 BN_free(rsa->iqmp); in ossl_rsa_sp800_56b_derive_params_from_pq() 322 rsa->iqmp = NULL; in ossl_rsa_sp800_56b_derive_params_from_pq()
|
H A D | rsa_gen.c | 145 if (!rsa->iqmp && ((rsa->iqmp = BN_secure_new()) == NULL)) in rsa_multiprime_keygen() 147 BN_set_flags(rsa->iqmp, BN_FLG_CONSTTIME); in rsa_multiprime_keygen() 393 if (!BN_mod_inverse(rsa->iqmp, rsa->q, p, ctx)) { in rsa_multiprime_keygen() 459 BN_clear_free(rsa->iqmp); in rsa_keygen() 465 rsa->iqmp = NULL; in rsa_keygen()
|
H A D | rsa_sp800_56b_check.c | 30 if (rsa->dmp1 == NULL || rsa->dmq1 == NULL || rsa->iqmp == NULL) { in ossl_rsa_check_crt_components() 31 if (rsa->dmp1 != NULL || rsa->dmq1 != NULL || rsa->iqmp != NULL) in ossl_rsa_check_crt_components() 62 && (BN_cmp(rsa->iqmp, BN_value_one()) > 0) in ossl_rsa_check_crt_components() 63 && (BN_cmp(rsa->iqmp, rsa->p) < 0) in ossl_rsa_check_crt_components() 71 && BN_mod_mul(r, rsa->iqmp, rsa->q, rsa->p, ctx) in ossl_rsa_check_crt_components()
|
H A D | rsa_chk.c | 160 if (key->dmp1 != NULL && key->dmq1 != NULL && key->iqmp != NULL) { in rsa_validate_keypair_multiprime() 189 /* iqmp = q^-1 mod p? */ in rsa_validate_keypair_multiprime() 194 if (BN_cmp(i, key->iqmp) != 0) { in rsa_validate_keypair_multiprime()
|
H A D | rsa_x931g.c | 136 rsa->iqmp = BN_mod_inverse(NULL, rsa->q, rsa->p, ctx2); in RSA_X931_derive_ex() 137 if (rsa->iqmp == NULL) in RSA_X931_derive_ex()
|
H A D | rsa_ossl.c | 322 (rsa->dmp1 != NULL) && (rsa->dmq1 != NULL) && (rsa->iqmp != NULL))) { in rsa_ossl_private_encrypt() 447 (rsa->dmp1 != NULL) && (rsa->dmq1 != NULL) && (rsa->iqmp != NULL))) { in rsa_ossl_private_decrypt() 715 /* r1 = r1 * iqmp mod p */ in rsa_ossl_mod_exp() 717 || !bn_mul_mont_fixed_top(r1, r1, rsa->iqmp, rsa->_method_mod_p, in rsa_ossl_mod_exp() 835 if (!BN_mul(r1, r0, rsa->iqmp, ctx)) in rsa_ossl_mod_exp()
|
H A D | rsa_asn1.c | 66 ASN1_SIMPLE(RSA, iqmp, CBIGNUM),
|
/third_party/openssl/crypto/rsa/ |
H A D | rsa_lib.c | 165 BN_clear_free(r->iqmp); in RSA_free() 444 int RSA_set0_crt_params(RSA *r, BIGNUM *dmp1, BIGNUM *dmq1, BIGNUM *iqmp) in RSA_set0_crt_params() argument 446 /* If the fields dmp1, dmq1 and iqmp in r are NULL, the corresponding input in RSA_set0_crt_params() 451 || (r->iqmp == NULL && iqmp == NULL)) in RSA_set0_crt_params() 464 if (iqmp != NULL) { in RSA_set0_crt_params() 465 BN_clear_free(r->iqmp); in RSA_set0_crt_params() 466 r->iqmp = iqmp; in RSA_set0_crt_params() 467 BN_set_flags(r->iqmp, BN_FLG_CONSTTIM in RSA_set0_crt_params() 596 RSA_get0_crt_params(const RSA *r, const BIGNUM **dmp1, const BIGNUM **dmq1, const BIGNUM **iqmp) RSA_get0_crt_params() argument [all...] |
H A D | rsa_sp800_56b_gen.c | 303 BN_free(rsa->iqmp); in ossl_rsa_sp800_56b_derive_params_from_pq() 304 rsa->iqmp = BN_secure_new(); in ossl_rsa_sp800_56b_derive_params_from_pq() 305 if (rsa->iqmp == NULL) in ossl_rsa_sp800_56b_derive_params_from_pq() 307 BN_set_flags(rsa->iqmp, BN_FLG_CONSTTIME); in ossl_rsa_sp800_56b_derive_params_from_pq() 308 if (BN_mod_inverse(rsa->iqmp, rsa->q, rsa->p, ctx) == NULL) in ossl_rsa_sp800_56b_derive_params_from_pq() 321 BN_free(rsa->iqmp); in ossl_rsa_sp800_56b_derive_params_from_pq() 322 rsa->iqmp = NULL; in ossl_rsa_sp800_56b_derive_params_from_pq()
|
H A D | rsa_gen.c | 145 if (!rsa->iqmp && ((rsa->iqmp = BN_secure_new()) == NULL)) in rsa_multiprime_keygen() 147 BN_set_flags(rsa->iqmp, BN_FLG_CONSTTIME); in rsa_multiprime_keygen() 393 if (!BN_mod_inverse(rsa->iqmp, rsa->q, p, ctx)) { in rsa_multiprime_keygen() 459 BN_clear_free(rsa->iqmp); in rsa_keygen() 465 rsa->iqmp = NULL; in rsa_keygen()
|
H A D | rsa_sp800_56b_check.c | 30 if (rsa->dmp1 == NULL || rsa->dmq1 == NULL || rsa->iqmp == NULL) { in ossl_rsa_check_crt_components() 31 if (rsa->dmp1 != NULL || rsa->dmq1 != NULL || rsa->iqmp != NULL) in ossl_rsa_check_crt_components() 62 && (BN_cmp(rsa->iqmp, BN_value_one()) > 0) in ossl_rsa_check_crt_components() 63 && (BN_cmp(rsa->iqmp, rsa->p) < 0) in ossl_rsa_check_crt_components() 71 && BN_mod_mul(r, rsa->iqmp, rsa->q, rsa->p, ctx) in ossl_rsa_check_crt_components()
|
H A D | rsa_chk.c | 160 if (key->dmp1 != NULL && key->dmq1 != NULL && key->iqmp != NULL) { in rsa_validate_keypair_multiprime() 189 /* iqmp = q^-1 mod p? */ in rsa_validate_keypair_multiprime() 194 if (BN_cmp(i, key->iqmp) != 0) { in rsa_validate_keypair_multiprime()
|
H A D | rsa_x931g.c | 136 rsa->iqmp = BN_mod_inverse(NULL, rsa->q, rsa->p, ctx2); in RSA_X931_derive_ex() 137 if (rsa->iqmp == NULL) in RSA_X931_derive_ex()
|
H A D | rsa_ossl.c | 322 (rsa->dmp1 != NULL) && (rsa->dmq1 != NULL) && (rsa->iqmp != NULL))) { in rsa_ossl_private_encrypt() 447 (rsa->dmp1 != NULL) && (rsa->dmq1 != NULL) && (rsa->iqmp != NULL))) { in rsa_ossl_private_decrypt() 715 /* r1 = r1 * iqmp mod p */ in rsa_ossl_mod_exp() 717 || !bn_mul_mont_fixed_top(r1, r1, rsa->iqmp, rsa->_method_mod_p, in rsa_ossl_mod_exp() 835 if (!BN_mul(r1, r0, rsa->iqmp, ctx)) in rsa_ossl_mod_exp()
|
H A D | rsa_asn1.c | 66 ASN1_SIMPLE(RSA, iqmp, CBIGNUM),
|
/third_party/openssl/test/ |
H A D | rsa_test.c | 43 BN_bin2bn(iqmp, sizeof(iqmp)-1, NULL)); \ 84 static unsigned char iqmp[] = in key1() local 129 static unsigned char iqmp[] = in key2() local 194 static unsigned char iqmp[] = in key3() local
|
H A D | rsa_mp_test.c | 107 static const unsigned char iqmp[] = variable 164 BN_bin2bn(iqmp, sizeof(iqmp) - 1, in key2048p3_v1() 227 if (!TEST_ptr(num = BN_bin2bn(iqmp, sizeof(iqmp) - 1, NULL)) in key2048p3_v2()
|
H A D | rsa_sp800_56b_test.c | 307 && TEST_BN_eq_word(key->iqmp, QINV) in test_check_crt_components() 322 && TEST_true(BN_set_word(key->iqmp, 1)) in test_check_crt_components() 324 && TEST_true(BN_set_word(key->iqmp, P)) in test_check_crt_components() 326 && TEST_true(BN_set_word(key->iqmp, QINV)) in test_check_crt_components() 336 && TEST_true(BN_set_word(key->iqmp, QINV+1)) in test_check_crt_components() 338 && TEST_true(BN_set_word(key->iqmp, QINV)) in test_check_crt_components()
|
/third_party/wpa_supplicant/wpa_supplicant-2.9/src/tls/ |
H A D | rsa.c | 27 struct bignum *iqmp; /* 1 / q mod p; CRT coefficient */ member 169 key->iqmp = bignum_init(); in crypto_rsa_import_private_key() 173 key->dmq1 == NULL || key->iqmp == NULL) { in crypto_rsa_import_private_key() 224 pos = crypto_rsa_parse_integer(pos, end, key->iqmp); in crypto_rsa_import_private_key() 294 * iqmp = (1/q) mod p, where p > q in crypto_rsa_exptmod() 315 bignum_mulmod(tmp, key->iqmp, key->p, tmp) < 0) in crypto_rsa_exptmod() 372 bignum_deinit(key->iqmp); in crypto_rsa_free()
|
/third_party/wpa_supplicant/wpa_supplicant-2.9_standard/src/tls/ |
H A D | rsa.c | 27 struct bignum *iqmp; /* 1 / q mod p; CRT coefficient */ member 164 key->iqmp = bignum_init(); in crypto_rsa_import_private_key() 168 key->dmq1 == NULL || key->iqmp == NULL) { in crypto_rsa_import_private_key() 215 pos = crypto_rsa_parse_integer(pos, end, key->iqmp); in crypto_rsa_import_private_key() 285 * iqmp = (1/q) mod p, where p > q in crypto_rsa_exptmod() 306 bignum_mulmod(tmp, key->iqmp, key->p, tmp) < 0) in crypto_rsa_exptmod() 363 bignum_deinit(key->iqmp); in crypto_rsa_free()
|
/third_party/node/deps/openssl/openssl/crypto/pem/ |
H A D | pvkfmt.c | 446 BIGNUM *p = NULL, *q = NULL, *dmp1 = NULL, *dmq1 = NULL, *iqmp = NULL; in ossl_b2i_RSA_after_header() local 470 if (!read_lebn(&pin, hnbyte, &iqmp)) in ossl_b2i_RSA_after_header() 477 if (!RSA_set0_crt_params(rsa, dmp1, dmq1, iqmp)) in ossl_b2i_RSA_after_header() 479 dmp1 = dmq1 = iqmp = NULL; in ossl_b2i_RSA_after_header() 495 BN_free(iqmp); in ossl_b2i_RSA_after_header() 639 const BIGNUM *d, *p, *q, *iqmp, *dmp1, *dmq1; in check_bitlen_rsa() local 650 RSA_get0_crt_params(rsa, &dmp1, &dmq1, &iqmp); in check_bitlen_rsa() 651 if ((BN_num_bytes(iqmp) > hnbyte) in check_bitlen_rsa() 667 const BIGNUM *n, *d, *e, *p, *q, *iqmp, *dmp1, *dmq1; in write_rsa() local 677 RSA_get0_crt_params(rsa, &dmp1, &dmq1, &iqmp); in write_rsa() [all...] |
/third_party/openssl/crypto/pem/ |
H A D | pvkfmt.c | 446 BIGNUM *p = NULL, *q = NULL, *dmp1 = NULL, *dmq1 = NULL, *iqmp = NULL; in ossl_b2i_RSA_after_header() local 470 if (!read_lebn(&pin, hnbyte, &iqmp)) in ossl_b2i_RSA_after_header() 477 if (!RSA_set0_crt_params(rsa, dmp1, dmq1, iqmp)) in ossl_b2i_RSA_after_header() 479 dmp1 = dmq1 = iqmp = NULL; in ossl_b2i_RSA_after_header() 495 BN_free(iqmp); in ossl_b2i_RSA_after_header() 639 const BIGNUM *d, *p, *q, *iqmp, *dmp1, *dmq1; in check_bitlen_rsa() local 650 RSA_get0_crt_params(rsa, &dmp1, &dmq1, &iqmp); in check_bitlen_rsa() 651 if ((BN_num_bytes(iqmp) > hnbyte) in check_bitlen_rsa() 667 const BIGNUM *n, *d, *e, *p, *q, *iqmp, *dmp1, *dmq1; in write_rsa() local 677 RSA_get0_crt_params(rsa, &dmp1, &dmq1, &iqmp); in write_rsa() [all...] |
/third_party/rust/crates/rust-openssl/openssl/src/ |
H A D | rsa.rs | 227 pub fn iqmp(&self) -> Option<&BigNumRef> { in iqmp() functions 463 /// `dmp1`, `dmq1`, and `iqmp` are the exponents and coefficient for 471 iqmp: BigNum, in set_crt_params() 478 iqmp.as_ptr(), in set_crt_params() 480 mem::forget((dmp1, dmq1, iqmp)); in set_crt_params() 499 /// # let (n, e, d, p, q, dmp1, dmq1, iqmp) = (bn(), bn(), bn(), bn(), bn(), bn(), bn(), bn()); 502 /// .set_crt_params(dmp1, dmq1, iqmp)? 515 iqmp: BigNum, in from_private_components() 519 .set_crt_params(dmp1, dmq1, iqmp)? in from_private_components() 627 iqmp in fmt() [all...] |
/third_party/rust/crates/rust-openssl/openssl-sys/src/handwritten/ |
H A D | rsa.rs | 29 iqmp: *mut BIGNUM, in RSA_set0_crt_params() 45 iqmp: *mut *const BIGNUM, in RSA_get0_crt_params()
|