diff options
author | Richard Levitte <levitte@openssl.org> | 2016-08-05 01:54:27 +0200 |
---|---|---|
committer | Richard Levitte <levitte@openssl.org> | 2016-08-05 21:18:15 +0200 |
commit | e38da82047ae92e78c948cdc31933957f367e538 (patch) | |
tree | ab89f3bcd6ec41045401f6d15610ff50237e137b | |
parent | 72c7658118dea1f4b65c699ba7225004138be179 (diff) |
Remove OPENSSL_NO_STDIO guards around certain SSL cert/key functions
These functions are:
SSL_use_certificate_file
SSL_use_RSAPrivateKey_file
SSL_use_PrivateKey_file
SSL_CTX_use_certificate_file
SSL_CTX_use_RSAPrivateKey_file
SSL_CTX_use_PrivateKey_file
SSL_use_certificate_chain_file
Internally, they use BIO_s_file(), which is defined and implemented at
all times, even when OpenSSL is configured no-stdio.
Reviewed-by: Rich Salz <rsalz@openssl.org>
-rw-r--r-- | ssl/ssl_rsa.c | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/ssl/ssl_rsa.c b/ssl/ssl_rsa.c index bb4e872ab4..3484536400 100644 --- a/ssl/ssl_rsa.c +++ b/ssl/ssl_rsa.c @@ -33,7 +33,6 @@ int SSL_use_certificate(SSL *ssl, X509 *x) return (ssl_set_cert(ssl->cert, x)); } -#ifndef OPENSSL_NO_STDIO int SSL_use_certificate_file(SSL *ssl, const char *file, int type) { int j; @@ -74,7 +73,6 @@ int SSL_use_certificate_file(SSL *ssl, const char *file, int type) BIO_free(in); return (ret); } -#endif int SSL_use_certificate_ASN1(SSL *ssl, const unsigned char *d, int len) { @@ -167,7 +165,6 @@ static int ssl_set_pkey(CERT *c, EVP_PKEY *pkey) } #ifndef OPENSSL_NO_RSA -# ifndef OPENSSL_NO_STDIO int SSL_use_RSAPrivateKey_file(SSL *ssl, const char *file, int type) { int j, ret = 0; @@ -207,7 +204,6 @@ int SSL_use_RSAPrivateKey_file(SSL *ssl, const char *file, int type) BIO_free(in); return (ret); } -# endif int SSL_use_RSAPrivateKey_ASN1(SSL *ssl, const unsigned char *d, long len) { @@ -239,7 +235,6 @@ int SSL_use_PrivateKey(SSL *ssl, EVP_PKEY *pkey) return (ret); } -#ifndef OPENSSL_NO_STDIO int SSL_use_PrivateKey_file(SSL *ssl, const char *file, int type) { int j, ret = 0; @@ -279,7 +274,6 @@ int SSL_use_PrivateKey_file(SSL *ssl, const char *file, int type) BIO_free(in); return (ret); } -#endif int SSL_use_PrivateKey_ASN1(int type, SSL *ssl, const unsigned char *d, long len) @@ -375,7 +369,6 @@ static int ssl_set_cert(CERT *c, X509 *x) return 1; } -#ifndef OPENSSL_NO_STDIO int SSL_CTX_use_certificate_file(SSL_CTX *ctx, const char *file, int type) { int j; @@ -416,7 +409,6 @@ int SSL_CTX_use_certificate_file(SSL_CTX *ctx, const char *file, int type) BIO_free(in); return (ret); } -#endif int SSL_CTX_use_certificate_ASN1(SSL_CTX *ctx, int len, const unsigned char *d) @@ -462,7 +454,6 @@ int SSL_CTX_use_RSAPrivateKey(SSL_CTX *ctx, RSA *rsa) return (ret); } -# ifndef OPENSSL_NO_STDIO int SSL_CTX_use_RSAPrivateKey_file(SSL_CTX *ctx, const char *file, int type) { int j, ret = 0; @@ -501,7 +492,6 @@ int SSL_CTX_use_RSAPrivateKey_file(SSL_CTX *ctx, const char *file, int type) BIO_free(in); return (ret); } -# endif int SSL_CTX_use_RSAPrivateKey_ASN1(SSL_CTX *ctx, const unsigned char *d, long len) @@ -531,7 +521,6 @@ int SSL_CTX_use_PrivateKey(SSL_CTX *ctx, EVP_PKEY *pkey) return (ssl_set_pkey(ctx->cert, pkey)); } -#ifndef OPENSSL_NO_STDIO int SSL_CTX_use_PrivateKey_file(SSL_CTX *ctx, const char *file, int type) { int j, ret = 0; @@ -570,7 +559,6 @@ int SSL_CTX_use_PrivateKey_file(SSL_CTX *ctx, const char *file, int type) BIO_free(in); return (ret); } -#endif int SSL_CTX_use_PrivateKey_ASN1(int type, SSL_CTX *ctx, const unsigned char *d, long len) @@ -590,7 +578,6 @@ int SSL_CTX_use_PrivateKey_ASN1(int type, SSL_CTX *ctx, return (ret); } -#ifndef OPENSSL_NO_STDIO /* * Read a file that contains our certificate in "PEM" format, possibly * followed by a sequence of CA certificates that should be sent to the peer @@ -702,7 +689,6 @@ int SSL_use_certificate_chain_file(SSL *ssl, const char *file) { return use_certificate_chain_file(NULL, ssl, file); } -#endif static int serverinfo_find_extension(const unsigned char *serverinfo, size_t serverinfo_length, |