# ifndef OPENSSL_NO_RSA
/*
- * We know that the "PKCS1_SSLeay()" functions hook properly to the
+ * We know that the "PKCS1_OpenSSL()" functions hook properly to the
* Broadcom-specific mod_exp and mod_exp_crt so we use those functions.
* NB: We don't use ENGINE_openssl() or anything "more generic" because
* something like the RSAref code may not hook properly, and if you own
* one of these cards then you have the right to do RSA operations on it
* anyway!
*/
- meth1 = RSA_PKCS1_SSLeay();
+ meth1 = RSA_PKCS1_OpenSSL();
ubsec_rsa.rsa_pub_enc = meth1->rsa_pub_enc;
ubsec_rsa.rsa_pub_dec = meth1->rsa_pub_dec;
ubsec_rsa.rsa_priv_enc = meth1->rsa_priv_enc;
static ENGINE *engine_ubsec(void)
{
ENGINE *ret = ENGINE_new();
- if (!ret)
+ if (ret == NULL)
return NULL;
if (!bind_helper(ret)) {
ENGINE_free(ret);
static long set_UBSEC_LIBNAME(const char *name)
{
free_UBSEC_LIBNAME();
- return (((UBSEC_LIBNAME = BUF_strdup(name)) != NULL) ? 1 : 0);
+ return (((UBSEC_LIBNAME = OPENSSL_strdup(name)) != NULL) ? 1 : 0);
}
static const char *UBSEC_F1 = "ubsec_bytes_to_bits";
/*
* Do in software as hardware failed.
*/
- const RSA_METHOD *meth = RSA_PKCS1_SSLeay();
+ const RSA_METHOD *meth = RSA_PKCS1_OpenSSL();
to_return = (*meth->rsa_mod_exp) (r0, I, rsa, ctx);
}
err:
/* Do in software if the key is too large for the hardware. */
if (BN_num_bits(m) > max_key_len) {
- const RSA_METHOD *meth = RSA_PKCS1_SSLeay();
+ const RSA_METHOD *meth = RSA_PKCS1_OpenSSL();
ret = (*meth->bn_mod_exp) (r, a, p, m, ctx, m_ctx);
} else {
ret = ubsec_mod_exp(r, a, p, m, ctx);
const RAND_METHOD *meth;
UBSECerr(UBSEC_F_UBSEC_RAND_BYTES, UBSEC_R_UNIT_FAILURE);
num = p_UBSEC_ubsec_bits_to_bytes(num);
- meth = RAND_SSLeay();
+ meth = RAND_OpenSSL();
meth->seed(buf, num);
ret = meth->bytes(buf, num);
goto err;
p_UBSEC_ubsec_close(fd);
num = p_UBSEC_ubsec_bits_to_bytes(num);
- meth = RAND_SSLeay();
+ meth = RAND_OpenSSL();
meth->seed(buf, num);
ret = meth->bytes(buf, num);