harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Leo Li (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HARMONY-3384) [classlib][security]java.security.cert.X509Certificate.toString() throws NullPointerException
Date Fri, 16 Mar 2007 03:37:09 GMT

    [ https://issues.apache.org/jira/browse/HARMONY-3384?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12481468
] 

Leo Li commented on HARMONY-3384:
---------------------------------

Hi, Stepan:
      Another interesting thing is that the certificate cannot be verified by certificate.verify(certificate.getPublicKey()).
I am quite confused about it. Do you have any idea?


Good luck!
Leo.

> [classlib][security]java.security.cert.X509Certificate.toString() throws NullPointerException
> ---------------------------------------------------------------------------------------------
>
>                 Key: HARMONY-3384
>                 URL: https://issues.apache.org/jira/browse/HARMONY-3384
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Leo Li
>         Assigned To: Stepan Mishura
>         Attachments: cert.dat
>
>
> Here is a testcase:
>     public void testToString() throws Exception
>          {
>              ObjectInputStream oin = new ObjectInputStream(new FileInputStream("cert.dat"));
>              X509Certificate cert = (X509Certificate) oin.readObject();
>              cert.toString();
>             oin.close();
>         }
> And the serialization file cert .dat is in the attachment.
> It passes on RI, but fails on Harmony with NullPointerException:
> java.lang.NullPointerException
> 	at java.math.BigInteger.<init>(BigInteger.java:179)
> 	at org.apache.harmony.security.x509.AuthorityKeyIdentifier$1.getDecodedObject(AuthorityKeyIdentifier.java:122)
> 	at org.apache.harmony.security.asn1.ASN1Sequence.decode(ASN1Sequence.java:54)
> 	at org.apache.harmony.security.asn1.ASN1Type.decode(ASN1Type.java:98)
> 	at org.apache.harmony.security.x509.AuthorityKeyIdentifier.decode(AuthorityKeyIdentifier.java:72)
> 	at org.apache.harmony.security.x509.Extension.decodeExtensionValue(Extension.java:297)
> 	at org.apache.harmony.security.x509.Extension.dumpValue(Extension.java:333)
> 	at org.apache.harmony.security.x509.Extensions.dumpValue(Extensions.java:40)
> 	at org.apache.harmony.security.x509.TBSCertificate.dumpValue(TBSCertificate.java:290)
> 	at org.apache.harmony.security.x509.Certificate.toString(Certificate.java:118)
> 	at org.apache.harmony.security.provider.cert.X509CertImpl.toString(X509CertImpl.java:486)
> 	at X509CertificateTest.testToString(X509CertificateTest.java:15) 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message