Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / Security / June 2006

Tip: Looking for answers? Try searching our database.

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

Thread view: 
Tim Ward - 02 Jun 2006 10:23 GMT
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 - 02 Jun 2006 16:56 GMT
> Anyone know what this means? - "/ by zero" is not the world's most helpful
> error message:
[quoted text clipped - 4 lines]
> :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


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.