Home
last modified time | relevance | path

Searched refs:BIGNUM (Results 1 – 25 of 282) sorted by relevance

12345678910>>...12

/netbsd/src/crypto/external/bsd/netpgp/dist/src/libbn/
Dbn.h59 #define BIGNUM mp_int macro
66 BIGNUM **v;
88 BIGNUM *BN_new(void);
89 BIGNUM *BN_dup(const BIGNUM */*a*/);
90 int BN_copy(BIGNUM */*b*/, const BIGNUM */*a*/);
92 void BN_init(BIGNUM */*a*/);
93 void BN_free(BIGNUM */*a*/);
94 void BN_clear(BIGNUM */*a*/);
95 void BN_clear_free(BIGNUM */*a*/);
97 int BN_cmp(BIGNUM */*a*/, BIGNUM */*b*/);
[all …]
/netbsd/src/crypto/external/bsd/openssl/dist/crypto/ec/
Dec_local.h57 int (*group_set_curve) (EC_GROUP *, const BIGNUM *p, const BIGNUM *a,
58 const BIGNUM *b, BN_CTX *);
59 int (*group_get_curve) (const EC_GROUP *, BIGNUM *p, BIGNUM *a, BIGNUM *b,
84 const BIGNUM *x, const BIGNUM *y,
87 BIGNUM *x, BIGNUM *y, BN_CTX *);
89 const BIGNUM *x, int y_bit,
135 int (*mul) (const EC_GROUP *group, EC_POINT *r, const BIGNUM *scalar,
136 size_t num, const EC_POINT *points[], const BIGNUM *scalars[],
147 int (*field_mul) (const EC_GROUP *, BIGNUM *r, const BIGNUM *a,
148 const BIGNUM *b, BN_CTX *);
[all …]
/netbsd/src/crypto/external/bsd/openssl/dist/crypto/rsa/
Drsa_local.h19 BIGNUM *r;
20 BIGNUM *d;
21 BIGNUM *t;
23 BIGNUM *pp;
33 BIGNUM *Xp1;
34 BIGNUM *Xp2;
35 BIGNUM *Xq1;
36 BIGNUM *Xq2;
37 BIGNUM *Xp;
38 BIGNUM *Xq;
[all …]
/netbsd/src/crypto/external/bsd/openssl/dist/crypto/srp/
Dsrp_lib.c26 static BIGNUM *srp_Calc_xy(const BIGNUM *x, const BIGNUM *y, const BIGNUM *N, in srp_Calc_xy()
32 BIGNUM *res = NULL; in srp_Calc_xy()
55 static BIGNUM *srp_Calc_k(const BIGNUM *N, const BIGNUM *g, in srp_Calc_k()
63 BIGNUM *SRP_Calc_u_ex(const BIGNUM *A, const BIGNUM *B, const BIGNUM *N, in SRP_Calc_u_ex()
70 BIGNUM *SRP_Calc_u(const BIGNUM *A, const BIGNUM *B, const BIGNUM *N) in SRP_Calc_u()
76 BIGNUM *SRP_Calc_server_key(const BIGNUM *A, const BIGNUM *v, const BIGNUM *u, in SRP_Calc_server_key()
77 const BIGNUM *b, const BIGNUM *N) in SRP_Calc_server_key()
79 BIGNUM *tmp = NULL, *S = NULL; in SRP_Calc_server_key()
106 BIGNUM *SRP_Calc_B_ex(const BIGNUM *b, const BIGNUM *N, const BIGNUM *g, in SRP_Calc_B_ex()
107 const BIGNUM *v, OSSL_LIB_CTX *libctx, const char *propq) in SRP_Calc_B_ex()
[all …]
/netbsd/src/crypto/external/bsd/heimdal/dist/lib/hcrypto/
Dbn.h73 #define BIGNUM hc_BIGNUM macro
84 typedef struct BIGNUM BIGNUM; typedef
102 BIGNUM *BN_new(void);
103 void BN_free(BIGNUM *);
104 void BN_clear_free(BIGNUM *);
105 void BN_clear(BIGNUM *);
106 BIGNUM *BN_dup(const BIGNUM *);
108 int BN_num_bits(const BIGNUM *);
109 int BN_num_bytes(const BIGNUM *);
111 int BN_cmp(const BIGNUM *, const BIGNUM *);
[all …]
Ddsa.h71 BIGNUM *r;
72 BIGNUM *s;
78 int (*dsa_sign_setup)(DSA *, BN_CTX *, BIGNUM **, BIGNUM **);
80 int (*dsa_mod_exp)(DSA *, BIGNUM *, BIGNUM *, BIGNUM *,
81 BIGNUM *, BIGNUM *, BIGNUM *, BN_CTX *,
83 int (*bn_mod_exp)(DSA *, BIGNUM *, BIGNUM *, const BIGNUM *,
84 const BIGNUM *, BN_CTX *,
96 BIGNUM *p;
97 BIGNUM *q;
98 BIGNUM *g;
[all …]
Dbn.c47 BIGNUM *
52 return (BIGNUM *)hi; in BN_new()
56 BN_free(BIGNUM *bn) in BN_free()
63 BN_clear(BIGNUM *bn) in BN_clear()
74 BN_clear_free(BIGNUM *bn) in BN_clear_free()
79 BIGNUM *
80 BN_dup(const BIGNUM *bn) in BN_dup()
82 BIGNUM *b = BN_new(); in BN_dup()
96 BN_num_bits(const BIGNUM *bn) in BN_num_bits()
115 BN_num_bytes(const BIGNUM *bn) in BN_num_bytes()
[all …]
Ddh.h79 int (*compute_key)(unsigned char *,const BIGNUM *,DH *);
80 int (*bn_mod_exp)(const DH *, BIGNUM *, const BIGNUM *,
81 const BIGNUM *, const BIGNUM *, BN_CTX *,
93 BIGNUM *p;
94 BIGNUM *g;
96 BIGNUM *pub_key;
97 BIGNUM *priv_key;
100 BIGNUM *q;
101 BIGNUM *j;
104 BIGNUM *counter;
[all …]
/netbsd/src/external/bsd/ntp/dist/include/
Dlibssl_compat.h61 extern void sslshim_RSA_get0_key(const RSA *prsa, const BIGNUM **pn,
62 const BIGNUM **pe, const BIGNUM **pd);
63 extern int sslshim_RSA_set0_key(RSA *prsa, BIGNUM *n,
64 BIGNUM *e, BIGNUM *d);
65 extern void sslshim_RSA_get0_factors(const RSA *prsa, const BIGNUM **pp,
66 const BIGNUM **pq);
67 extern int sslshim_RSA_set0_factors(RSA *prsar, BIGNUM *p, BIGNUM *q);
68 extern int sslshim_RSA_set0_crt_params(RSA *prsa, BIGNUM *dmp1,
69 BIGNUM *dmq1, BIGNUM *iqmp);
71 extern void sslshim_DSA_SIG_get0(const DSA_SIG *psig, const BIGNUM **pr,
[all …]
/netbsd/src/crypto/external/bsd/openssl/dist/crypto/bn/
Dbn_mod.c13 int BN_nnmod(BIGNUM *r, const BIGNUM *m, const BIGNUM *d, BN_CTX *ctx) in BN_nnmod()
33 int BN_mod_add(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, const BIGNUM *m, in BN_mod_add()
53 int bn_mod_add_fixed_top(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, in bn_mod_add_fixed_top()
54 const BIGNUM *m) in bn_mod_add_fixed_top()
104 int BN_mod_add_quick(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, in BN_mod_add_quick()
105 const BIGNUM *m) in BN_mod_add_quick()
115 int BN_mod_sub(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, const BIGNUM *m, in BN_mod_sub()
137 int bn_mod_sub_fixed_top(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, in bn_mod_sub_fixed_top()
138 const BIGNUM *m) in bn_mod_sub_fixed_top()
191 int BN_mod_sub_quick(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, in BN_mod_sub_quick()
[all …]
Dbn_const.c25 BIGNUM *BN_get_rfc2409_prime_768(BIGNUM *bn) in BN_get_rfc2409_prime_768()
53 BIGNUM *BN_get_rfc2409_prime_1024(BIGNUM *bn) in BN_get_rfc2409_prime_1024()
85 BIGNUM *BN_get_rfc3526_prime_1536(BIGNUM *bn) in BN_get_rfc3526_prime_1536()
98 BIGNUM *BN_get_rfc3526_prime_2048(BIGNUM *bn) in BN_get_rfc3526_prime_2048()
111 BIGNUM *BN_get_rfc3526_prime_3072(BIGNUM *bn) in BN_get_rfc3526_prime_3072()
124 BIGNUM *BN_get_rfc3526_prime_4096(BIGNUM *bn) in BN_get_rfc3526_prime_4096()
137 BIGNUM *BN_get_rfc3526_prime_6144(BIGNUM *bn) in BN_get_rfc3526_prime_6144()
150 BIGNUM *BN_get_rfc3526_prime_8192(BIGNUM *bn) in BN_get_rfc3526_prime_8192()
Dbn_lib.c82 const BIGNUM *BN_value_one(void) in BN_value_one()
85 static const BIGNUM const_one = in BN_value_one()
153 int bn_num_bits_consttime(const BIGNUM *a) in bn_num_bits_consttime()
178 int BN_num_bits(const BIGNUM *a) in BN_num_bits()
202 static void bn_free_d(BIGNUM *a, int clear) in bn_free_d()
213 void BN_clear_free(BIGNUM *a) in BN_clear_free()
225 void BN_free(BIGNUM *a) in BN_free()
235 void bn_init(BIGNUM *a) in bn_init()
237 static BIGNUM nilbn; in bn_init()
243 BIGNUM *BN_new(void) in BN_new()
[all …]
Dbn_x931p.c23 static int bn_x931_derive_pi(BIGNUM *pi, const BIGNUM *Xpi, BN_CTX *ctx, in bn_x931_derive_pi()
53 int BN_X931_derive_prime_ex(BIGNUM *p, BIGNUM *p1, BIGNUM *p2, in BN_X931_derive_prime_ex()
54 const BIGNUM *Xp, const BIGNUM *Xp1, in BN_X931_derive_prime_ex()
55 const BIGNUM *Xp2, const BIGNUM *e, BN_CTX *ctx, in BN_X931_derive_prime_ex()
60 BIGNUM *t, *p1p2, *pm1; in BN_X931_derive_prime_ex()
162 int BN_X931_generate_Xpq(BIGNUM *Xp, BIGNUM *Xq, int nbits, BN_CTX *ctx) in BN_X931_generate_Xpq()
164 BIGNUM *t; in BN_X931_generate_Xpq()
219 int BN_X931_generate_prime_ex(BIGNUM *p, BIGNUM *p1, BIGNUM *p2, in BN_X931_generate_prime_ex()
220 BIGNUM *Xp1, BIGNUM *Xp2, in BN_X931_generate_prime_ex()
221 const BIGNUM *Xp, in BN_X931_generate_prime_ex()
[all …]
Dbn_rand.c23 static int bnrand(BNRAND_FLAG flag, BIGNUM *rnd, int bits, int top, int bottom, in bnrand()
102 int BN_rand_ex(BIGNUM *rnd, int bits, int top, int bottom, in BN_rand_ex()
108 int BN_rand(BIGNUM *rnd, int bits, int top, int bottom) in BN_rand()
113 int BN_bntest_rand(BIGNUM *rnd, int bits, int top, int bottom) in BN_bntest_rand()
119 int BN_priv_rand_ex(BIGNUM *rnd, int bits, int top, int bottom, in BN_priv_rand_ex()
126 int BN_priv_rand(BIGNUM *rnd, int bits, int top, int bottom) in BN_priv_rand()
133 static int bnrand_range(BNRAND_FLAG flag, BIGNUM *r, const BIGNUM *range, in bnrand_range()
205 int BN_rand_range_ex(BIGNUM *r, const BIGNUM *range, unsigned int strength, in BN_rand_range_ex()
212 int BN_rand_range(BIGNUM *r, const BIGNUM *range) in BN_rand_range()
218 int BN_priv_rand_range_ex(BIGNUM *r, const BIGNUM *range, unsigned int strength, in BN_priv_rand_range_ex()
[all …]
Dbn_rsa_fips186_4.c43 const BIGNUM ossl_bn_inv_sqrt_2 = {
103 static int bn_rsa_fips186_4_find_aux_prob_prime(const BIGNUM *Xp1, in bn_rsa_fips186_4_find_aux_prob_prime()
104 BIGNUM *p1, BN_CTX *ctx, in bn_rsa_fips186_4_find_aux_prob_prime()
154 int ossl_bn_rsa_fips186_4_gen_prob_primes(BIGNUM *p, BIGNUM *Xpout, in ossl_bn_rsa_fips186_4_gen_prob_primes()
155 BIGNUM *p1, BIGNUM *p2, in ossl_bn_rsa_fips186_4_gen_prob_primes()
156 const BIGNUM *Xp, const BIGNUM *Xp1, in ossl_bn_rsa_fips186_4_gen_prob_primes()
157 const BIGNUM *Xp2, int nlen, in ossl_bn_rsa_fips186_4_gen_prob_primes()
158 const BIGNUM *e, BN_CTX *ctx, in ossl_bn_rsa_fips186_4_gen_prob_primes()
162 BIGNUM *p1i = NULL, *p2i = NULL, *Xp1i = NULL, *Xp2i = NULL; in ossl_bn_rsa_fips186_4_gen_prob_primes()
172 Xp1i = (Xp1 != NULL) ? (BIGNUM *)Xp1 : BN_CTX_get(ctx); in ossl_bn_rsa_fips186_4_gen_prob_primes()
[all …]
Dbn_gf2m.c253 int BN_GF2m_add(BIGNUM *r, const BIGNUM *a, const BIGNUM *b) in BN_GF2m_add()
256 const BIGNUM *at, *bt; in BN_GF2m_add()
293 int BN_GF2m_mod_arr(BIGNUM *r, const BIGNUM *a, const int p[]) in BN_GF2m_mod_arr()
391 int BN_GF2m_mod(BIGNUM *r, const BIGNUM *a, const BIGNUM *p) in BN_GF2m_mod()
411 int BN_GF2m_mod_mul_arr(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, in BN_GF2m_mod_mul_arr()
415 BIGNUM *s; in BN_GF2m_mod_mul_arr()
466 int BN_GF2m_mod_mul(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, in BN_GF2m_mod_mul()
467 const BIGNUM *p, BN_CTX *ctx) in BN_GF2m_mod_mul()
495 int BN_GF2m_mod_sqr_arr(BIGNUM *r, const BIGNUM *a, const int p[], in BN_GF2m_mod_sqr_arr()
499 BIGNUM *s; in BN_GF2m_mod_sqr_arr()
[all …]
Dbn_blind.c17 BIGNUM *A;
18 BIGNUM *Ai;
19 BIGNUM *e;
20 BIGNUM *mod; /* just a reference */
25 int (*bn_mod_exp) (BIGNUM *r, const BIGNUM *a, const BIGNUM *p,
26 const BIGNUM *m, BN_CTX *ctx, BN_MONT_CTX *m_ctx);
30 BN_BLINDING *BN_BLINDING_new(const BIGNUM *A, const BIGNUM *Ai, BIGNUM *mod) in BN_BLINDING_new()
129 int BN_BLINDING_convert(BIGNUM *n, BN_BLINDING *b, BN_CTX *ctx) in BN_BLINDING_convert()
134 int BN_BLINDING_convert_ex(BIGNUM *n, BIGNUM *r, BN_BLINDING *b, BN_CTX *ctx) in BN_BLINDING_convert_ex()
162 int BN_BLINDING_invert(BIGNUM *n, BN_BLINDING *b, BN_CTX *ctx) in BN_BLINDING_invert()
[all …]
/netbsd/src/crypto/external/bsd/netpgp/dist/src/librsa/
Drsa.h43 BIGNUM *n; /* RSA public modulus n */
44 BIGNUM *e; /* RSA public encryption exponent e */
52 BIGNUM *n;
53 BIGNUM *e;
54 BIGNUM *d;
55 BIGNUM *p;
56 BIGNUM *q;
57 BIGNUM *dmp1;
58 BIGNUM *dmq1;
59 BIGNUM *iqmp;
[all …]
/netbsd/src/external/bsd/ntp/dist/libntp/
Dlibssl_compat.c45 BIGNUM ** ps, in replace_bn_nn()
46 BIGNUM * n in replace_bn_nn()
134 const BIGNUM ** pn, in sslshim_RSA_get0_key()
135 const BIGNUM ** pe, in sslshim_RSA_get0_key()
136 const BIGNUM ** pd in sslshim_RSA_get0_key()
152 BIGNUM * n, in sslshim_RSA_set0_key()
153 BIGNUM * e, in sslshim_RSA_set0_key()
154 BIGNUM * d in sslshim_RSA_set0_key()
171 const BIGNUM ** pp, in sslshim_RSA_get0_factors()
172 const BIGNUM ** pq in sslshim_RSA_get0_factors()
[all …]
/netbsd/src/crypto/external/bsd/openssl/dist/crypto/dsa/
Ddsa_meth.c121 (DSA *, BN_CTX *, BIGNUM **, BIGNUM **) in DSA_meth_get_sign_setup()
127 int (*sign_setup) (DSA *, BN_CTX *, BIGNUM **, BIGNUM **)) in DSA_meth_set_sign_setup() argument
147 (DSA *, BIGNUM *, const BIGNUM *, const BIGNUM *, const BIGNUM *, in DSA_meth_get_mod_exp()
148 const BIGNUM *, const BIGNUM *, BN_CTX *, BN_MONT_CTX *) in DSA_meth_get_mod_exp()
154 int (*mod_exp) (DSA *, BIGNUM *, const BIGNUM *, const BIGNUM *, in DSA_meth_set_mod_exp() argument
155 const BIGNUM *, const BIGNUM *, const BIGNUM *, BN_CTX *, in DSA_meth_set_mod_exp()
163 (DSA *, BIGNUM *, const BIGNUM *, const BIGNUM *, const BIGNUM *, BN_CTX *, in DSA_meth_get_bn_mod_exp()
170 int (*bn_mod_exp) (DSA *, BIGNUM *, const BIGNUM *, const BIGNUM *, in DSA_meth_set_bn_mod_exp() argument
171 const BIGNUM *, BN_CTX *, BN_MONT_CTX *)) in DSA_meth_set_bn_mod_exp()
Ddsa_local.h22 BIGNUM *pub_key; /* y public key */
23 BIGNUM *priv_key; /* x private key */
42 BIGNUM *r;
43 BIGNUM *s;
49 int (*dsa_sign_setup) (DSA *dsa, BN_CTX *ctx_in, BIGNUM **kinvp,
50 BIGNUM **rp);
53 int (*dsa_mod_exp) (DSA *dsa, BIGNUM *rr, const BIGNUM *a1,
54 const BIGNUM *p1, const BIGNUM *a2, const BIGNUM *p2,
55 const BIGNUM *m, BN_CTX *ctx, BN_MONT_CTX *in_mont);
57 int (*bn_mod_exp) (DSA *dsa, BIGNUM *r, const BIGNUM *a, const BIGNUM *p,
[all …]
Ddsa_asn1.c43 ASN1_SIMPLE(DSA, params.p, BIGNUM),
44 ASN1_SIMPLE(DSA, params.q, BIGNUM),
45 ASN1_SIMPLE(DSA, params.g, BIGNUM),
46 ASN1_SIMPLE(DSA, pub_key, BIGNUM),
53 ASN1_SIMPLE(DSA, params.p, BIGNUM),
54 ASN1_SIMPLE(DSA, params.q, BIGNUM),
55 ASN1_SIMPLE(DSA, params.g, BIGNUM),
61 ASN1_SIMPLE(DSA, pub_key, BIGNUM),
62 ASN1_SIMPLE(DSA, params.p, BIGNUM),
63 ASN1_SIMPLE(DSA, params.q, BIGNUM),
[all …]
/netbsd/src/games/factor/
Dfactor.c94 static void pollard_pminus1(BIGNUM *, int, int);
98 typedef long BIGNUM; typedef
103 #define BN_new() calloc(sizeof(BIGNUM), 1)
112 static BIGNUM *BN_dup(const BIGNUM *);
113 static int BN_dec2bn(BIGNUM **, const char *);
114 static int BN_hex2bn(BIGNUM **, const char *);
115 static BN_ULONG BN_div_word(BIGNUM *, BN_ULONG);
116 static void BN_print_fp(FILE *, const BIGNUM *);
120 static void BN_print_dec_fp(FILE *, const BIGNUM *);
121 static void convert_str2bn(BIGNUM **, char *);
[all …]
/netbsd/src/crypto/external/bsd/openssl/dist/test/
Dsrptest.c33 BIGNUM *s = NULL; in run_srp()
34 BIGNUM *v = NULL; in run_srp()
35 BIGNUM *a = NULL; in run_srp()
36 BIGNUM *b = NULL; in run_srp()
37 BIGNUM *u = NULL; in run_srp()
38 BIGNUM *x = NULL; in run_srp()
39 BIGNUM *Apub = NULL; in run_srp()
40 BIGNUM *Bpub = NULL; in run_srp()
41 BIGNUM *Kclient = NULL; in run_srp()
42 BIGNUM *Kserver = NULL; in run_srp()
[all …]
/netbsd/src/crypto/external/bsd/netpgp/dist/src/lib/
Dpacket.h374 BIGNUM *p; /* DSA prime p */
375 BIGNUM *q; /* DSA group order q */
376 BIGNUM *g; /* DSA group generator g */
377 BIGNUM *y; /* DSA public key value y (= g^x mod p
388 BIGNUM *p;
396 BIGNUM *n; /* RSA public modulus n */
397 BIGNUM *e; /* RSA public encryption exponent e */
405 BIGNUM *p; /* ElGamal prime p */
406 BIGNUM *g; /* ElGamal group generator g */
407 BIGNUM *y; /* ElGamal public key value y (= g^x mod p
[all …]

12345678910>>...12