- Encryption:
local ciphertext = minicrypto.encrypt(content, key)
- Decryption:
local content = minicrypto.decrypt(content, key)
RC4 is not a secure cryptographic system see here. I'm not suggesting you use this for actual security.
I used this for a system where I wanted to further obscure data which was being transmitted over an already secure channel.
Simply download the .lua
file. I've provided the global variable minicrypto
to access the functions so I dont have to write an implemtation for the myriad of ways embedded lua contexts like to require their scripts.
This project is MIT licensed; do what you like with it within the terms of that license.