Lines Matching refs:rsa

34                        RSA *rsa, int padding)  in RSA_public_encrypt()  argument
36 return rsa->meth->rsa_pub_enc(flen, from, to, rsa, padding); in RSA_public_encrypt()
40 unsigned char *to, RSA *rsa, int padding) in RSA_private_encrypt() argument
42 return rsa->meth->rsa_priv_enc(flen, from, to, rsa, padding); in RSA_private_encrypt()
46 unsigned char *to, RSA *rsa, int padding) in RSA_private_decrypt() argument
48 return rsa->meth->rsa_priv_dec(flen, from, to, rsa, padding); in RSA_private_decrypt()
52 RSA *rsa, int padding) in RSA_public_decrypt() argument
54 return rsa->meth->rsa_pub_dec(flen, from, to, rsa, padding); in RSA_public_decrypt()
62 void RSA_blinding_off(RSA *rsa) in RSA_blinding_off() argument
64 BN_BLINDING_free(rsa->blinding); in RSA_blinding_off()
65 rsa->blinding = NULL; in RSA_blinding_off()
66 rsa->flags &= ~RSA_FLAG_BLINDING; in RSA_blinding_off()
67 rsa->flags |= RSA_FLAG_NO_BLINDING; in RSA_blinding_off()
70 int RSA_blinding_on(RSA *rsa, BN_CTX *ctx) in RSA_blinding_on() argument
74 if (rsa->blinding != NULL) in RSA_blinding_on()
75 RSA_blinding_off(rsa); in RSA_blinding_on()
77 rsa->blinding = RSA_setup_blinding(rsa, ctx); in RSA_blinding_on()
78 if (rsa->blinding == NULL) in RSA_blinding_on()
81 rsa->flags |= RSA_FLAG_BLINDING; in RSA_blinding_on()
82 rsa->flags &= ~RSA_FLAG_NO_BLINDING; in RSA_blinding_on()
116 BN_BLINDING *RSA_setup_blinding(RSA *rsa, BN_CTX *in_ctx) in RSA_setup_blinding() argument
123 if ((ctx = BN_CTX_new_ex(rsa->libctx)) == NULL) in RSA_setup_blinding()
136 if (rsa->e == NULL) { in RSA_setup_blinding()
137 e = rsa_get_public_exp(rsa->d, rsa->p, rsa->q, ctx); in RSA_setup_blinding()
143 e = rsa->e; in RSA_setup_blinding()
153 BN_with_flags(n, rsa->n, BN_FLG_CONSTTIME); in RSA_setup_blinding()
155 ret = BN_BLINDING_create_param(NULL, e, n, ctx, rsa->meth->bn_mod_exp, in RSA_setup_blinding()
156 rsa->_method_mod_n); in RSA_setup_blinding()
171 if (e != rsa->e) in RSA_setup_blinding()