changeset 13805:44837c0ed1b1

8133489: Better messaging for PKIX path validation matching Reviewed-by: xuelei, phh, andrew
author coffeys
date Fri, 21 Jun 2019 08:07:18 +0000
parents fc153ac3c223
children 0ce61f5487f8
files src/share/classes/java/security/cert/X509CertSelector.java test/java/security/cert/CertPathBuilder/selfIssued/KeyUsageMatters.java
diffstat 2 files changed, 9 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/classes/java/security/cert/X509CertSelector.java	Wed Apr 13 16:05:31 2016 -0700
+++ b/src/share/classes/java/security/cert/X509CertSelector.java	Fri Jun 21 08:07:18 2019 +0000
@@ -2115,8 +2115,11 @@
             if (certSubjectKeyID == null ||
                     !Arrays.equals(subjectKeyID, certSubjectKeyID)) {
                 if (debug != null) {
-                    debug.println("X509CertSelector.match: "
-                        + "subject key IDs don't match");
+                    debug.println("X509CertSelector.match: subject key IDs " +
+                        "don't match\nX509CertSelector.match: subjectKeyID: " +
+                        Arrays.toString(subjectKeyID) +
+                        "\nX509CertSelector.match: certSubjectKeyID: " +
+                        Arrays.toString(certSubjectKeyID));
                 }
                 return false;
             }
--- a/test/java/security/cert/CertPathBuilder/selfIssued/KeyUsageMatters.java	Wed Apr 13 16:05:31 2016 -0700
+++ b/test/java/security/cert/CertPathBuilder/selfIssued/KeyUsageMatters.java	Fri Jun 21 08:07:18 2019 +0000
@@ -29,12 +29,12 @@
 
 /**
  * @test
- * @bug 6852744
+ * @bug 6852744 8133489
  * @summary PIT b61: PKI test suite fails because self signed certificates
  *          are being rejected
- * @run main/othervm KeyUsageMatters subca
- * @run main/othervm KeyUsageMatters subci
- * @run main/othervm KeyUsageMatters alice
+ * @run main/othervm -Djava.security.debug=certpath KeyUsageMatters subca
+ * @run main/othervm -Djava.security.debug=certpath KeyUsageMatters subci
+ * @run main/othervm -Djava.security.debug=certpath KeyUsageMatters alice
  * @author Xuelei Fan
  */