Lines Matching defs:mod
123 BIGNUM *mod; /* just a reference */
137 BN_BLINDING *BN_BLINDING_new(const BIGNUM *A, const BIGNUM *Ai, BIGNUM *mod)
141 bn_check_top(mod);
158 /* save a copy of mod in the BN_BLINDING structure */
159 if ((ret->mod = BN_dup(mod)) == NULL) goto err;
160 if (BN_get_flags(mod, BN_FLG_CONSTTIME) != 0)
161 BN_set_flags(ret->mod, BN_FLG_CONSTTIME);
182 if (r->mod != NULL) BN_free(r->mod);
208 if (!BN_mod_mul(b->A,b->A,b->A,b->mod,ctx)) goto err;
209 if (!BN_mod_mul(b->Ai,b->Ai,b->Ai,b->mod,ctx)) goto err;
247 if (!BN_mod_mul(n,n,b->A,b->mod,ctx)) ret=0;
264 ret = BN_mod_mul(n, n, r, b->mod, ctx);
272 ret = BN_mod_mul(n, n, b->Ai, b->mod, ctx);
343 if (!BN_rand_range(ret->A, ret->mod)) goto err;
344 if (BN_mod_inverse(ret->Ai, ret->A, ret->mod, ctx) == NULL)
367 if (!ret->bn_mod_exp(ret->A, ret->A, ret->e, ret->mod, ctx, ret->m_ctx))
372 if (!BN_mod_exp(ret->A, ret->A, ret->e, ret->mod, ctx))