Java library for encoding and decoding using CFMX_Compat.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
gradle/wrapper
src
.gitignore
.travis.yml
LICENSE.txt
README.md
build.gradle
gradlew
gradlew.bat
settings.gradle

README.md

CFMX_Compat

Travis branch Codecov branch Maven Central VersionEye LGPLv3

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")