[jdk8u-dev] RFR: 8341946: [8u] sun/security/pkcs11/ec/ tests fail on RHEL9

Taizo Kurashige duke at openjdk.org
Fri Oct 11 09:00:51 UTC 2024


The following tests fail when they cannot find the NSS version information, because the initial value of nss_ecc_status is ECCState.Extended and tries to use the EC algorithm not supported in ECCState.Basic,

sun/security/pkcs11/ec/TestECDH.java
sun/security/pkcs11/ec/TestECDSA.java
sun/security/pkcs11/ec/TestECGenSpec.java

To resolve these failures, change the initial value of nss_ecc_status from ECCState.Extended to ECCState.Basic.

Similar fix was made in [JDK-8253637](https://bugs.openjdk.org/browse/JDK-8253637) for jdk16 and later, and [JDK-8328889](https://bugs.openjdk.org/browse/JDK-8328889) for jdk11.

JDK-8253637 and JDK-8313206 were done with versions higher than jdk8. For this reason, it is normal to do a backport, but do not backport to jdk11 or jdk8 because:

JDK-8253637
About jdk11
・The ECDHKeyAgreement.java diff contains enhancements that have not been applied to jdk11 and cannot be backported to jdk11.
・Since TestEC.java is now passed in jdk11 and has been removed from the ProblemList, there is no need to modify Problemlist.txt and TestEC.java.
・The fix for PKCS11Test.java has already been made in JDK-8313206.
About jdk8
・For the same reason as jdk11, the ECDHKeyAgreement.java diff is not applicable, and the TestEC.java and Problemlist.txt diffs need not be applied.
・All we need is a PKCS11Test.java fix to resolve 3 failures (TestECDH.java, TestECDSA.java and TestECGenSpec.java). It is appropriate to issue a new bug ID this time because the test to be solved is different from JDK-8253637.

JDK-8313206
In JDK-8313206, only jdk11 has the fix to the initial value of nss_ecc_status in PKCS11Test.java.
Since JDK-8313206 is a different topic than the one I want to solve this time, I think it is inappropriate to backport to solve 3 failures(TestECDH.java, TestECDSA.java and TestECGenSpec.java).

Thanks

-------------

Commit messages:
 - Modify copyright year
 - Change the initial value of nss_ecc_status

Changes: https://git.openjdk.org/jdk8u-dev/pull/594/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk8u-dev&pr=594&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8341946
  Stats: 2 lines in 1 file changed: 0 ins; 0 del; 2 mod
  Patch: https://git.openjdk.org/jdk8u-dev/pull/594.diff
  Fetch: git fetch https://git.openjdk.org/jdk8u-dev.git pull/594/head:pull/594

PR: https://git.openjdk.org/jdk8u-dev/pull/594


More information about the jdk8u-dev mailing list