diff options
author | Pauli <paul.dale@oracle.com> | 2020-01-09 09:08:31 +1000 |
---|---|---|
committer | Pauli <paul.dale@oracle.com> | 2020-01-12 12:00:31 +1000 |
commit | 601fca1778f8d3cb38031655d2aa01b91b8f0cde (patch) | |
tree | 651fb601498df124cfba7443d029eae278067192 /crypto | |
parent | 65167dba890b2e92821ee3b90e8f7f46fa30f9c1 (diff) |
Deprecate the low level RIPEMD160 functions.
Use of the low level RIPEMD160 functions has been informally discouraged for a
long time. We now formally deprecate them.
Applications should instead use the EVP APIs, e.g. EVP_Digest,
EVP_DigestInit_ex, EVP_DigestUpdate and EVP_DigestFinal_ex.
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
(Merged from https://github.com/openssl/openssl/pull/10789)
Diffstat (limited to 'crypto')
-rw-r--r-- | crypto/evp/legacy_ripemd.c | 6 | ||||
-rw-r--r-- | crypto/ripemd/build.info | 14 | ||||
-rw-r--r-- | crypto/ripemd/rmd_dgst.c | 6 | ||||
-rw-r--r-- | crypto/ripemd/rmd_one.c | 6 |
4 files changed, 29 insertions, 3 deletions
diff --git a/crypto/evp/legacy_ripemd.c b/crypto/evp/legacy_ripemd.c index 8edcbba371..fd1739c7cd 100644 --- a/crypto/evp/legacy_ripemd.c +++ b/crypto/evp/legacy_ripemd.c @@ -7,6 +7,12 @@ * https://www.openssl.org/source/license.html */ +/* + * RIPEMD160 low level APIs are deprecated for public use, but still ok for + * internal use. + */ +#include "internal/deprecated.h" + #include <openssl/ripemd.h> #include "crypto/evp.h" #include "legacy_meth.h" diff --git a/crypto/ripemd/build.info b/crypto/ripemd/build.info index a0a45b0e84..055da5dab8 100644 --- a/crypto/ripemd/build.info +++ b/crypto/ripemd/build.info @@ -12,12 +12,20 @@ IF[{- !$disabled{asm} -}] ENDIF ENDIF -SOURCE[../../libcrypto]=rmd_dgst.c rmd_one.c $RMD160ASM - # Implementations are now spread across several libraries, so the defines # need to be applied to all affected libraries and modules -DEFINE[../../libcrypto]=$RMD160DEF DEFINE[../providers/libimplementations.a]=$RMD160DEF +SOURCE[../../libcrypto]=rmd_dgst.c rmd_one.c $RMD160ASM +DEFINE[../../libcrypto]=$RMD160DEF + +# When all deprecated symbols are removed, libcrypto doesn't export the +# RIPEMD160 functions, so we must include them directly in liblegacy.a +IF[{- $disabled{"deprecated"} + && (defined $config{"api"} && $config{"api"} >= 30000) -}] + SOURCE[../../providers/liblegacy.a]=rmd_dgst.c rmd_one.c $RMD160ASM + DEFINE[../../providers/liblegacy.a]=$RMD160DEF +ENDIF + GENERATE[rmd-586.s]=asm/rmd-586.pl DEPEND[rmd-586.s]=../perlasm/x86asm.pl diff --git a/crypto/ripemd/rmd_dgst.c b/crypto/ripemd/rmd_dgst.c index f4a69c8862..d815f173cd 100644 --- a/crypto/ripemd/rmd_dgst.c +++ b/crypto/ripemd/rmd_dgst.c @@ -7,6 +7,12 @@ * https://www.openssl.org/source/license.html */ +/* + * RIPEMD160 low level APIs are deprecated for public use, but still ok for + * internal use. + */ +#include "internal/deprecated.h" + #include <stdio.h> #include "rmd_local.h" #include <openssl/opensslv.h> diff --git a/crypto/ripemd/rmd_one.c b/crypto/ripemd/rmd_one.c index 5efb36b887..30a83da8db 100644 --- a/crypto/ripemd/rmd_one.c +++ b/crypto/ripemd/rmd_one.c @@ -7,6 +7,12 @@ * https://www.openssl.org/source/license.html */ +/* + * RIPEMD160 low level APIs are deprecated for public use, but still ok for + * internal use. + */ +#include "internal/deprecated.h" + #include <stdio.h> #include <string.h> #include <openssl/ripemd.h> |