Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/boringssl.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/crypto
diff options
context:
space:
mode:
authorAlex Chernyakhovsky <achernya@google.com>2014-07-05 07:43:44 +0400
committerAdam Langley <agl@google.com>2014-07-08 00:20:53 +0400
commit3c5034e97ca6eb204f06b030c70fc6644bb217d4 (patch)
tree5edd871f29c0e464adc08b511b95e5886ba61615 /crypto
parentc6318e349af35290bb937b56cd7539cfedc35a5b (diff)
Remove OPENSSL_NO_RSA
Building without RSA support is unreasonable. Changes were made by running find . -type f -name *.c | xargs unifdef -m -U OPENSSL_NO_RSA find . -type f -name *.h | xargs unifdef -m -U OPENSSL_NO_RSA using unifdef 2.10 and some newlines were removed manually. Change-Id: Iea559e2d4b3d1053f28a4a9cc2f7a3d1f6cabd61 Reviewed-on: https://boringssl-review.googlesource.com/1095 Reviewed-by: Adam Langley <agl@google.com>
Diffstat (limited to 'crypto')
-rw-r--r--crypto/pem/pem.h4
-rw-r--r--crypto/pem/pem_all.c2
-rw-r--r--crypto/pem/pem_info.c4
-rw-r--r--crypto/x509/x509.h6
-rw-r--r--crypto/x509/x_all.c3
-rw-r--r--crypto/x509/x_pubkey.c2
6 files changed, 0 insertions, 21 deletions
diff --git a/crypto/pem/pem.h b/crypto/pem/pem.h
index 469fbd22..464aae41 100644
--- a/crypto/pem/pem.h
+++ b/crypto/pem/pem.h
@@ -471,15 +471,11 @@ DECLARE_PEM_rw(PKCS8, X509_SIG)
DECLARE_PEM_rw(PKCS8_PRIV_KEY_INFO, PKCS8_PRIV_KEY_INFO)
-#ifndef OPENSSL_NO_RSA
-
DECLARE_PEM_rw_cb(RSAPrivateKey, RSA)
DECLARE_PEM_rw_const(RSAPublicKey, RSA)
DECLARE_PEM_rw(RSA_PUBKEY, RSA)
-#endif
-
#ifndef OPENSSL_NO_DSA
DECLARE_PEM_rw_cb(DSAPrivateKey, DSA)
diff --git a/crypto/pem/pem_all.c b/crypto/pem/pem_all.c
index ccdc2e82..aa0c971f 100644
--- a/crypto/pem/pem_all.c
+++ b/crypto/pem/pem_all.c
@@ -130,7 +130,6 @@ IMPLEMENT_PEM_write(X509_REQ_NEW, X509_REQ, PEM_STRING_X509_REQ_OLD, X509_REQ)
IMPLEMENT_PEM_rw(X509_CRL, X509_CRL, PEM_STRING_X509_CRL, X509_CRL)
-#ifndef OPENSSL_NO_RSA
/* We treat RSA or DSA private keys as a special case.
*
@@ -232,7 +231,6 @@ IMPLEMENT_PEM_write_cb_const(RSAPrivateKey, RSA, PEM_STRING_RSA, RSAPrivateKey)
IMPLEMENT_PEM_rw_const(RSAPublicKey, RSA, PEM_STRING_RSA_PUBLIC, RSAPublicKey)
IMPLEMENT_PEM_rw(RSA_PUBKEY, RSA, PEM_STRING_PUBLIC, RSA_PUBKEY)
-#endif
#ifndef OPENSSL_NO_DSA
diff --git a/crypto/pem/pem_info.c b/crypto/pem/pem_info.c
index 9536e49f..6e59a7fc 100644
--- a/crypto/pem/pem_info.c
+++ b/crypto/pem/pem_info.c
@@ -165,7 +165,6 @@ start:
pp=&(xi->crl);
}
else
-#ifndef OPENSSL_NO_RSA
if (strcmp(name,PEM_STRING_RSA) == 0)
{
d2i=(D2I_OF(void))d2i_RSAPrivateKey;
@@ -186,7 +185,6 @@ start:
raw=1;
}
else
-#endif
#ifndef OPENSSL_NO_DSA
if (strcmp(name,PEM_STRING_DSA) == 0)
{
@@ -380,13 +378,11 @@ int PEM_X509_INFO_write_bio(BIO *bp, X509_INFO *xi, EVP_CIPHER *enc,
else
{
/* Add DSA/DH */
-#ifndef OPENSSL_NO_RSA
/* normal optionally encrypted stuff */
if (PEM_write_bio_RSAPrivateKey(bp,
xi->x_pkey->dec_pkey->pkey.rsa,
enc,kstr,klen,cb,u)<=0)
goto err;
-#endif
}
}
diff --git a/crypto/x509/x509.h b/crypto/x509/x509.h
index 86472299..d7ab2ce5 100644
--- a/crypto/x509/x509.h
+++ b/crypto/x509/x509.h
@@ -659,14 +659,12 @@ X509_CRL *d2i_X509_CRL_fp(FILE *fp,X509_CRL **crl);
int i2d_X509_CRL_fp(FILE *fp,X509_CRL *crl);
X509_REQ *d2i_X509_REQ_fp(FILE *fp,X509_REQ **req);
int i2d_X509_REQ_fp(FILE *fp,X509_REQ *req);
-#ifndef OPENSSL_NO_RSA
RSA *d2i_RSAPrivateKey_fp(FILE *fp,RSA **rsa);
int i2d_RSAPrivateKey_fp(FILE *fp,RSA *rsa);
RSA *d2i_RSAPublicKey_fp(FILE *fp,RSA **rsa);
int i2d_RSAPublicKey_fp(FILE *fp,RSA *rsa);
RSA *d2i_RSA_PUBKEY_fp(FILE *fp,RSA **rsa);
int i2d_RSA_PUBKEY_fp(FILE *fp,RSA *rsa);
-#endif
#ifndef OPENSSL_NO_DSA
DSA *d2i_DSA_PUBKEY_fp(FILE *fp, DSA **dsa);
int i2d_DSA_PUBKEY_fp(FILE *fp, DSA *dsa);
@@ -698,14 +696,12 @@ X509_CRL *d2i_X509_CRL_bio(BIO *bp,X509_CRL **crl);
int i2d_X509_CRL_bio(BIO *bp,X509_CRL *crl);
X509_REQ *d2i_X509_REQ_bio(BIO *bp,X509_REQ **req);
int i2d_X509_REQ_bio(BIO *bp,X509_REQ *req);
-#ifndef OPENSSL_NO_RSA
RSA *d2i_RSAPrivateKey_bio(BIO *bp,RSA **rsa);
int i2d_RSAPrivateKey_bio(BIO *bp,RSA *rsa);
RSA *d2i_RSAPublicKey_bio(BIO *bp,RSA **rsa);
int i2d_RSAPublicKey_bio(BIO *bp,RSA *rsa);
RSA *d2i_RSA_PUBKEY_bio(BIO *bp,RSA **rsa);
int i2d_RSA_PUBKEY_bio(BIO *bp,RSA *rsa);
-#endif
#ifndef OPENSSL_NO_DSA
DSA *d2i_DSA_PUBKEY_bio(BIO *bp, DSA **dsa);
int i2d_DSA_PUBKEY_bio(BIO *bp, DSA *dsa);
@@ -774,11 +770,9 @@ int X509_get_pubkey_parameters(EVP_PKEY *pkey,
int i2d_PUBKEY(const EVP_PKEY *a,unsigned char **pp);
EVP_PKEY * d2i_PUBKEY(EVP_PKEY **a,const unsigned char **pp,
long length);
-#ifndef OPENSSL_NO_RSA
int i2d_RSA_PUBKEY(const RSA *a,unsigned char **pp);
RSA * d2i_RSA_PUBKEY(RSA **a,const unsigned char **pp,
long length);
-#endif
#ifndef OPENSSL_NO_DSA
int i2d_DSA_PUBKEY(const DSA *a,unsigned char **pp);
DSA * d2i_DSA_PUBKEY(DSA **a,const unsigned char **pp,
diff --git a/crypto/x509/x_all.c b/crypto/x509/x_all.c
index 49e35e54..08cc79d7 100644
--- a/crypto/x509/x_all.c
+++ b/crypto/x509/x_all.c
@@ -233,7 +233,6 @@ int i2d_X509_REQ_bio(BIO *bp, X509_REQ *req)
return ASN1_item_i2d_bio(ASN1_ITEM_rptr(X509_REQ), bp, req);
}
-#ifndef OPENSSL_NO_RSA
#ifndef OPENSSL_NO_FP_API
RSA *d2i_RSAPrivateKey_fp(FILE *fp, RSA **rsa)
@@ -251,7 +250,6 @@ RSA *d2i_RSAPublicKey_fp(FILE *fp, RSA **rsa)
return ASN1_item_d2i_fp(ASN1_ITEM_rptr(RSAPublicKey), fp, rsa);
}
-
RSA *d2i_RSA_PUBKEY_fp(FILE *fp, RSA **rsa)
{
return ASN1_d2i_fp((void *(*)(void))
@@ -300,7 +298,6 @@ int i2d_RSA_PUBKEY_bio(BIO *bp, RSA *rsa)
{
return ASN1_i2d_bio_of_const(RSA,i2d_RSA_PUBKEY,bp,rsa);
}
-#endif
#ifndef OPENSSL_NO_DSA
#ifndef OPENSSL_NO_FP_API
diff --git a/crypto/x509/x_pubkey.c b/crypto/x509/x_pubkey.c
index df1d4af2..d1b21465 100644
--- a/crypto/x509/x_pubkey.c
+++ b/crypto/x509/x_pubkey.c
@@ -224,7 +224,6 @@ int i2d_PUBKEY(const EVP_PKEY *a, unsigned char **pp)
/* The following are equivalents but which return RSA and DSA
* keys
*/
-#ifndef OPENSSL_NO_RSA
RSA *d2i_RSA_PUBKEY(RSA **a, const unsigned char **pp,
long length)
{
@@ -262,7 +261,6 @@ int i2d_RSA_PUBKEY(const RSA *a, unsigned char **pp)
EVP_PKEY_free(pktmp);
return ret;
}
-#endif
#ifndef OPENSSL_NO_DSA
DSA *d2i_DSA_PUBKEY(DSA **a, const unsigned char **pp,