Re: Problem opening pkcs12 files using IBM's JRE 1.5.0 on Windows

"Andi Mullaraj" <andim-pm/[email protected]>
Newsgroups gmane.org.user-groups.trijug.juglist
Message-ID <[email protected]>
Problem was in

\jdks\ibm_sdk50\lib\security\local_policy.jar
\jdks\ibm_sdk50\lib\security\US_export_policy.jar

Default ones that had come with the download bundle were restrictive. I just
replaced them with the JRE1.4 ones and everything works fine now. In the
link that Don provided they mention you can create your own policy files (my
guess is that jar signing and cacert modification will be required) - I will
give that a try and let you all know.

Thanks for you help,

Andi





-----Original Message-----
From: Don Brady [mailto:dbrady-d0/1ywxyuRNWk0Htik3J/[email protected]] 
Sent: Thursday, February 23, 2006 5:24 PM
To: Andi Mullaraj; 'juglist'
Subject: Re: [Juglist] Problem opening pkcs12 files using IBM's JRE 1.5.0 on
Windows

At 12:13 PM 2/23/2006, Andi Mullaraj wrote:
>Hi all,
>
>does anybody have an idea why this (trivial) piece of code
>
>public static void main(String[] args) throws Exception {
>     java.security.KeyStore keyStore = 
> java.security.KeyStore.getInstance("pkcs12");
>     java.io.InputStream is = new
java.io.FileInputStream("\\test2048.pfx");
>     keyStore.load(is, "test".toCharArray());
>}
>
>will throw the exception "java.io.IOException: Private key decryption 
>error: (java.security.InvalidKeyException: Illegal key size)"?
>
>**This will work fine with all Sun's JREs and also with IBM's JRE 1.4.**
>
>The key is RSA 2048 bit (attached) but the exception occurs when using 
>smaller keys as well.
>
>


Have you looked at

http://www-1.ibm.com/support/docview.wss?uid=swg21169931

You can also post the problem here and it looks as if they are answering 
Java 5 issues promptly...

http://www-128.ibm.com/developerworks/forums/dw_forum.jsp?forum=367&cat=10

Don
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.