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

[iaik-jce] IAIK applet problem



Hi,

I'm having problems when I use the IAIK applet edition in an applet. I use
IAIK to extract a certificate from a pkcs#7 signature with the following
code:

ContentInfo contentInfo = new ContentInfo(inputCertStream);
if (contentInfo.getContentType().equals(ObjectID.pkcs7_signedData)) {
    SignedData signedData = (SignedData) contentInfo.getContent();
    X509Certificate[] certificates = signedData.getCertificates();
    byte[] outputCert = certificates[0].getEncoded();
}

When I execute the applet in NS 4.08 or IE 5.5 I get the following exception
when the ContentInfo(InputStream) constructor is called:

java.lang.NoSuchMethodError: iaik/asn1/structures/AlgorithmID: method
getKeyFactoryInstance()Liaik/java/security/KeyFactory; not found
	at iaik/x509/PublicKeyInfo.getPublicKey
	at iaik/x509/X509Certificate.b
	at iaik/x509/X509Certificate.decode
	at iaik/x509/X509Certificate.<init>
	at iaik/pkcs/pkcs7/SignedDataStream.notifyEOF
	at iaik/pkcs/pkcs7/SignedData.decode
	at iaik/pkcs/pkcs7/ContentInfo.decode
	at iaik/pkcs/pkcs7/ContentInfo.<init>
	at Terra2.init
	at com/ms/applet/AppletPanel.securedCall0
	at com/ms/applet/AppletPanel.securedCall
	at com/ms/applet/AppletPanel.processSentEvent
	at com/ms/applet/AppletPanel.processSentEvent
	at com/ms/applet/AppletPanel.run
	at java/lang/Thread.run

It doesn't work in the appletviewer either.

Grateful for advice.

Regards,
Marcus Hansson

marcus.hansson@prevas.se
--
Mailinglist-archive at http://jcewww.iaik.at/mailarchive/iaik-jce/jcethreads.html

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