2 releases
0.1.1 | Oct 7, 2020 |
---|---|
0.1.0 | Oct 7, 2020 |
#1468 in Algorithms
5KB
63 lines
The Hutton Cipher
The Hutton Cipher of Eric Bond Hutton, implemented in Rust (as a crate).
Usage Example
extern crate hutton_rust;
use hutton_rust::encrypt;
fn main() {
// the following 3 values must all consist of lowercase letters in the range [a-z]
// else, panicc!
let input = String::from("helloworld");
let password = String::from("foo");
let key = String::from("bar");
// the last boolean argument is whether to decrypt instead of encrypt
let output = encrypt(&input, &password, &key, false);
println!("{}", output); // => pwckfenttc
}