如何禁用少于 2048 位的 SSL/TLS Diffie-Hellman 密钥

如何禁用少于 2048 位的 SSL/TLS Diffie-Hellman 密钥

我想禁用密钥短于 2048 位的 Diffie-Hellman 密钥交换,因为我收到了弱 SSL/TLS 密钥交换漏洞警报。

作为解决方案,该工具本身告诉我以下内容:

Change the SSL/TLS server configuration to only allow strong key exchanges. Key exchanges used on the server should provide at least 112 bits of security, so the minimum key size to not flag this QID should be:  
2048 bit key size for Diffie Hellman (DH) or RSA key exchanges  
224 bit key size for Elliptic Curve Diffie Hellman (EDCH) key exchanges.

据我所知,修改 java.security 文件中的以下行可以修复该错误

jdk.tls.disabledAlgorithms=SSLv3、TLSv1、TLSv1.1、RC4、DES、MD5withRSA、
DH keySize < 1024、EC keySize < 224、3DES_EDE_CBC、anon、NULL,
包括 jdk.disabled.namedCurves

jdk.tls.disabledAlgorithms=SSLv3、TLSv1、TLSv1.1、RC4、DES、MD5withRSA、
DH keySize < 2048、EC keySize < 224、3DES_EDE_CBC、anon、NULL,
包括 jdk.disabled.namedCurves

我是否应该进行其他修改,因为我在一些论坛上看到修改该行仍然会导致漏洞出现?

答案1

Linux 中的加密/加密设置是特定于应用程序的,实际上没有一个系统范围的设置允许您调整所有应用程序、服务器和服务的加密设置。

RHELupdate-crypto-policies命令最接近,但使用默认策略,例如,update-crypto-policies --set FUTURE它不提供调整单个设置的粒度,而无需创建自己的设置,并且您的应用程序甚至可能没有加密策略。

相关内容