= DES
Data Encryption Standard parallel Rust implementation.
The only supported mode is Electronic Codebook (ECB).
image:https://img.shields.io/travis/antoyo/des-rs.svg[link="https://travis-ci.org/antoyo/des-rs"] image:https://img.shields.io/coveralls/antoyo/des-rs.svg[link="https://coveralls.io/github/antoyo/des-rs"] image:https://img.shields.io/crates/v/des.svg[link="https://crates.io/crates/des"] image:https://img.shields.io/badge/rust-documentation-blue.svg[link="https://antoyo.github.io/des-rs/des/"] image:https://img.shields.io/crates/d/des.svg[link="https://crates.io/crates/des"] image:https://img.shields.io/crates/l/des.svg[link="LICENSE"]
== Usage
To use des
, add this to your Cargo.toml
:
[dependencies]
and this to your crate root:
Here's a simple encrypt/decrypt example:
use des::{decrypt, encrypt};
let key = [0x13, 0x34, 0x57, 0x79, 0x9B, 0xBC, 0xDF, 0xF1]; let message = [0x01, 0x23, 0x45, 0x67, 0x89, 0xAB, 0xCD, 0xEF]; let cipher = encrypt(&message, &key);