Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8350117

Define the order of certificates returned by JarURLConnection.getCertificates()

XMLWordPrintable

    • Icon: CSR CSR
    • Resolution: Approved
    • Icon: P3 P3
    • 25
    • core-libs
    • None
    • behavioral
    • minimal
    • This is documenting long-standing implementation behavior.
    • Java API
    • SE

      Summary

      Define the order of certificates returned by java.net.JarURLConnection.getCertificates().

      Problem

      The getCertificates method of JarURLConnection has never defined the order of the returned array of certificates.

      Solution

      Specify the order in the method description. It is the same order as specified by JarEntry.getCertificates(), which it calls to get the array of certificates associated with the jar entry.

      Specification

      Add the following text to JarURLConnection.getCertificates():

       * <p>The returned certificate array comprises all the signer certificates
       * that were used to verify this entry. Each signer certificate is
       * followed by its supporting certificate chain (which may be empty).
       * Each signer certificate and its supporting certificate chain are ordered
       * bottom-to-top (i.e., with the signer certificate first and the (root)
       * certificate authority last).

      (This is the same text as in JarEntry.getCertificates())

            mullan Sean Mullan
            mullan Sean Mullan
            Jaikiran Pai, Lance Andersen
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: