Uploaded image for project: 'WildFly Core'
  1. WildFly Core
  2. WFCORE-5004

TlsTestCase#testReloadTrustManager fails on IBM Java 8

XMLWordPrintable

    • Hide

      Setup IBM Java 8

      cd wildfly-core/elytron
      mvn test -Dtest=TlsTestCase#testReloadTrustManager
      

      Java version

      java version "1.8.0_251"
      Java(TM) SE Runtime Environment (build 8.0.6.10 - pxa6480sr6fp10-20200408_01(SR6 FP10))
      IBM J9 VM (build 2.9, JRE 1.8.0 Linux amd64-64-Bit Compressed References 20200402_443261 (JIT enabled, AOT enabled)
      OpenJ9   - 35ef566
      OMR      - 4bca4f4
      IBM      - 55acf4a)
      JCL - 20200407_01 based on Oracle jdk8u251-b08
      
      Show
      Setup IBM Java 8 cd wildfly-core/elytron mvn test -Dtest=TlsTestCase#testReloadTrustManager Java version java version "1.8.0_251" Java(TM) SE Runtime Environment (build 8.0.6.10 - pxa6480sr6fp10-20200408_01(SR6 FP10)) IBM J9 VM (build 2.9, JRE 1.8.0 Linux amd64-64-Bit Compressed References 20200402_443261 (JIT enabled, AOT enabled) OpenJ9 - 35ef566 OMR - 4bca4f4 IBM - 55acf4a) JCL - 20200407_01 based on Oracle jdk8u251-b08

      TlsTestCase#testReloadTrustManager fails on IBM Java 8 at TlsTestCase.java#L439 reporting the same DN. When I try to compare using canonical names, there is a difference. Using RFC1779 or RFC2253 names is ok.

      Assert.assertEquals(originalFoundDN.getIssuerX500Principal().getName(X500Principal.CANONICAL), ISSUER_DN.getName(X500Principal.CANONICAL));
      
      [ERROR]   TlsTestCase.testReloadTrustManager:439 expected:<....2.840.113549.1.9.1=[#1613656c7974726f6e4077696c64666c792e6f7267],c=uk,st=elytron,cn=...> but was:<....2.840.113549.1.9.1=[elytron@wildfly.org],c=uk,st=elytron,cn=...>
      

      Is it just a test issue, or can there be an impact on functionality? In case it's just a test issue, can we assert equality of names? I.e.

      Assert.assertEquals(originalFoundDN.getIssuerX500Principal().getName(), ISSUER_DN.getName());
      

      The same for TlsTestCase.java#L465 then.

              rh-ee-szaldana Sonia Zaldana Calles
              okotek@redhat.com Ondrej Kotek
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: