Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

java.security.UnrecoverableKeyException: Get Key failed: / by zero

518 views
Skip to first unread message

Tim Ward

unread,
Jun 2, 2006, 5:23:51 AM6/2/06
to
Anyone know what this means? - "/ by zero" is not the world's most helpful
error message:

java.security.UnrecoverableKeyException: Get Key failed: / by zero
at
com.sun.net.ssl.internal.ssl.PKCS12KeyStore.engineGetKey(PKCS12KeyStore.java
:268)
at java.security.KeyStore.getKey(KeyStore.java:731)
at
com.sun.net.ssl.internal.ssl.SunX509KeyManagerImpl.<init>(SunX509KeyManagerI
mpl.java:111)
at
com.sun.net.ssl.internal.ssl.KeyManagerFactoryImpl$SunX509.engineInit(KeyMan
agerFactoryImpl.java:41)
at javax.net.ssl.KeyManagerFactory.init(KeyManagerFactory.java:192)
at ... (my stuff)
Caused by: java.lang.ArithmeticException: / by zero
at com.sun.crypto.provider.SunJCE_ab.a(DashoA12275)
at com.sun.crypto.provider.SunJCE_ab.a(DashoA12275)
at com.sun.crypto.provider.SunJCE_ab.a(DashoA12275)
at com.sun.crypto.provider.SunJCE_ab.a(DashoA12275)
at
com.sun.crypto.provider.PKCS12PBECipherCore$PBEWithSHA1AndDESede.engineInit(
DashoA12275)
at javax.crypto.Cipher.a(DashoA12275)
at javax.crypto.Cipher.a(DashoA12275)
at javax.crypto.Cipher.init(DashoA12275)
at javax.crypto.Cipher.init(DashoA12275)
at
com.sun.net.ssl.internal.ssl.PKCS12KeyStore.engineGetKey(PKCS12KeyStore.java
:249)
... 7 more

javax.net.ssl.KeyManagerFactory.init was called like this:

kmf.init( ks, "".toCharArray() );

where ks is a "PKCS12" KeyStore loaded from a .p12 file (which is correctly
interpreted by other (non-Java) tools, so I'm not looking at an invalid .p12
file as the first thing to suspect).

--
Tim Ward
Brett Ward Limited - www.brettward.co.uk


Oliver Wong

unread,
Jun 2, 2006, 11:56:39 AM6/2/06
to

"Tim Ward" <t...@ipaccess.com> wrote in message
news:4eaed7F...@individual.net...

> Anyone know what this means? - "/ by zero" is not the world's most helpful
> error message:
>
> java.security.UnrecoverableKeyException: Get Key failed: / by zero
> at
> com.sun.net.ssl.internal.ssl.PKCS12KeyStore.engineGetKey(PKCS12KeyStore.java
> :268)
> at java.security.KeyStore.getKey(KeyStore.java:731)

If I had to make a guess, I'd say somewhere, someone tried to divide a
number by zero.

FWIW, the javadocs say:

@exception UnrecoverableKeyException if the key cannot be recovered (e.g.,
the given password is wrong).

- Oliver

0 new messages