Node:Installing the GNU Crypto Provider, Next:, Previous:Installing the JCE Classes, Up:JCE Support



Installing the GNU Crypto Provider

The GNU Crypto provider is implemented in the class gnu.crypto.jce.GnuCrypto, and is available by the name "GNU Crypto". You can install this provider at run-time by including in your program a statement such as:

     java.security.Security.addProvider(new gnu.crypto.jce.GnuCrypto());
     

Or by putting the following in your security properties file, usually located at ${JRE_HOME}/lib/security/${VM_NAME}.security:

     security.provider.N=gnu.crypto.jce.GnuCrypto
     

Where `N' is the appropriate preference number. Doing this, and asserting that the gnu-crypto.jar file is in your classpath, will complete the installation of the provider.