Java library for encoding and decoding using cfmx_compat algorithm.
Algorithm is taken from railo source.
<dependency>
<groupId>pl.wojtun</groupId>
<artifactId>cfmxcompat</artifactId>
<version>0.0.1</version>
</dependency>
Usage:
String key = "secretkey"
String plain = "plain text value"
encrypted = CFMXCompat.encrypt(plain, key)
decrypted = CFMXCompat.decrypt(encrypted, key)
encrypted = CFMXCompat.encrypt(plain, key, "uu")
decrypted = CFMXCompat.decrypt(encrypted, key, "uu")
encrypted = CFMXCompat.encrypt(plain, key, "hex")
decrypted = CFMXCompat.decrypt(encrypted, key, "hex")
encrypted = CFMXCompat.encrypt(plain, key, "base64")
decrypted = CFMXCompat.decrypt(encrypted, key, "base64")