Lines Matching defs:rsa
60 # include <openssl/rsa.h>
111 static int cryptodev_rsa_nocrt_mod_exp(BIGNUM *r0, const BIGNUM *I, RSA *rsa,
113 static int cryptodev_rsa_mod_exp(BIGNUM *r0, const BIGNUM *I, RSA *rsa,
1152 cryptodev_rsa_nocrt_mod_exp(BIGNUM *r0, const BIGNUM *I, RSA *rsa,
1157 r = cryptodev_bn_mod_exp(r0, I, rsa->d, rsa->n, ctx, NULL);
1163 cryptodev_rsa_mod_exp(BIGNUM *r0, const BIGNUM *I, RSA *rsa, BN_CTX *ctx)
1168 if (!rsa->p || !rsa->q || !rsa->dmp1 || !rsa->dmq1 || !rsa->iqmp) {
1175 /* inputs: rsa->p rsa->q I rsa->dmp1 rsa->dmq1 rsa->iqmp */
1176 if (bn2crparam(rsa->p, &kop.crk_param[0]))
1178 if (bn2crparam(rsa->q, &kop.crk_param[1]))
1182 if (bn2crparam(rsa->dmp1, &kop.crk_param[3]))
1184 if (bn2crparam(rsa->dmq1, &kop.crk_param[4]))
1186 if (bn2crparam(rsa->iqmp, &kop.crk_param[5]))
1190 if (cryptodev_asym(&kop, BN_num_bytes(rsa->n), r0, 0, NULL)) {
1193 ret = (*meth->rsa_mod_exp) (r0, I, rsa, ctx);
1198 ret = (*meth->rsa_mod_exp) (r0, I, rsa, ctx);