Crates.io | csr |
lib.rs | csr |
version | 0.8.2 |
source | src |
created_at | 2020-02-01 04:17:04.471332 |
updated_at | 2020-03-27 06:12:09.073761 |
description | csr is a library for encrypting and decrypting many types using caesar cipher. This shouldn't be used for any serious security but was more of an exercise in generics and creating a rust crate. |
homepage | https://git.cryptid.cc/lost/csr |
repository | https://git.cryptid.cc/lost/csr |
max_upload_size | |
id | 203834 |
size | 21,056 |
This is a library that provides encryption and decryption for the caesar cipher.
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!");
}