Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FIPS sun/reflect/ReflectionFactory/ReflectionFactoryTest.java - RuntimeException: could not find SunPKCS11-NSS-FIPS provider for FIPS mode #15656

Open
JasonFengJ9 opened this issue Aug 3, 2022 · 3 comments

Comments

@JasonFengJ9
Copy link
Member

Failure link

From an internal build(rhel8x64-fips2-1):

08:36:46  java version "17.0.4" 2022-07-19
08:36:46  IBM Semeru Runtime Certified Edition 17.0.4.0-rc1 (build 17.0.4+8)
08:36:46  Eclipse OpenJ9 VM 17.0.4.0-rc1 (build openj9-0.33.0-rc1, JRE 17 Linux amd64-64-Bit Compressed References 20220719_186 (JIT enabled, AOT enabled)
08:36:46  OpenJ9   - 8cb527940
08:36:46  OMR      - b58aa2708
08:36:46  JCL      - e5bc2863363 based on jdk-17.0.4+8)

Rerun in Grinder - Change TARGET to run only the failed test targets.

Optional info

Failure output (captured from console output)

09:06:44  ===============================================
09:06:44  Running test jdk_security3_1 ...
09:06:44  ===============================================
09:06:44  jdk_security3_1 Start Time: Fri Jul 29 06:06:43 2022 Epoch Time (ms): 1659100003669
09:06:44  "/home/jenkins/workspace/Grinder_testList_1/openjdkbinary/j2sdk-image/bin/java" -Xshareclasses:destroyAll; "/home/jenkins/workspace/Grinder_testList_1/openjdkbinary/j2sdk-image/bin/java" -Xshareclasses:groupAccess,destroyAll; echo "cache cleanup done";
09:06:44  JVMSHRC005I No shared class caches available
09:06:44  JVMSHRC005I No shared class caches available
09:06:44  cache cleanup done
09:06:44  variation: Mode650
09:06:44  JVM_OPTIONS:  -XX:-UseCompressedOops -Dsemeru.fips=true

09:07:06  TEST: com/sun/security/sasl/digest/HasInitialResponse.java

09:07:06  STDERR:
09:07:06  java.lang.NullPointerException: Cannot invoke "javax.security.sasl.SaslClient.isComplete()" because "this.base" is null
09:07:06  	at HasInitialResponse$MyDigestMD5Client.isComplete(HasInitialResponse.java:124)
09:07:06  	at HasInitialResponse.main(HasInitialResponse.java:67)
09:07:06  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:07:06  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:07:06  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:07:06  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:07:06  	at com.sun.javatest.regtest.agent.MainActionHelper$AgentVMRunnable.run(MainActionHelper.java:312)
09:07:06  	at java.base/java.lang.Thread.run(Thread.java:858)

09:07:10  TEST: javax/net/ssl/HttpsURLConnection/DummyCacheResponse.java

09:07:10  STDERR:
09:07:10  java.io.IOException: parseAlgParameters failed: PBE AlgorithmParameters not available
09:07:10  	at java.base/sun.security.pkcs12.PKCS12KeyStore.parseAlgParameters(PKCS12KeyStore.java:855)
09:07:10  	at java.base/sun.security.pkcs12.PKCS12KeyStore.engineLoad(PKCS12KeyStore.java:2113)
09:07:10  	at java.base/java.security.KeyStore.load(KeyStore.java:1473)
09:07:10  	at jdk.test.lib.net.SimpleSSLContext.init(SimpleSSLContext.java:114)
09:07:10  	at jdk.test.lib.net.SimpleSSLContext$1.run(SimpleSSLContext.java:72)
09:07:10  	at jdk.test.lib.net.SimpleSSLContext$1.run(SimpleSSLContext.java:60)
09:07:10  	at java.base/java.security.AccessController.doPrivileged(AccessController.java:748)
09:07:10  	at jdk.test.lib.net.SimpleSSLContext.<init>(SimpleSSLContext.java:60)
09:07:10  	at jdk.test.lib.net.SimpleSSLContext.<init>(SimpleSSLContext.java:54)
09:07:10  	at DummyCacheResponse.main(DummyCacheResponse.java:64)
09:07:10  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:07:10  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:07:10  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:07:10  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:07:10  	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
09:07:10  	at java.base/java.lang.Thread.run(Thread.java:858)
09:07:10  Caused by: java.security.NoSuchAlgorithmException: PBE AlgorithmParameters not available
09:07:10  	at java.base/sun.security.jca.GetInstance.getInstance(GetInstance.java:159)
09:07:10  	at java.base/java.security.Security.getImpl(Security.java:720)
09:07:10  	at java.base/java.security.AlgorithmParameters.getInstance(AlgorithmParameters.java:157)
09:07:10  	at java.base/sun.security.pkcs12.PKCS12KeyStore.parseAlgParameters(PKCS12KeyStore.java:849)
09:07:10  	... 15 more
09:07:10  

