int RSA_generate_multi_prime_key(RSA *rsa, int bits, int primes,
BIGNUM *e_value, BN_GENCB *cb)
{
int RSA_generate_multi_prime_key(RSA *rsa, int bits, int primes,
BIGNUM *e_value, BN_GENCB *cb)
{
/* multi-prime is only supported with the builtin key generation */
if (rsa->meth->rsa_multi_prime_keygen != NULL) {
return rsa->meth->rsa_multi_prime_keygen(rsa, bits, primes,
/* multi-prime is only supported with the builtin key generation */
if (rsa->meth->rsa_multi_prime_keygen != NULL) {
return rsa->meth->rsa_multi_prime_keygen(rsa, bits, primes,
return rsa_keygen(NULL, rsa, bits, primes, e_value, cb, 0);
}
return rsa_keygen(NULL, rsa, bits, primes, e_value, cb, 0);
}
if (primes != 2)
return 0;
ok = rsa_sp800_56b_generate_key(rsa, bits, e_value, cb);
if (primes != 2)
return 0;
ok = rsa_sp800_56b_generate_key(rsa, bits, e_value, cb);