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

Re: [iaik-jce] Internal error when verifying a signature



From your classpath I see that you are using iaik_jce.jar. I donīt know if
you use an additional RSA supporting provider, and if the certificates in
your content info are RSA certificates, but if so, you should use
iaik_jce_full.jar or add rsa_rc4.jar.

However, if this will not solve the problem, you may send me your DER
encoded ContentInfo, so that I can look into the problem.

Dieter Bratko

----- Original Message -----
From: Ismael Blesa Part <iblesa@tissat.es>
To: <iaik-jce@iaik.tu-graz.ac.at>
Sent: Friday, September 03, 1999 3:09 PM
Subject: [iaik-jce] Internal error when verifying a signature


> I have a program (servlet) that works fine with
> jdk1.1+jdk11x_update.jar+iaik_jce.jar but that reports
> an internal error with jdk 1.2.1+iaik_jce.jar
> This is the source file
> IAIK.addAsProvider(true);
>
>     ASN1 asn1 = new ASN1(firm.getBytes());
>     ASN1Object asn1_object = asn1.toASN1Object();
>     // calculate the hash over the content received outside the message
>     MessageDigest md = java.security.MessageDigest.getInstance("SHA");
>     file://texto=texto+"a";
>     md.update(texto.getBytes());
>     byte[] digest = md.digest();
>     out.println("<BR> parse the ContentInfo");
>     // parse the ContentInfo
>     ContentInfo ci = new ContentInfo(asn1_object);  <-- Here comes the
> error
>     out.println("<BR> get the SignedData from the ContentInfo");
>     // get the SignedData from the ContentInfo
>     SignedData sd = (SignedData)ci.getContent();
>     out.println("<BR> set the hash");
>
> This is the error
> parse the ContentInfo iaik.utils.InternalErrorException: Error form
> ByteArrayInputStream! at
> iaik.pkcs.pkcs7.ContentInfo.(Unknown Source) at
> isum.verifySignature.comprueba(Compiled Code) at
> isum.verifySignature.comprobar(verifySignature.java:327) at
> isum.verifySignature.service(verifySignature.java:98) at
> javax.servlet.http.HttpServlet.service(Compiled Code) at
> com.livesoftware.jrun.JRun.runServlet(Compiled Code) at
> com.livesoftware.jrun.JRunGeneric.handleConnection(Compiled Code) at
> com.livesoftware.jrun.JRunGeneric.handleProxyConnection(Compiled Code)
> at
>
com.livesoftware.jrun.service.proxy.JRunProxyServiceHandler.handleRequest(Co
mpiled
> Code) at
> com.livesoftware.jrun.service.ThreadConfigHandler.run(Compiled Code)
>
> What I should do?
>
> Thanks
>
> --
> Mailinglist-archive at
http://jcewww.iaik.tu-graz.ac.at/mailarchive/iaik-jce/maillist.html
>
> To unsubscribe send an email to listserv@iaik.tu-graz.ac.at with the
folowing content: UNSUBSCRIBE iaik-jce
>
>


smime.p7s