[PATCH] Don't provide implementation of DES/RC4 if CONFIG_FIPS

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Don't provide implementation of DES/RC4 if CONFIG_FIPS

Signed-off-by: Norman Hamer <nhamer@xxxxxxxxxxxx>
---
 src/crypto/crypto_openssl.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/src/crypto/crypto_openssl.c b/src/crypto/crypto_openssl.c
index 700638761..fc85c2c90 100644
--- a/src/crypto/crypto_openssl.c
+++ b/src/crypto/crypto_openssl.c
@@ -321,6 +321,7 @@ int md4_vector(size_t num_elem, const u8 *addr[], const size_t *len, u8 *mac)
 #endif /* CONFIG_FIPS */
 
 
+#ifndef CONFIG_FIPS
 int des_encrypt(const u8 *clear, const u8 *key, u8 *cypher)
 {
 	u8 pkey[8], next, tmp;
@@ -352,8 +353,10 @@ int des_encrypt(const u8 *clear, const u8 *key, u8 *cypher)
 		EVP_CIPHER_CTX_free(ctx);
 	return ret;
 }
+#endif /* CONFIG_FIPS */
 
 
+#ifndef CONFIG_FIPS
 #ifndef CONFIG_NO_RC4
 int rc4_skip(const u8 *key, size_t keylen, size_t skip,
 	     u8 *data, size_t data_len)
@@ -395,7 +398,7 @@ out:
 #endif /* OPENSSL_NO_RC4 */
 }
 #endif /* CONFIG_NO_RC4 */
-
+#endif /* CONFIG_FIPS */
 
 #ifndef CONFIG_FIPS
 int md5_vector(size_t num_elem, const u8 *addr[], const size_t *len, u8 *mac)
-- 
2.28.0.windows.1


_______________________________________________
Hostap mailing list
Hostap@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/hostap



[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux