diff options
author | Pauli <paul.dale@oracle.com> | 2020-01-09 10:16:21 +1000 |
---|---|---|
committer | Pauli <paul.dale@oracle.com> | 2020-01-12 12:02:17 +1000 |
commit | 58e1f3d6d4046355df272af0261179bf9999d473 (patch) | |
tree | 40d8b94b709ddf1c820cb9fd1b17d8567896e1d1 /crypto/md2 | |
parent | b2be1ea2c37cc9ac1c44e34f50df2b2207abdbdd (diff) |
Deprecate the low level MD2 functions.
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
(Merged from https://github.com/openssl/openssl/pull/10790)
Diffstat (limited to 'crypto/md2')
-rw-r--r-- | crypto/md2/build.info | 11 | ||||
-rw-r--r-- | crypto/md2/md2_dgst.c | 6 | ||||
-rw-r--r-- | crypto/md2/md2_one.c | 6 |
3 files changed, 21 insertions, 2 deletions
diff --git a/crypto/md2/build.info b/crypto/md2/build.info index e31948c23f..d682cfa658 100644 --- a/crypto/md2/build.info +++ b/crypto/md2/build.info @@ -1,3 +1,10 @@ LIBS=../../libcrypto -SOURCE[../../libcrypto]=\ - md2_dgst.c md2_one.c + +SOURCE[../../libcrypto]=md2_dgst.c md2_one.c + +# When all deprecated symbols are removed, libcrypto doesn't export the +# MD2 functions, so we must include them directly in liblegacy.a +IF[{- $disabled{"deprecated"} + && (defined $config{"api"} && $config{"api"} >= 30000) -}] + SOURCE[../../providers/liblegacy.a]=md2_dgst.c md2_one.c +ENDIF diff --git a/crypto/md2/md2_dgst.c b/crypto/md2/md2_dgst.c index 405600fb7e..d852489102 100644 --- a/crypto/md2/md2_dgst.c +++ b/crypto/md2/md2_dgst.c @@ -7,6 +7,12 @@ * https://www.openssl.org/source/license.html */ +/* + * MD2 low level APIs are deprecated for public use, but still ok for + * internal use. + */ +#include "internal/deprecated.h" + #include <stdio.h> #include <stdlib.h> #include <string.h> diff --git a/crypto/md2/md2_one.c b/crypto/md2/md2_one.c index a600802477..9b152ef7ae 100644 --- a/crypto/md2/md2_one.c +++ b/crypto/md2/md2_one.c @@ -7,6 +7,12 @@ * https://www.openssl.org/source/license.html */ +/* + * MD2 low level APIs are deprecated for public use, but still ok for + * internal use. + */ +#include "internal/deprecated.h" + #include <stdio.h> #include "internal/cryptlib.h" #include <openssl/md2.h> |