09:07:14  TEST: javax/net/ssl/sanity/CacertsExplorer.java

09:07:14  java.lang.AssertionError: no accepted issuers - cacerts file configuration problem?
09:07:14  	at CacertsExplorer.main(CacertsExplorer.java:65)
09:07:14  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:07:14  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:07:14  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:07:14  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:07:14  	at com.sun.javatest.regtest.agent.MainActionHelper$AgentVMRunnable.run(MainActionHelper.java:312)
09:07:14  	at java.base/java.lang.Thread.run(Thread.java:858)
09:07:14  

09:07:18  TEST: javax/net/ssl/SSLEngine/FinishedPresent.java

09:07:18  STDERR:
09:07:18  java.security.KeyStoreException: JKS not found
09:07:18  	at java.base/java.security.KeyStore.getInstance(KeyStore.java:871)
09:07:18  	at FinishedPresent.<init>(FinishedPresent.java:109)
09:07:18  	at FinishedPresent.main(FinishedPresent.java:98)
09:07:18  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:07:18  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:07:18  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:07:18  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:07:18  	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
09:07:18  	at java.base/java.lang.Thread.run(Thread.java:858)
09:07:18  Caused by: java.security.NoSuchAlgorithmException: JKS KeyStore not available
09:07:18  	at java.base/sun.security.jca.GetInstance.getInstance(GetInstance.java:159)
09:07:18  	at java.base/java.security.Security.getImpl(Security.java:720)
09:07:18  	at java.base/java.security.KeyStore.getInstance(KeyStore.java:868)
09:07:18  	... 8 more

09:07:19  TEST: javax/net/ssl/SSLSession/CheckSessionContext.java

09:07:19  STDERR:
09:07:19  Server ready on port 41773
09:07:19  Client connected using port 36818
09:07:19  javax.net.ssl.SSLHandshakeException: no cipher suites in common
09:07:19  	at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:131)
09:07:19  	at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:117)
09:07:19  	at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:358)
09:07:19  	at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:314)
09:07:19  	at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:305)
09:07:19  	at java.base/sun.security.ssl.ServerHello$T12ServerHelloProducer.chooseCipherSuite(ServerHello.java:471)
09:07:19  (write)client(SSLSocket[hostname=localhost, port=41773, Session(1659100039093|SSL_NULL_WITH_NULL_NULL)]): Hello
09:07:19  java.net.SocketException: Socket is closed
09:07:19  	at java.base/sun.security.ssl.SSLSocketImpl.getInputStream(SSLSocketImpl.java:888)
09:07:19  	at TLSBase.read(TLSBase.java:85)
09:07:19  	at TLSBase$Client.read(TLSBase.java:239)
09:07:19  	at TLSBase$Client.connect(TLSBase.java:230)
09:07:19  	at TLSBase$Client.<init>(TLSBase.java:217)
09:07:19  	at CheckSessionContext.main(CheckSessionContext.java:53)
09:07:19  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:07:19  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:07:19  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:07:19  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:07:19  	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
09:07:19  	at java.base/java.lang.Thread.run(Thread.java:858)
09:07:19  java.lang.Exception: Context was null
09:07:19  	at CheckSessionContext.main(CheckSessionContext.java:55)
09:07:19  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:07:19  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:07:19  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:07:19  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:07:19  	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
09:07:19  	at java.base/java.lang.Thread.run(Thread.java:858)

09:07:21  TEST: javax/net/ssl/TLSCommon/TLSWithEdDSA.java

