diff --git a/src/native/libs/System.Security.Cryptography.Native/configure.cmake b/src/native/libs/System.Security.Cryptography.Native/configure.cmake index 78caad3fd5bd25..89d4c6c4760a0a 100644 --- a/src/native/libs/System.Security.Cryptography.Native/configure.cmake +++ b/src/native/libs/System.Security.Cryptography.Native/configure.cmake @@ -35,11 +35,6 @@ check_source_compiles(C " int main(void) { ENGINE_init(NULL); return 1; }" HAVE_OPENSSL_ENGINE) -check_source_compiles(C " -#include -int main(void) { RSA *r = RSA_new(); RSA_free(r); return 0; }" -HAVE_OPENSSL_RSA_PRIMITIVE) - configure_file( ${CMAKE_CURRENT_SOURCE_DIR}/pal_crypto_config.h.in ${CMAKE_CURRENT_BINARY_DIR}/pal_crypto_config.h) diff --git a/src/native/libs/System.Security.Cryptography.Native/opensslshim.h b/src/native/libs/System.Security.Cryptography.Native/opensslshim.h index 22425beb8a4126..156f4470ae3d5c 100644 --- a/src/native/libs/System.Security.Cryptography.Native/opensslshim.h +++ b/src/native/libs/System.Security.Cryptography.Native/opensslshim.h @@ -209,26 +209,6 @@ int SSL_set_ciphersuites(SSL *s, const char *str); const SSL_CIPHER* SSL_CIPHER_find(SSL *ssl, const unsigned char *ptr); #endif -#if !HAVE_OPENSSL_RSA_PRIMITIVE -// In portable build, we need to support legacy RSA functions even if they were not present -// on the build OS. The shim will detect their presence at runtime. -#undef HAVE_OPENSSL_RSA_PRIMITIVE -#define HAVE_OPENSSL_RSA_PRIMITIVE 1 - -typedef struct rsa_st RSA; -typedef struct rsa_meth_st RSA_METHOD; - -const RSA* EVP_PKEY_get0_RSA(const EVP_PKEY* pkey); -int EVP_PKEY_set1_RSA(EVP_PKEY* pkey, RSA* key); -const RSA_METHOD* RSA_get_method(const RSA* rsa); -int RSA_get_multi_prime_extra_count(const RSA* rsa); -void RSA_get0_key(const RSA* r, const BIGNUM** n, const BIGNUM** e, const BIGNUM** d); -void RSA_get0_factors(const RSA* r, const BIGNUM** p, const BIGNUM** q); -void RSA_get0_crt_params(const RSA* r, const BIGNUM** dmp1, const BIGNUM** dmq1, const BIGNUM** iqmp); -int RSA_meth_get_flags(const RSA_METHOD* meth); -int RSA_test_flags(const RSA* r, int flags); -#endif - #if OPENSSL_VERSION_NUMBER < OPENSSL_VERSION_4_0_RTM #include "osslcompat_40.h" #endif diff --git a/src/native/libs/System.Security.Cryptography.Native/pal_crypto_config.h.in b/src/native/libs/System.Security.Cryptography.Native/pal_crypto_config.h.in index 2e54fbf405321d..d09ed47fa02843 100644 --- a/src/native/libs/System.Security.Cryptography.Native/pal_crypto_config.h.in +++ b/src/native/libs/System.Security.Cryptography.Native/pal_crypto_config.h.in @@ -6,4 +6,3 @@ #cmakedefine01 HAVE_OPENSSL_SHA3_SQUEEZE #cmakedefine01 HAVE_OPENSSL_EVP_PKEY_SIGN_MESSAGE_INIT #cmakedefine01 HAVE_OPENSSL_ENGINE -#cmakedefine01 HAVE_OPENSSL_RSA_PRIMITIVE