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

DerOutputStream.putUTCTime doesn't work for year == 2000

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P3 P3
    • 1.1.6
    • 1.1, 1.1.5
    • security-libs
    • None
    • 1.1.6
    • generic, sparc
    • generic, solaris_2.6
    • Verified

        --> See the stack trace below. The issue is that it won't write dates in
        --> the year 2000 ... all other years in the range [1980-2079] work fine.


        --> p.s. The diagnostic is from a slightly hacked CertAndKeyGen, which
        --> dumps the IOException rather than swallowing it.



        --> Generating 768 bit DSA keys for DSA self-signed certificate
        --> validity: Tue Jan 06 10:29:01 PST 1998 to Sat Jun 24 11:29:01 PDT 2000
        --> java.io.IOException: putUTCTime(), year >= 2080
        --> at
        sun.security.util.DerOutputStream.putUTCTime(DerOutputStream.java:277)
        --> at sun.security.x509.X509Cert.encode(X509Cert.java:854)
        --> at sun.security.x509.X509Cert.DERencode(X509Cert.java:826)
        --> at sun.security.x509.X509Cert.encodeAndSign(X509Cert.java:424)
        --> at sun.security.x509.CertAndKeyGen.getSelfCert(CertAndKeyGen.java:188)
        --> at sun.security.CertStore.doSelfCert(CertStore.java:600)
        --> at sun.security.CertStore.doCommands(CertStore.java:526)
        --> at sun.security.CertStore.main(CertStore.java:298)
        --> at sun.security.Login.main(Login.java:413)
        --> [Certificate Exception: There was an error when constructing the
        certificate.
        --> ( getSelfCert)]
        --> at sun.security.x509.CertAndKeyGen.getSelfCert(CertAndKeyGen.java:196)
        --> at sun.security.CertStore.doSelfCert(CertStore.java:600)
        --> at sun.security.CertStore.doCommands(CertStore.java:526)
        --> at sun.security.CertStore.main(CertStore.java:298)
        --> at sun.security.Login.main(Login.java:413)

              jlueheorcl Jan Luehe (Inactive)
              dbrownelsunw David Brownell (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: