Browse Source

Avoid putting ripemd_prov.c in libcommon otherwise it is regarded as fips source

Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: Tim Hudson <tjh@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/19375)
Tomas Mraz 1 year ago
parent
commit
155a82d1fe
2 changed files with 9 additions and 5 deletions
  1. 4 4
      crypto/ripemd/build.info
  2. 5 1
      providers/implementations/digests/build.info

+ 4 - 4
crypto/ripemd/build.info

@@ -19,10 +19,10 @@ 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 libcommon.a
-IF[{- $disabled{'deprecated-3.0'} -}]
-  SOURCE[../../providers/libcommon.a]=rmd_dgst.c rmd_one.c $RMD160ASM
-  DEFINE[../../providers/libcommon.a]=$RMD160DEF
+# RIPEMD160 functions, so we must include them directly in liblegacy.a
+IF[{- $disabled{'deprecated-3.0'} && !$disabled{'module'} -}]
+  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

+ 5 - 1
providers/implementations/digests/build.info

@@ -15,7 +15,11 @@ $MD2_GOAL=../../liblegacy.a
 $MD4_GOAL=../../liblegacy.a
 $MDC2_GOAL=../../liblegacy.a
 $WHIRLPOOL_GOAL=../../liblegacy.a
-$RIPEMD_GOAL=$COMMON_GOAL
+IF[{- !$disabled{module} -}]
+  $RIPEMD_GOAL=../../libdefault.a ../../liblegacy.a
+ELSE
+  $RIPEMD_GOAL=../../libdefault.a
+ENDIF
 
 # This source is common for all digests in all our providers.
 SOURCE[$COMMON_GOAL]=digestcommon.c