Author: markt
Date: Tue Mar 20 12:05:23 2018
New Revision: 1827299
URL: http://svn.apache.org/viewvc?rev=1827299&view=rev
Log:
Fix test failure when OpenSSL version that supports TLS 1.3 is used.
Modified:
tomcat/trunk/test/org/apache/tomcat/util/net/openssl/TestOpenSSLConf.java
Modified:
tomcat/trunk/test/org/apache/tomcat/util/net/openssl/TestOpenSSLConf.java
URL:
http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/tomcat/util/net/openssl/TestOpenSSLConf.java?rev=1827299&r1=1827298&r2=1827299&view=diff
==============================================================================
--- tomcat/trunk/test/org/apache/tomcat/util/net/openssl/TestOpenSSLConf.java
(original)
+++ tomcat/trunk/test/org/apache/tomcat/util/net/openssl/TestOpenSSLConf.java
Tue Mar 20 12:05:23 2018
@@ -37,7 +37,7 @@ public class TestOpenSSLConf extends Tom
private static final String ENABLED_CIPHER = "AES256-SHA256";
private static final String[] EXPECTED_CIPHERS = {"AES256-SHA256"};
private static final String[] ENABLED_PROTOCOLS = {"TLSv1.1"};
- private static final String[] DISABLED_PROTOCOLS = {"SSLv3", "TLSv1",
"TLSv1.2"};
+ private static final String[] DISABLED_PROTOCOLS = {"SSLv3", "TLSv1",
"TLSv1.2", "TLSv1.3"};
public SSLHostConfig initOpenSSLConfCmdCipher(String... commands) throws
Exception {
Assert.assertNotNull(commands);
@@ -78,7 +78,9 @@ public class TestOpenSSLConf extends Tom
@Test
public void testOpenSSLConfCmdCipher() throws Exception {
- SSLHostConfig sslHostConfig = initOpenSSLConfCmdCipher("CipherString",
ENABLED_CIPHER);
+ // Ensure TLSv1.3 ciphers aren't returned
+ SSLHostConfig sslHostConfig = initOpenSSLConfCmdCipher("CipherString",
ENABLED_CIPHER,
+ "MaxProtocol", "TLSv1.2");
String[] ciphers = sslHostConfig.getEnabledCiphers();
Assert.assertThat("Wrong HostConfig ciphers", ciphers,
CoreMatchers.is(EXPECTED_CIPHERS));
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]