09:07:21  STDERR:
09:07:21  java.security.KeyStoreException: Key protection algorithm not found: java.security.UnrecoverableKeyException: Encrypt Private Key failed: getPBEAlgorithmParameters failed: PBEWithHmacSHA256AndAES_256 AlgorithmParameters not available
09:07:21  	at java.base/sun.security.pkcs12.PKCS12KeyStore.setKeyEntry(PKCS12KeyStore.java:709)
09:07:21  	at java.base/sun.security.pkcs12.PKCS12KeyStore.engineSetKeyEntry(PKCS12KeyStore.java:589)
09:07:21  	at java.base/java.security.KeyStore.setKeyEntry(KeyStore.java:1167)
09:07:21  	at TLSWithEdDSA.createKeyStore(TLSWithEdDSA.java:355)
09:07:21  	at TLSWithEdDSA.testKeyManager(TLSWithEdDSA.java:601)
09:07:21  	at TLSWithEdDSA.main(TLSWithEdDSA.java:564)
09:07:21  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:07:21  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:07:21  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:07:21  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:07:21  	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
09:07:21  	at java.base/java.lang.Thread.run(Thread.java:858)
09:07:21  Caused by: java.security.UnrecoverableKeyException: Encrypt Private Key failed: getPBEAlgorithmParameters failed: PBEWithHmacSHA256AndAES_256 AlgorithmParameters not available
09:07:21  	at java.base/sun.security.pkcs12.PKCS12KeyStore.encryptPrivateKey(PKCS12KeyStore.java:957)
09:07:21  	at java.base/sun.security.pkcs12.PKCS12KeyStore.setKeyEntry(PKCS12KeyStore.java:631)
09:07:21  	... 11 more
09:07:21  Caused by: java.io.IOException: getPBEAlgorithmParameters failed: PBEWithHmacSHA256AndAES_256 AlgorithmParameters not available
09:07:21  	at java.base/sun.security.pkcs12.PKCS12KeyStore.getPBEAlgorithmParameters(PKCS12KeyStore.java:823)
09:07:21  	at java.base/sun.security.pkcs12.PKCS12KeyStore.encryptPrivateKey(PKCS12KeyStore.java:923)
09:07:21  	... 12 more
09:07:21  Caused by: java.security.NoSuchAlgorithmException: PBEWithHmacSHA256AndAES_256 AlgorithmParameters not available
09:07:21  	at java.base/sun.security.jca.GetInstance.getInstance(GetInstance.java:159)
09:07:21  	at java.base/java.security.Security.getImpl(Security.java:720)
09:07:21  	at java.base/java.security.AlgorithmParameters.getInstance(AlgorithmParameters.java:157)
09:07:21  	at java.base/sun.security.pkcs12.PKCS12KeyStore.getPBEAlgorithmParameters(PKCS12KeyStore.java:819)
09:07:21  	... 13 more

09:07:23  TEST: javax/net/ssl/TLSv13/ClientHelloKeyShares.java

09:07:23  STDERR:
09:07:23  java.lang.RuntimeException: Missing TLS 1.3 Protocol Version in supported_groups
09:07:23  	at ClientHelloKeyShares.checkClientHello(ClientHelloKeyShares.java:220)
09:07:23  	at ClientHelloKeyShares.main(ClientHelloKeyShares.java:87)
09:07:23  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:07:23  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:07:23  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:07:23  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:07:23  	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
09:07:23  	at java.base/java.lang.Thread.run(Thread.java:858)

09:07:25  TEST: javax/net/ssl/TLSv13/HRRKeyShares.java

09:07:25  STDERR:
09:07:25  java.lang.RuntimeException: Missing TLSv1.3 protocol in supported_versions
09:07:25  	at HRRKeyShares.hrrKeyShareTest(HRRKeyShares.java:312)
09:07:25  	at HRRKeyShares.main(HRRKeyShares.java:213)
09:07:25  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:07:25  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:07:25  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:07:25  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:07:25  	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
09:07:25  	at java.base/java.lang.Thread.run(Thread.java:858)

09:08:01  TEST: sun/security/ec/ed/EdDSAKeyCompatibility.java

09:08:01  java.security.NoSuchAlgorithmException: no such algorithm: Ed448 for provider SunEC
09:08:01  	at java.base/sun.security.jca.GetInstance.getService(GetInstance.java:87)
09:08:01  	at java.base/sun.security.jca.GetInstance.getInstance(GetInstance.java:206)
09:08:01  	at java.base/java.security.KeyFactory.getInstance(KeyFactory.java:225)
09:08:01  	at EdDSAKeyCompatibility.validateCert(EdDSAKeyCompatibility.java:113)
09:08:01  	at EdDSAKeyCompatibility.main(EdDSAKeyCompatibility.java:65)
09:08:01  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:08:01  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:08:01  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:08:01  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:08:01  	at com.sun.javatest.regtest.agent.MainActionHelper$AgentVMRunnable.run(MainActionHelper.java:312)
09:08:01  	at java.base/java.lang.Thread.run(Thread.java:858)
09:08:01  java.security.NoSuchAlgorithmException: no such algorithm: Ed25519 for provider SunEC
09:08:01  	at java.base/sun.security.jca.GetInstance.getService(GetInstance.java:87)
09:08:01  	at java.base/sun.security.jca.GetInstance.getInstance(GetInstance.java:206)
09:08:01  	at java.base/java.security.KeyFactory.getInstance(KeyFactory.java:225)
09:08:01  	at EdDSAKeyCompatibility.validatePrivate(EdDSAKeyCompatibility.java:79)
09:08:01  	at EdDSAKeyCompatibility.main(EdDSAKeyCompatibility.java:67)
09:08:01  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:08:01  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:08:01  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:08:01  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:08:01  	at com.sun.javatest.regtest.agent.MainActionHelper$AgentVMRunnable.run(MainActionHelper.java:312)
09:08:01  	at java.base/java.lang.Thread.run(Thread.java:858)
09:08:01  java.security.NoSuchAlgorithmException: no such algorithm: Ed448 for provider SunEC
09:08:01  	at java.base/sun.security.jca.GetInstance.getService(GetInstance.java:87)
09:08:01  	at java.base/sun.security.jca.GetInstance.getInstance(GetInstance.java:206)
09:08:01  	at java.base/java.security.KeyFactory.getInstance(KeyFactory.java:225)
09:08:01  	at EdDSAKeyCompatibility.validatePrivate(EdDSAKeyCompatibility.java:79)
09:08:01  	at EdDSAKeyCompatibility.main(EdDSAKeyCompatibility.java:68)
09:08:01  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:08:01  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:08:01  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:08:01  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:08:01  	at com.sun.javatest.regtest.agent.MainActionHelper$AgentVMRunnable.run(MainActionHelper.java:312)
09:08:01  	at java.base/java.lang.Thread.run(Thread.java:858)
09:08:01  STDERR:
09:08:01  java.lang.RuntimeException: Some test cases failed
09:08:01  	at EdDSAKeyCompatibility.main(EdDSAKeyCompatibility.java:71)
09:08:01  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:08:01  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:08:01  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:08:01  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:08:01  	at com.sun.javatest.regtest.agent.MainActionHelper$AgentVMRunnable.run(MainActionHelper.java:312)
09:08:01  	at java.base/java.lang.Thread.run(Thread.java:858)

09:08:01  TEST: sun/security/ec/ed/EdCRLSign.java

09:08:01  STDERR:
09:08:01  java.security.NoSuchAlgorithmException: no such algorithm: Ed25519 for provider SunEC
09:08:01  	at java.base/sun.security.jca.GetInstance.getService(GetInstance.java:87)
09:08:01  	at java.base/sun.security.jca.GetInstance.getInstance(GetInstance.java:206)
09:08:01  	at java.base/java.security.KeyPairGenerator.getInstance(KeyPairGenerator.java:300)
09:08:01  	at EdCRLSign.genKeyPair(EdCRLSign.java:92)
09:08:01  	at EdCRLSign.test(EdCRLSign.java:81)
09:08:01  	at EdCRLSign.main(EdCRLSign.java:54)
09:08:01  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:08:01  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:08:01  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:08:01  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:08:01  	at com.sun.javatest.regtest.agent.MainActionHelper$AgentVMRunnable.run(MainActionHelper.java:312)
09:08:01  	at java.base/java.lang.Thread.run(Thread.java:858)

09:08:01  TEST: sun/security/ec/ed/EdDSAKeySize.java

09:08:01  STDERR:
09:08:01  java.security.NoSuchAlgorithmException: no such algorithm: EDDSA for provider SunEC
09:08:01  	at java.base/sun.security.jca.GetInstance.getService(GetInstance.java:87)
09:08:01  	at java.base/sun.security.jca.GetInstance.getInstance(GetInstance.java:206)
09:08:01  	at java.base/java.security.KeyPairGenerator.getInstance(KeyPairGenerator.java:300)
09:08:01  	at EdDSAKeySize.testKeyAttributes(EdDSAKeySize.java:106)
09:08:01  	at EdDSAKeySize.main(EdDSAKeySize.java:73)
09:08:01  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:08:01  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:08:01  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:08:01  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:08:01  	at com.sun.javatest.regtest.agent.MainActionHelper$AgentVMRunnable.run(MainActionHelper.java:312)
09:08:01  	at java.base/java.lang.Thread.run(Thread.java:858)

