March 20, 2004

AES for java

I've been doing a performance comparison of 3DES versus AES over the last couple of days and for the java code the best solution seems to be the Java Cryptography Extension (JCE) library from Cryptix since the Sun AES code does not seem to be available in all versions of JDK 1.4+.

Unfortunately, Cryptix has been off the air for the last couple of days (their DNS provider cryptohill.net has been unreachable). I was able to find a snapshot from last March on the Wiretapped security code mirror, but I'm reasonably certain that there ought to be something newer.

It's not really well documented, but if you decide to put their JCE libraries in the extension directory, you'll need to edit {$JAVA_HOME}/lib/security/java.security and add the provider class:

security.provider.[next-number]=cryptix.jce.provider.CryptixCrypto

Finally, although the documentation suggests that the "AES" cipher is available, you'll have to use the name "Rijndael" to access it using the March 2003 version of the Cryptix JCE libs. Having the code available made it quite a bit easier to figure that part out.

Posted by Dave at March 20, 2004 11:53 AM
Comments