8173478: SSL related tests failes with message: "java.security.NoSuchAlgorithmException: EC KeyFactory not available"
Reviewed-by: xuelei
--- a/jdk/test/javax/net/ssl/FixingJavadocs/SSLSessionNulls.java Mon Jan 30 16:33:20 2017 +0100
+++ b/jdk/test/javax/net/ssl/FixingJavadocs/SSLSessionNulls.java Mon Jan 30 13:11:56 2017 +0300
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2001, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2001, 2017, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -27,6 +27,7 @@
* @summary Need to revisit the javadocs for JSSE, especially the
* promoted classes.
* @library /javax/net/ssl/templates
+ * @modules jdk.crypto.ec
* @run main/othervm SSLSessionNulls
*
* SunJSSE does not support dynamic system properties, no way to re-use
--- a/jdk/test/javax/net/ssl/interop/ClientHelloChromeInterOp.java Mon Jan 30 16:33:20 2017 +0100
+++ b/jdk/test/javax/net/ssl/interop/ClientHelloChromeInterOp.java Mon Jan 30 13:11:56 2017 +0300
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -30,7 +30,8 @@
* @test
* @bug 8169362
* @summary Interop automated testing with Chrome
- * @modules java.base/sun.security.util
+ * @modules jdk.crypto.ec
+ * java.base/sun.security.util
* @run main/othervm ClientHelloChromeInterOp
*/
--- a/jdk/test/javax/net/ssl/templates/SSLSocketTemplate.java Mon Jan 30 16:33:20 2017 +0100
+++ b/jdk/test/javax/net/ssl/templates/SSLSocketTemplate.java Mon Jan 30 13:11:56 2017 +0300
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -29,11 +29,22 @@
/*
* @test
* @bug 8161106 8170329
+ * @modules jdk.crypto.ec
* @summary Improve SSLSocket test template
* @run main/othervm SSLSocketTemplate
*/
-import java.io.*;
-import javax.net.ssl.*;
+
+import java.io.ByteArrayInputStream;
+import java.io.InputStream;
+import java.io.IOException;
+import java.io.OutputStream;
+import javax.net.ssl.KeyManagerFactory;
+import javax.net.ssl.SSLContext;
+import javax.net.ssl.SSLServerSocket;
+import javax.net.ssl.SSLServerSocketFactory;
+import javax.net.ssl.SSLSocket;
+import javax.net.ssl.SSLSocketFactory;
+import javax.net.ssl.TrustManagerFactory;
import java.net.InetSocketAddress;
import java.net.SocketTimeoutException;
import java.security.KeyStore;
@@ -41,7 +52,7 @@
import java.security.KeyFactory;
import java.security.cert.Certificate;
import java.security.cert.CertificateFactory;
-import java.security.spec.*;
+import java.security.spec.PKCS8EncodedKeySpec;
import java.util.Base64;
import java.util.concurrent.CountDownLatch;