summaryrefslogtreecommitdiffstats
path: root/crypto/pem
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/pem')
-rw-r--r--crypto/pem/pem_all.c6
-rw-r--r--crypto/pem/pem_info.c4
-rw-r--r--crypto/pem/pem_seal.c1
3 files changed, 11 insertions, 0 deletions
diff --git a/crypto/pem/pem_all.c b/crypto/pem/pem_all.c
index a9ac52de02..66cbc7eb82 100644
--- a/crypto/pem/pem_all.c
+++ b/crypto/pem/pem_all.c
@@ -117,9 +117,15 @@
#include <openssl/x509.h>
#include <openssl/pkcs7.h>
#include <openssl/pem.h>
+#ifndef OPENSSL_NO_RSA
#include <openssl/rsa.h>
+#endif
+#ifndef OPENSSL_NO_DSA
#include <openssl/dsa.h>
+#endif
+#ifndef OPENSSL_NO_DH
#include <openssl/dh.h>
+#endif
#ifndef OPENSSL_NO_RSA
static RSA *pkey_get_rsa(EVP_PKEY *key, RSA **rsa);
diff --git a/crypto/pem/pem_info.c b/crypto/pem/pem_info.c
index 489e71a892..1644dfcaac 100644
--- a/crypto/pem/pem_info.c
+++ b/crypto/pem/pem_info.c
@@ -63,8 +63,12 @@
#include <openssl/evp.h>
#include <openssl/x509.h>
#include <openssl/pem.h>
+#ifndef OPENSSL_NO_RSA
#include <openssl/rsa.h>
+#endif
+#ifndef OPENSSL_NO_DSA
#include <openssl/dsa.h>
+#endif
#ifndef OPENSSL_NO_FP_API
STACK_OF(X509_INFO) *PEM_X509_INFO_read(FILE *fp, STACK_OF(X509_INFO) *sk, pem_password_cb *cb, void *u)
diff --git a/crypto/pem/pem_seal.c b/crypto/pem/pem_seal.c
index 0458093353..4e554e5481 100644
--- a/crypto/pem/pem_seal.c
+++ b/crypto/pem/pem_seal.c
@@ -56,6 +56,7 @@
* [including the GNU Public Licence.]
*/
+#include <openssl/opensslconf.h> /* for OPENSSL_NO_RSA */
#ifndef OPENSSL_NO_RSA
#include <stdio.h>
#include "cryptlib.h"