[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

AW: [iaik-jce] How can I import a certificate from IE


do not call X509Certificate(fis) twice on the input stream reading a file
that only contains one single certificate.

Dieter Bratko

-----Ursprüngliche Nachricht-----
Von: iaik-jce-owner@iaik.tu-graz.ac.at
[mailto:iaik-jce-owner@iaik.tu-graz.ac.at]Im Auftrag von Ricky Wong
Gesendet: Donnerstag, 8. Februar 2001 09:07
An: 'iaik-jce@iaik.tu-graz.ac.at'
Betreff: [iaik-jce] How can I import a certificate from IE

I've generate a certificate with W2k's Certificate Server and it is
installed in the IE browser keystore. I then export the certificate with DER
format and attempt to read the certificate with the following code :

	InputStream fis = new FileInputStream("test.cer");
	recipientCertificate = new X509Certificate(fis);
	encryptionCertOfSigner = new X509Certificate(fis);

When I run the program, I got the error
"java.security.cert.CertificateException: Cannot parse an ASN1 object from a
null object.". What's wrong ? Can I do something like this ?


Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.230 / Virus Database: 111 - Release Date: 1/25/2001

Mailinglist-archive at

To unsubscribe send an email to listserv@iaik.at with the folowing content: