Posts Tagged 'ros'

The Bouncy Castle Provider

Recently I was using a Java applet which generated a digital certificate for storage on the local file system, but which was failing, silently, at the last step.

Switching the browser’s security settings down to the lowest (i.e. least secure) level and, subsequently, starting the browser as an Administrator made no difference.

Bringing up the Java Console, I found a stack trace of exceptions with the following root:
java.lang.RuntimeException: java.lang.NoClassDefFoundError: org/bouncycastle/jce/provider/BouncyCastleProvider

This indicated that the applet depended on one or more third-party libraries which had not been deployed with the applet. The solution, here, was to download the current implementation of the Bouncy Castle Cryptography library.

I copied the four .jar files (you don’t need to download the ‘Test Classes’) into the Optional Package directory of my Java installation.

(On Windows, Java is typically installed into the Java folder/directory under Program Files, or, if you are using 32-bit Java on 64-bit Windows, in the Java folder/directory under ‘Program Files (x86)’.)

After restarting the browser again, the applet functioned as desired.


My Photos on Flickr

%d bloggers like this: