diff options
author | Richard Levitte <levitte@openssl.org> | 2019-11-05 17:34:09 +0100 |
---|---|---|
committer | Richard Levitte <levitte@openssl.org> | 2019-11-07 11:37:25 +0100 |
commit | 00db8c60aaecd2ff9b0a5d9fd10c7771a1e1a73e (patch) | |
tree | 55a6f88db1ff6e53c4fdcf17b074672ff64e9263 /crypto | |
parent | 936c2b9e933eacae80d3489e5f7316589f3e9a07 (diff) |
Update source files for pre-3.0 deprecation
Reviewed-by: Tim Hudson <tjh@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/10364)
Diffstat (limited to 'crypto')
-rw-r--r-- | crypto/asn1/asn1_lib.c | 2 | ||||
-rw-r--r-- | crypto/bio/b_sock.c | 6 | ||||
-rw-r--r-- | crypto/bn/bn_depr.c | 2 | ||||
-rw-r--r-- | crypto/bn/bn_lib.c | 2 | ||||
-rw-r--r-- | crypto/conf/conf_sap.c | 2 | ||||
-rw-r--r-- | crypto/dh/dh_depr.c | 2 | ||||
-rw-r--r-- | crypto/dsa/dsa_depr.c | 2 | ||||
-rw-r--r-- | crypto/engine/eng_all.c | 5 | ||||
-rw-r--r-- | crypto/err/err.c | 4 | ||||
-rw-r--r-- | crypto/evp/e_old.c | 2 | ||||
-rw-r--r-- | crypto/hmac/hmac.c | 2 | ||||
-rw-r--r-- | crypto/pkcs12/p12_sbag.c | 2 | ||||
-rw-r--r-- | crypto/rand/rand_lib.c | 2 | ||||
-rw-r--r-- | crypto/rand/rand_win.c | 2 | ||||
-rw-r--r-- | crypto/rsa/rsa_depr.c | 2 | ||||
-rw-r--r-- | crypto/srp/srp_vfy.c | 2 | ||||
-rw-r--r-- | crypto/x509/x509_d2.c | 2 | ||||
-rw-r--r-- | crypto/x509/x509cset.c | 2 |
18 files changed, 23 insertions, 22 deletions
diff --git a/crypto/asn1/asn1_lib.c b/crypto/asn1/asn1_lib.c index 6399de7c2a..52eb16ba9c 100644 --- a/crypto/asn1/asn1_lib.c +++ b/crypto/asn1/asn1_lib.c @@ -383,7 +383,7 @@ const unsigned char *ASN1_STRING_get0_data(const ASN1_STRING *x) return x->data; } -# if !OPENSSL_API_1_1_0 +# ifndef OPENSSL_NO_DEPRECATED_1_1_0 unsigned char *ASN1_STRING_data(ASN1_STRING *x) { return x->data; diff --git a/crypto/bio/b_sock.c b/crypto/bio/b_sock.c index 8e40d8644c..78bcffdb13 100644 --- a/crypto/bio/b_sock.c +++ b/crypto/bio/b_sock.c @@ -24,7 +24,7 @@ static int wsa_init_done = 0; # endif -# if !OPENSSL_API_1_1_0 +# ifndef OPENSSL_NO_DEPRECATED_1_1_0 int BIO_get_host_ip(const char *str, unsigned char *ip) { BIO_ADDRINFO *res = NULL; @@ -103,7 +103,7 @@ int BIO_sock_error(int sock) return j; } -# if !OPENSSL_API_1_1_0 +# ifndef OPENSSL_NO_DEPRECATED_1_1_0 struct hostent *BIO_gethostbyname(const char *name) { /* @@ -195,7 +195,7 @@ int BIO_socket_ioctl(int fd, long type, void *arg) return i; } -# if !OPENSSL_API_1_1_0 +# ifndef OPENSSL_NO_DEPRECATED_1_1_0 int BIO_get_accept_socket(char *host, int bind_mode) { int s = INVALID_SOCKET; diff --git a/crypto/bn/bn_depr.c b/crypto/bn/bn_depr.c index 4dbbdc3814..9c1c3d57c8 100644 --- a/crypto/bn/bn_depr.c +++ b/crypto/bn/bn_depr.c @@ -13,7 +13,7 @@ */ #include <openssl/opensslconf.h> -#if OPENSSL_API_0_9_8 +#ifdef OPENSSL_NO_DEPRECATED_0_9_8 NON_EMPTY_TRANSLATION_UNIT #else diff --git a/crypto/bn/bn_lib.c b/crypto/bn/bn_lib.c index bdd4caa21d..1e62b96874 100644 --- a/crypto/bn/bn_lib.c +++ b/crypto/bn/bn_lib.c @@ -15,7 +15,7 @@ #include "internal/constant_time.h" /* This stuff appears to be completely unused, so is deprecated */ -#if !OPENSSL_API_0_9_8 +#ifndef OPENSSL_NO_DEPRECATED_0_9_8 /*- * For a 32 bit machine * 2 - 4 == 128 diff --git a/crypto/conf/conf_sap.c b/crypto/conf/conf_sap.c index 921ff77085..2c5ee2a131 100644 --- a/crypto/conf/conf_sap.c +++ b/crypto/conf/conf_sap.c @@ -27,7 +27,7 @@ static int openssl_configured = 0; -#if !OPENSSL_API_1_1_0 +#ifndef OPENSSL_NO_DEPRECATED_1_1_0 void OPENSSL_config(const char *appname) { OPENSSL_INIT_SETTINGS settings; diff --git a/crypto/dh/dh_depr.c b/crypto/dh/dh_depr.c index f0903ca20a..09403f6ad5 100644 --- a/crypto/dh/dh_depr.c +++ b/crypto/dh/dh_depr.c @@ -10,7 +10,7 @@ /* This file contains deprecated functions as wrappers to the new ones */ #include <openssl/opensslconf.h> -#if OPENSSL_API_0_9_8 +#ifdef OPENSSL_NO_DEPRECATED_0_9_8 NON_EMPTY_TRANSLATION_UNIT #else diff --git a/crypto/dsa/dsa_depr.c b/crypto/dsa/dsa_depr.c index e97eaf124c..2b363e2642 100644 --- a/crypto/dsa/dsa_depr.c +++ b/crypto/dsa/dsa_depr.c @@ -20,7 +20,7 @@ #define xxxHASH EVP_sha1() #include <openssl/opensslconf.h> -#if OPENSSL_API_0_9_8 +#ifdef OPENSSL_NO_DEPRECATED_0_9_8 NON_EMPTY_TRANSLATION_UNIT #else diff --git a/crypto/engine/eng_all.c b/crypto/engine/eng_all.c index 0c5e4bdfd5..2f83b2ec18 100644 --- a/crypto/engine/eng_all.c +++ b/crypto/engine/eng_all.c @@ -15,9 +15,10 @@ void ENGINE_load_builtin_engines(void) OPENSSL_init_crypto(OPENSSL_INIT_ENGINE_ALL_BUILTIN, NULL); } -#if (defined(__OpenBSD__) || defined(__FreeBSD__) || defined(__DragonFly__)) \ - && !OPENSSL_API_1_1_0 +#ifndef OPENSSL_NO_DEPRECATED_1_1_0 +# if (defined(__OpenBSD__) || defined(__FreeBSD__) || defined(__DragonFly__)) void ENGINE_setup_bsd_cryptodev(void) { } +# endif #endif diff --git a/crypto/err/err.c b/crypto/err/err.c index b56eec8414..28a5db8ad4 100644 --- a/crypto/err/err.c +++ b/crypto/err/err.c @@ -659,13 +659,13 @@ static void err_delete_thread_state(void *arg) ERR_STATE_free(state); } -#if !OPENSSL_API_1_1_0 +#ifndef OPENSSL_NO_DEPRECATED_1_1_0 void ERR_remove_thread_state(void *dummy) { } #endif -#if !OPENSSL_API_1_0_0 +#ifndef OPENSSL_NO_DEPRECATED_1_0_0 void ERR_remove_state(unsigned long pid) { } diff --git a/crypto/evp/e_old.c b/crypto/evp/e_old.c index 02b16d0f97..82e0c1282c 100644 --- a/crypto/evp/e_old.c +++ b/crypto/evp/e_old.c @@ -8,7 +8,7 @@ */ #include <openssl/opensslconf.h> -#if OPENSSL_API_0_9_8 +#ifdef OPENSSL_NO_DEPRECATED_0_9_8 NON_EMPTY_TRANSLATION_UNIT #else diff --git a/crypto/hmac/hmac.c b/crypto/hmac/hmac.c index 17cc58717b..6d4d24d77b 100644 --- a/crypto/hmac/hmac.c +++ b/crypto/hmac/hmac.c @@ -86,7 +86,7 @@ int HMAC_Init_ex(HMAC_CTX *ctx, const void *key, int len, return rv; } -#if !OPENSSL_API_1_1_0 +#ifndef OPENSSL_NO_DEPRECATED_1_1_0 int HMAC_Init(HMAC_CTX *ctx, const void *key, int len, const EVP_MD *md) { if (key && md) diff --git a/crypto/pkcs12/p12_sbag.c b/crypto/pkcs12/p12_sbag.c index 2b4ca65399..ccb9acb17e 100644 --- a/crypto/pkcs12/p12_sbag.c +++ b/crypto/pkcs12/p12_sbag.c @@ -12,7 +12,7 @@ #include <openssl/pkcs12.h> #include "p12_local.h" -#if !OPENSSL_API_1_1_0 +#ifndef OPENSSL_NO_DEPRECATED_1_1_0 ASN1_TYPE *PKCS12_get_attr(const PKCS12_SAFEBAG *bag, int attr_nid) { return PKCS12_get_attr_gen(bag->attrib, attr_nid); diff --git a/crypto/rand/rand_lib.c b/crypto/rand/rand_lib.c index 3508cfb25c..c6b4ad3ae4 100644 --- a/crypto/rand/rand_lib.c +++ b/crypto/rand/rand_lib.c @@ -896,7 +896,7 @@ int RAND_bytes(unsigned char *buf, int num) return rand_bytes_ex(NULL, buf, num); } -#if !OPENSSL_API_1_1_0 && !defined(FIPS_MODE) +#if !defined(OPENSSL_NO_DEPRECATED_1_1_0) && !defined(FIPS_MODE) int RAND_pseudo_bytes(unsigned char *buf, int num) { const RAND_METHOD *meth = RAND_get_rand_method(); diff --git a/crypto/rand/rand_win.c b/crypto/rand/rand_win.c index 5f67c87c3c..40b0de9209 100644 --- a/crypto/rand/rand_win.c +++ b/crypto/rand/rand_win.c @@ -163,7 +163,7 @@ int rand_pool_add_additional_data(RAND_POOL *pool) return rand_pool_add(pool, (unsigned char *)&data, sizeof(data), 0); } -# if !OPENSSL_API_1_1_0 && !defined(FIPS_MODE) +# if !defined(OPENSSL_NO_DEPRECATED_1_1_0) && !defined(FIPS_MODE) int RAND_event(UINT iMsg, WPARAM wParam, LPARAM lParam) { RAND_poll(); diff --git a/crypto/rsa/rsa_depr.c b/crypto/rsa/rsa_depr.c index c34c605859..ed63262645 100644 --- a/crypto/rsa/rsa_depr.c +++ b/crypto/rsa/rsa_depr.c @@ -13,7 +13,7 @@ */ #include <openssl/opensslconf.h> -#if OPENSSL_API_0_9_8 +#ifdef OPENSSL_NO_DEPRECATED_0_9_8 NON_EMPTY_TRANSLATION_UNIT #else diff --git a/crypto/srp/srp_vfy.c b/crypto/srp/srp_vfy.c index c4dd5153f2..9505d4265e 100644 --- a/crypto/srp/srp_vfy.c +++ b/crypto/srp/srp_vfy.c @@ -525,7 +525,7 @@ int SRP_VBASE_add0_user(SRP_VBASE *vb, SRP_user_pwd *user_pwd) return 1; } -# if !OPENSSL_API_1_1_0 +# ifndef OPENSSL_NO_DEPRECATED_1_1_0 /* * DEPRECATED: use SRP_VBASE_get1_by_user instead. * This method ignores the configured seed and fails for an unknown user. diff --git a/crypto/x509/x509_d2.c b/crypto/x509/x509_d2.c index 5beb7034a7..cb0f84a7e8 100644 --- a/crypto/x509/x509_d2.c +++ b/crypto/x509/x509_d2.c @@ -74,7 +74,7 @@ int X509_STORE_load_store(X509_STORE *ctx, const char *uri) } /* Deprecated */ -#if OPENSSL_API_LEVEL < 3 +#ifndef OPENSSL_NO_DEPRECATED_3_0 int X509_STORE_load_locations(X509_STORE *ctx, const char *file, const char *path) { diff --git a/crypto/x509/x509cset.c b/crypto/x509/x509cset.c index f1992ddcf0..2350995239 100644 --- a/crypto/x509/x509cset.c +++ b/crypto/x509/x509cset.c @@ -91,7 +91,7 @@ const ASN1_TIME *X509_CRL_get0_nextUpdate(const X509_CRL *crl) return crl->crl.nextUpdate; } -#if !OPENSSL_API_1_1_0 +#ifndef OPENSSL_NO_DEPRECATED_1_1_0 ASN1_TIME *X509_CRL_get_lastUpdate(X509_CRL *crl) { return crl->crl.lastUpdate; |