9 releases
0.8.2 | Mar 27, 2020 |
---|---|
0.8.1 | Feb 9, 2020 |
0.7.0 | Feb 6, 2020 |
0.6.4 | Feb 3, 2020 |
#14 in #caesar
10KB
140 lines
csr
This is a library that provides encryption and decryption for the caesar cipher.
WARNING: OBVIOUSLY NOT CRYPTOGRAPHICALLY SECURE
Usage
use csr::Caesar;
fn main() {
// the key or "shift"
let key: u8 = 2;
let caesar = Caesar::new(2);
let input = "Hello world!";
assert_eq!(caesar.encrypt(input), "Jgnnq yqtnf!");
}
Dependencies
~475KB