Mihail Daskalov wrote: > I tracked the problem to jss3.dll library: > it searches for > libplc4.dll, libplsd4.dll, libnspr4.dll but according to > http://www.mozilla.org/projects/security/pki/jss/using_jss.html, on > Windows platform the dlls' names should be > plc4.dll, plsd4.dll, nspr4.dll - without lib prefix.
The documentation is wrong here. We do a few different Windows builds here: WIN954.0, WINNT4.0, and WINNT5.0. The NSPR WIN954.0 build does not prepend a "lib" to the library name, hence "nspr4.dll". The WINNT4.0 and WINNT5.0 builds DO prepend a lib, hence "libnspr4.dll". It sounds like your Mozilla installation is using a WIN954.0 build. Your best bet is to download the WIN954.0 version of JSS. Don't worry about using something with "WIN95" in the name. The only difference between the WIN95 and WINNT build is that the WIN95 build does not use NT fibers. Renaming the files should work in theory, but that leads us to your next problem... > I tried a workaround (stupid one) - I copied plc4.dll, plsd4.dll, nspr4.dll > as respectively libplc4.dll, libplsd4.dll, libnspr4.dll . > The I run the programs again, and I got the following results: > > ------------------------------------------------------------- > E:\PROGRA~1\mozilla.org\Mozilla>java.exe -classpath > L:\work\try_jss1\classes;L:\work\try_jss1\lib\jss311.jar pkcs12 > E:\MOZILLA_PROFILE\mdaskalo\4tyxtrqm.slt e: > \temp\testcerts.p12 e:\temp\b.p12 > Decoded PFX > Version: 3 > AuthSafes has 2 SafeContents > Enter password: > ******* > Enter new password: > **************** > > An unexpected exception has been detected in native code outside the VM. > Unexpected Signal : EXCEPTION_ACCESS_VIOLATION occurred at PC=0x67afda4b > Function name=set_sbh_threshold > Library=E:\WINNT\system32\MSVCRT.dll > > Current Java thread: > at org.mozilla.jss.util.Password.readPasswordFromConsole(Native > Method) > at pkcs12.main(pkcs12.java:108) This sounds like bug 112330: "CryptoToken.changePassword(new ConsolePasswordCallback(), new ConsolePasswordCallback()) throws Native Exception" (http://bugzilla.mozilla.org/show_bug.cgi?id=112330). It is fixed in JSS 3.2. That should be available in about a week.
