Skip to Main Content

Java Security

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

"Unable to initialize" during certificate import

843811May 18 2004 — edited May 24 2004
I'm trying to import a base64 root CA certificate, using:

CertificateFactory cf = CertificateFactory.getInstance("X.509");
X509Certificate cert = (X509Certificate)cf.generateCertificate(b);

Result:
Certificate Exception:
detailMessage= "Unable to initialize, java.io.IOException: DerInputStream.getLength(): lengthTag=127, too big."

I know this certificate is formatted OK, because if I double-click on it, Microsoft Management Console recognizes and formats it properly.

Do I need to use BASE64Decoder before generateCertificate? Doc says I don't need to.
Any other ideas?
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 21 2004
Added on May 18 2004
7 comments
4,899 views