09:08:01  TEST: sun/security/ec/ed/EdDSANegativeTest.java

09:08:01  STDERR:
09:08:01  java.lang.RuntimeException: Unknown issue with algo name: EDDSA
09:08:01  	at EdDSANegativeTest.byName(EdDSANegativeTest.java:91)
09:08:01  	at EdDSANegativeTest.main(EdDSANegativeTest.java:56)
09:08:01  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:08:01  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:08:01  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:08:01  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:08:01  	at com.sun.javatest.regtest.agent.MainActionHelper$AgentVMRunnable.run(MainActionHelper.java:312)
09:08:01  	at java.base/java.lang.Thread.run(Thread.java:858)
09:08:01  Caused by: java.security.NoSuchAlgorithmException: no such algorithm: EDDSA for provider SunEC
09:08:01  	at java.base/sun.security.jca.GetInstance.getService(GetInstance.java:87)
09:08:01  	at java.base/sun.security.jca.GetInstance.getInstance(GetInstance.java:206)
09:08:01  	at java.base/java.security.KeyPairGenerator.getInstance(KeyPairGenerator.java:300)
09:08:01  	at EdDSANegativeTest.genKeyPair(EdDSANegativeTest.java:185)
09:08:01  	at EdDSANegativeTest.byName(EdDSANegativeTest.java:68)
09:08:01  	... 7 more

09:08:01  TEST: sun/security/ec/ed/EdECKeyFormat.java

09:08:01  java.lang.RuntimeException: no service found for Ed25519
09:08:01  	at EdECKeyFormat.forEachProvider(EdECKeyFormat.java:62)
09:08:01  	at EdECKeyFormat.privKeyTest(EdECKeyFormat.java:107)
09:08:01  	at EdECKeyFormat.main(EdECKeyFormat.java:82)
09:08:01  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:08:01  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:08:01  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:08:01  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:08:01  	at com.sun.javatest.regtest.agent.MainActionHelper$AgentVMRunnable.run(MainActionHelper.java:312)
09:08:01  	at java.base/java.lang.Thread.run(Thread.java:858)

09:08:02  TEST: sun/security/pkcs11/Cipher/CancelMultipart.java

09:08:02  STDERR:
09:08:02  java.security.InvalidKeyException: Could not create key
09:08:02  	at jdk.crypto.cryptoki/sun.security.pkcs11.P11SecretKeyFactory.createKey(P11SecretKeyFactory.java:290)
09:08:02  	at jdk.crypto.cryptoki/sun.security.pkcs11.P11SecretKeyFactory.convertKey(P11SecretKeyFactory.java:191)
09:08:02  	at jdk.crypto.cryptoki/sun.security.pkcs11.P11SecretKeyFactory.convertKey(P11SecretKeyFactory.java:123)
09:08:02  	at jdk.crypto.cryptoki/sun.security.pkcs11.P11Cipher.implInit(P11Cipher.java:414)
09:08:02  	at jdk.crypto.cryptoki/sun.security.pkcs11.P11Cipher.engineInit(P11Cipher.java:312)
09:08:02  	at java.base/javax.crypto.Cipher.init(Cipher.java:1296)
09:08:02  	at java.base/javax.crypto.Cipher.init(Cipher.java:1236)
09:08:02  	at CancelMultipart$LeakDecrypt.getCipher(CancelMultipart.java:90)
09:08:02  	at CancelMultipart$SessionLeaker.leakAndTry(CancelMultipart.java:60)
09:08:02  	at CancelMultipart.executeTest(CancelMultipart.java:135)
09:08:02  	at CancelMultipart.main(CancelMultipart.java:123)
09:08:02  	at PKCS11Test.premain(PKCS11Test.java:174)
09:08:02  	at PKCS11Test.testDefault(PKCS11Test.java:261)
09:08:02  	at PKCS11Test.main(PKCS11Test.java:209)
09:08:02  	at CancelMultipart.main(CancelMultipart.java:114)
09:08:02  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:08:02  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:08:02  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:08:02  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:08:02  	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
09:08:02  	at java.base/java.lang.Thread.run(Thread.java:858)
09:08:02  Caused by: sun.security.pkcs11.wrapper.PKCS11Exception: CKR_GENERAL_ERROR
09:08:02  	at jdk.crypto.cryptoki/sun.security.pkcs11.wrapper.PKCS11$InnerPKCS11.C_CreateObject(PKCS11.java:184)
09:08:02  	at jdk.crypto.cryptoki/sun.security.pkcs11.P11SecretKeyFactory.createKey(P11SecretKeyFactory.java:285)
09:08:02  	... 20 more
09:08:02  

09:08:03  TEST: sun/security/pkcs11/Cipher/TestCipherMode.java

09:08:03  STDERR:
09:08:03  java.security.ProviderException: Initialization failed
09:08:03  	at jdk.crypto.cryptoki/sun.security.pkcs11.SunPKCS11.<init>(SunPKCS11.java:430)
09:08:03  	at jdk.crypto.cryptoki/sun.security.pkcs11.SunPKCS11$1.run(SunPKCS11.java:138)
09:08:03  	at jdk.crypto.cryptoki/sun.security.pkcs11.SunPKCS11$1.run(SunPKCS11.java:135)
09:08:03  	at java.base/java.security.AccessController.doPrivileged(AccessController.java:748)
09:08:03  	at jdk.crypto.cryptoki/sun.security.pkcs11.SunPKCS11.configure(SunPKCS11.java:135)
09:08:03  	at PKCS11Test.getSunPKCS11(PKCS11Test.java:150)
09:08:03  	at PKCS11Test.getSunPKCS11(PKCS11Test.java:142)
09:08:03  	at PKCS11Test.testNSS(PKCS11Test.java:549)
09:08:03  	at PKCS11Test.main(PKCS11Test.java:210)
09:08:03  	at TestCipherMode.main(TestCipherMode.java:92)
09:08:03  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:08:03  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:08:03  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:08:03  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:08:03  	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
09:08:03  	at java.base/java.lang.Thread.run(Thread.java:858)
09:08:03  Caused by: sun.security.pkcs11.wrapper.PKCS11Exception: CKR_SLOT_ID_INVALID
09:08:03  	at jdk.crypto.cryptoki/sun.security.pkcs11.wrapper.PKCS11.C_GetSlotInfo(Native Method)
09:08:03  	at jdk.crypto.cryptoki/sun.security.pkcs11.SunPKCS11.<init>(SunPKCS11.java:396)
09:08:03  	... 15 more

09:08:11  TEST: sun/security/pkcs11/KeyAgreement/IllegalPackageAccess.java

09:08:11  java.lang.ExceptionInInitializerError
09:08:11  	at java.base/java.lang.J9VMInternals.ensureError(J9VMInternals.java:222)
09:08:11  	at java.base/java.lang.J9VMInternals.recordInitializationFailure(J9VMInternals.java:211)
09:08:11  	at java.base/sun.security.jca.JCAUtil.getSecureRandom(JCAUtil.java:70)
09:08:11  	at jdk.crypto.cryptoki/sun.security.pkcs11.NativeKeyHolder.createNativeKeyWrapper(P11Key.java:1298)
09:08:11  	at jdk.crypto.cryptoki/sun.security.pkcs11.NativeKeyHolder.<init>(P11Key.java:1354)
09:08:11  	at jdk.crypto.cryptoki/sun.security.pkcs11.P11Key.<init>(P11Key.java:150)
09:08:11  	at jdk.crypto.cryptoki/sun.security.pkcs11.P11Key$P11PrivateKey.<init>(P11Key.java:461)
09:08:11  	at jdk.crypto.cryptoki/sun.security.pkcs11.P11Key.privateKey(P11Key.java:402)
09:08:11  	at jdk.crypto.cryptoki/sun.security.pkcs11.P11KeyPairGenerator.generateKeyPair(P11KeyPairGenerator.java:419)
09:08:11  	at java.base/java.security.KeyPairGenerator$Delegate.generateKeyPair(KeyPairGenerator.java:721)
09:08:11  	at IllegalPackageAccess.main(IllegalPackageAccess.java:85)
09:08:11  	at PKCS11Test.premain(PKCS11Test.java:174)
09:08:11  	at PKCS11Test.testDefault(PKCS11Test.java:261)
09:08:11  	at PKCS11Test.main(PKCS11Test.java:209)
09:08:11  	at IllegalPackageAccess.main(IllegalPackageAccess.java:68)
09:08:11  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
09:08:11  	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
09:08:11  	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
09:08:11  	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
09:08:11  	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
09:08:11  	at java.base/java.lang.Thread.run(Thread.java:858)
09:08:11  Caused by: java.lang.RuntimeException: could not find SunPKCS11-NSS-FIPS provider for FIPS mode
09:08:11  	at java.base/java.security.SecureRandom.getDefaultPRNG(SecureRandom.java:284)
09:08:11  	at java.base/java.security.SecureRandom.<init>(SecureRandom.java:233)
09:08:11  	at java.base/sun.security.jca.JCAUtil$CachedSecureRandomHolder.<clinit>(JCAUtil.java:58)
09:08:11  	... 19 more
09:08:11  

09:19:54  TEST RESULT: Failed. Execution failed: `main' threw exception: java.security.ProviderException: cancel failed
09:19:54  --------------------------------------------------
09:24:46  Test results: passed: 329; failed: 83
09:24:49  Report written to /home/jenkins/workspace/Grinder_testList_1/jvmtest/openjdk/report/html/report.html
09:24:49  Results written to /home/jenkins/workspace/Grinder_testList_1/aqa-tests/TKG/output_16590982696185/jdk_security3_1/work
09:24:49  Error: Some tests failed or other problems occurred.
09:24:49  
09:24:49  jdk_security3_1_FAILED

@alon-sh @taoliult

@JasonFengJ9
Copy link
Member Author

JasonFengJ9 commented Sep 9, 2022

An internal build(rhel8x64-fips1-1)

openjdk version "1.8.0_352"
IBM Semeru Runtime Open Edition (build 1.8.0_352-b05)
Eclipse OpenJ9 VM (build v0.35.0-release-7dd982ba7, JRE 1.8.0 Linux amd64-64-Bit Compressed References 20220908_469 (JIT enabled, AOT enabled)
OpenJ9   - 7dd982ba7
OMR      - 938f0686f
JCL      - d0e3108595 based on jdk8u352-b05)

[2022-09-09T01:29:50.750Z] variation: -Xdump:system:none -Xdump:heap:none -Xdump:system:events=gpf+abort+traceassert+corruptcache -XX:-JITServerTechPreviewMessage Mode150
[2022-09-09T01:29:50.750Z] JVM_OPTIONS:  -Xdump:system:none -Xdump:heap:none -Xdump:system:events=gpf+abort+traceassert+corruptcache -XX:-JITServerTechPreviewMessage -XX:+UseCompressedOops 

[2022-09-09T01:33:06.018Z] TEST: sun/reflect/ReflectionFactory/ReflectionFactoryTest.java

[2022-09-09T01:33:06.020Z] STDERR:
[2022-09-09T01:33:06.020Z] java.lang.ExceptionInInitializerError
[2022-09-09T01:33:06.021Z] 	at java.lang.J9VMInternals.ensureError(J9VMInternals.java:158)
[2022-09-09T01:33:06.021Z] 	at java.lang.J9VMInternals.recordInitializationFailure(J9VMInternals.java:147)
[2022-09-09T01:33:06.021Z] 	at java.util.UUID.randomUUID(UUID.java:142)
[2022-09-09T01:33:06.021Z] 	at org.testng.xml.XmlTest.init(XmlTest.java:82)
[2022-09-09T01:33:06.021Z] 	at org.testng.xml.XmlTest.<init>(XmlTest.java:72)
[2022-09-09T01:33:06.021Z] 	at org.testng.TestNG.createCommandLineSuitesForClasses(TestNG.java:583)
[2022-09-09T01:33:06.021Z] 	at org.testng.TestNG.initializeCommandLineSuites(TestNG.java:794)
[2022-09-09T01:33:06.021Z] 	at org.testng.TestNG.run(TestNG.java:994)
[2022-09-09T01:33:06.021Z] 	at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:94)
[2022-09-09T01:33:06.021Z] 	at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:54)
[2022-09-09T01:33:06.021Z] 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[2022-09-09T01:33:06.021Z] 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
[2022-09-09T01:33:06.021Z] 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[2022-09-09T01:33:06.021Z] 	at java.lang.reflect.Method.invoke(Method.java:498)
[2022-09-09T01:33:06.021Z] 	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
[2022-09-09T01:33:06.021Z] 	at java.lang.Thread.run(Thread.java:826)
[2022-09-09T01:33:06.021Z] Caused by: java.lang.RuntimeException: could not find SunPKCS11-NSS-FIPS provider for FIPS mode
[2022-09-09T01:33:06.021Z] 	at java.security.SecureRandom.getDefaultPRNG(SecureRandom.java:209)
[2022-09-09T01:33:06.021Z] 	at java.security.SecureRandom.<init>(SecureRandom.java:170)
[2022-09-09T01:33:06.021Z] 	at java.util.UUID$Holder.<clinit>(UUID.java:96)
[2022-09-09T01:33:06.021Z] 	... 14 more
[2022-09-09T01:33:06.021Z] 
[2022-09-09T01:33:06.021Z] JavaTest Message: Test threw exception: java.lang.ExceptionInInitializerError

[2022-09-09T01:33:06.022Z] TEST RESULT: Failed. Execution failed: `main' threw exception: java.lang.ExceptionInInitializerError
[2022-09-09T01:33:06.022Z] --------------------------------------------------
[2022-09-09T01:33:06.022Z] Test results: passed: 435; failed: 1
[2022-09-09T01:33:06.022Z] Report written to /home/jenkins/workspace/Test_openjdk8_j9_sanity.openjdk_x86-64_linux_fips_testList_0/aqa-tests/TKG/output_16626869907321/jdk_lang_0/report/html/report.html
[2022-09-09T01:33:06.022Z] Results written to /home/jenkins/workspace/Test_openjdk8_j9_sanity.openjdk_x86-64_linux_fips_testList_0/aqa-tests/TKG/output_16626869907321/jdk_lang_0/work
[2022-09-09T01:33:06.022Z] Error: Some tests failed or other problems occurred.
[2022-09-09T01:33:06.022Z] 
[2022-09-09T01:33:06.022Z] jdk_lang_0_FAILED

