Lines Matching refs:BIGNUM
195 int BN_div(BIGNUM *quotient, BIGNUM *rem, const BIGNUM *numerator, in BN_div()
196 const BIGNUM *divisor, BN_CTX *ctx) { in BN_div()
198 BIGNUM wnum; in BN_div()
223 BIGNUM *tmp = BN_CTX_get(ctx); in BN_div()
224 BIGNUM *snum = BN_CTX_get(ctx); in BN_div()
225 BIGNUM *sdiv = BN_CTX_get(ctx); in BN_div()
226 BIGNUM *res = NULL; in BN_div()
403 int BN_nnmod(BIGNUM *r, const BIGNUM *m, const BIGNUM *d, BN_CTX *ctx) { in BN_nnmod()
459 int bn_div_consttime(BIGNUM *quotient, BIGNUM *remainder, in bn_div_consttime()
460 const BIGNUM *numerator, const BIGNUM *divisor, in bn_div_consttime()
477 BIGNUM *q = quotient, *r = remainder; in bn_div_consttime()
484 BIGNUM *tmp = BN_CTX_get(ctx); in bn_div_consttime()
532 static BIGNUM *bn_scratch_space_from_ctx(size_t width, BN_CTX *ctx) { in bn_scratch_space_from_ctx()
533 BIGNUM *ret = BN_CTX_get(ctx); in bn_scratch_space_from_ctx()
548 static const BIGNUM *bn_resized_from_ctx(const BIGNUM *bn, size_t width, in bn_resized_from_ctx()
555 BIGNUM *ret = bn_scratch_space_from_ctx(width, ctx); in bn_resized_from_ctx()
564 int BN_mod_add(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, const BIGNUM *m, in BN_mod_add()
572 int BN_mod_add_quick(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, in BN_mod_add_quick()
573 const BIGNUM *m) { in BN_mod_add_quick()
581 int bn_mod_add_consttime(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, in bn_mod_add_consttime()
582 const BIGNUM *m, BN_CTX *ctx) { in bn_mod_add_consttime()
586 BIGNUM *tmp = bn_scratch_space_from_ctx(m->width, ctx); in bn_mod_add_consttime()
598 int BN_mod_sub(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, const BIGNUM *m, in BN_mod_sub()
606 int bn_mod_sub_consttime(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, in bn_mod_sub_consttime()
607 const BIGNUM *m, BN_CTX *ctx) { in bn_mod_sub_consttime()
611 BIGNUM *tmp = bn_scratch_space_from_ctx(m->width, ctx); in bn_mod_sub_consttime()
623 int BN_mod_sub_quick(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, in BN_mod_sub_quick()
624 const BIGNUM *m) { in BN_mod_sub_quick()
632 int BN_mod_mul(BIGNUM *r, const BIGNUM *a, const BIGNUM *b, const BIGNUM *m, in BN_mod_mul()
634 BIGNUM *t; in BN_mod_mul()
664 int BN_mod_sqr(BIGNUM *r, const BIGNUM *a, const BIGNUM *m, BN_CTX *ctx) { in BN_mod_sqr()
673 int BN_mod_lshift(BIGNUM *r, const BIGNUM *a, int n, const BIGNUM *m, in BN_mod_lshift()
675 BIGNUM *abs_m = NULL; in BN_mod_lshift()
696 int bn_mod_lshift_consttime(BIGNUM *r, const BIGNUM *a, int n, const BIGNUM *m, in bn_mod_lshift_consttime()
709 int BN_mod_lshift_quick(BIGNUM *r, const BIGNUM *a, int n, const BIGNUM *m) { in BN_mod_lshift_quick()
717 int BN_mod_lshift1(BIGNUM *r, const BIGNUM *a, const BIGNUM *m, BN_CTX *ctx) { in BN_mod_lshift1()
725 int bn_mod_lshift1_consttime(BIGNUM *r, const BIGNUM *a, const BIGNUM *m, in bn_mod_lshift1_consttime()
730 int BN_mod_lshift1_quick(BIGNUM *r, const BIGNUM *a, const BIGNUM *m) { in BN_mod_lshift1_quick()
738 BN_ULONG BN_div_word(BIGNUM *a, BN_ULONG w) { in BN_div_word()
772 BN_ULONG BN_mod_word(const BIGNUM *a, BN_ULONG w) { in BN_mod_word()
788 BIGNUM *tmp = BN_dup(a); in BN_mod_word()
809 int BN_mod_pow2(BIGNUM *r, const BIGNUM *a, size_t e) { in BN_mod_pow2()
844 int BN_nnmod_pow2(BIGNUM *r, const BIGNUM *a, size_t e) { in BN_nnmod_pow2()