]
Farah Juma commented on ELY-1458:
---------------------------------
[~mchoma] Thanks for catching this. The Authority Information Access extension's OCSP
URI must have both a scheme and a scheme-specific part (as mentioned in the GeneralName
definition in RFC 3280). However, the test was erroneously specifying just
"ocsp:uri:10.20.30.40:8080". Since the scheme was missing, IBM JDK was
considering this extension to be invalid when attempting to parse it. I've submitted
the following PR to fix the test and also ensure that we check the URI name is valid when
attempting to create a GeneralName.URIName:
SelfSignedX509CertificateAndSigningKeyTest.testSelfSignedCertificateWithStringExtensionValues
fails on IBM JDK
--------------------------------------------------------------------------------------------------------------
Key: ELY-1458
URL:
https://issues.jboss.org/browse/ELY-1458
Project: WildFly Elytron
Issue Type: Bug
Components: Certificate Authority
Affects Versions: 1.2.0.Beta10
Reporter: Martin Choma
Assignee: Farah Juma
With IBM java
{noformat}
java -version
java version "1.8.0"
Java(TM) SE Runtime Environment (build pxa6480sr4fp6-20170518_02(SR4 FP6))
IBM J9 VM (build 2.8, JRE 1.8.0 Linux amd64-64 Compressed References 20170516_348050 (JIT
enabled, AOT enabled)
J9VM - R28_20170516_1905_B348050
JIT - tr.r14.java_20170516_348050
GC - R28_20170516_1905_B348050_CMPRSS
J9CL - 20170516_348050)
JCL - 20170516_01 based on Oracle jdk8u131-b11
{noformat}
run test
{noformat}
mvn test -Dtest=SelfSignedX509CertificateAndSigningKeyTest
[INFO] Running org.wildfly.security.x500.cert.SelfSignedX509CertificateAndSigningKeyTest
[ERROR] Tests run: 9, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 2.372 s
<<< FAILURE! - in
org.wildfly.security.x500.cert.SelfSignedX509CertificateAndSigningKeyTest
[ERROR]
testSelfSignedCertificateWithStringExtensionValues(org.wildfly.security.x500.cert.SelfSignedX509CertificateAndSigningKeyTest)
Time elapsed: 0.274 s <<< FAILURE!
java.lang.AssertionError
at
org.wildfly.security.x500.cert.SelfSignedX509CertificateAndSigningKeyTest.testSelfSignedCertificateWithStringExtensionValues(SelfSignedX509CertificateAndSigningKeyTest.java:197)
{noformat}
This is test line failing
{code:java|title=SelfSignedX509CertificateAndSigningKeyTest.java}
byte[] authorityInfoAccessExtension =
certificate.getExtensionValue(X500.OID_PE_AUTHORITY_INFO_ACCESS);
assertNotNull(authorityInfoAccessExtension);
{code}