@JasonFengJ9 JasonFengJ9 changed the title JDK17 FIPS jdk_security3_1_FAILED FIPS jdk_security3_1_FAILED Sep 9, 2022
@JasonFengJ9 JasonFengJ9 changed the title FIPS jdk_security3_1_FAILED FIPS sun/reflect/ReflectionFactory/ReflectionFactoryTest.java - RuntimeException: could not find SunPKCS11-NSS-FIPS provider for FIPS mode Sep 9, 2022
@taoliult
Copy link
Contributor

@WilburZjh please help to take a look.

@WilburZjh
Copy link
Contributor

openjdk version "1.8.0_352"
IBM Semeru Runtime Open Edition (build 1.8.0_352-b05)
Eclipse OpenJ9 VM (build v0.35.0-release-7dd982ba7, JRE 1.8.0 Linux amd64-64-Bit Compressed References 20220908_469 (JIT enabled, AOT enabled)
OpenJ9 - 7dd982b
OMR - 938f0686f
JCL - d0e3108595 based on jdk8u352-b05)

[2022-09-09T01:29:50.750Z] variation: -Xdump:system:none -Xdump:heap:none -Xdump:system:events=gpf+abort+traceassert+corruptcache -XX:-JITServerTechPreviewMessage Mode150
[2022-09-09T01:29:50.750Z] JVM_OPTIONS: -Xdump:system:none -Xdump:heap:none -Xdump:system:events=gpf+abort+traceassert+corruptcache -XX:-JITServerTechPreviewMessage -XX:+UseCompressedOops

[2022-09-09T01:33:06.018Z] TEST: sun/reflect/ReflectionFactory/ReflectionFactoryTest.java

[2022-09-09T01:33:06.020Z] STDERR:
[2022-09-09T01:33:06.020Z] java.lang.ExceptionInInitializerError
[2022-09-09T01:33:06.021Z] at java.lang.J9VMInternals.ensureError(J9VMInternals.java:158)
[2022-09-09T01:33:06.021Z] at java.lang.J9VMInternals.recordInitializationFailure(J9VMInternals.java:147)
[2022-09-09T01:33:06.021Z] at java.util.UUID.randomUUID(UUID.java:142)
[2022-09-09T01:33:06.021Z] at org.testng.xml.XmlTest.init(XmlTest.java:82)
[2022-09-09T01:33:06.021Z] at org.testng.xml.XmlTest.(XmlTest.java:72)
[2022-09-09T01:33:06.021Z] at org.testng.TestNG.createCommandLineSuitesForClasses(TestNG.java:583)
[2022-09-09T01:33:06.021Z] at org.testng.TestNG.initializeCommandLineSuites(TestNG.java:

Link to issue 613 in jdk8.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants