All Projects → RustCrypto → Stream Ciphers

RustCrypto / Stream Ciphers

Collection of stream cipher algorithms

Programming Languages

rust
11053 projects

Projects that are alternatives of or similar to Stream Ciphers

Open Crypto
🔑 Hashing (BCrypt, SHA2, HMAC), encryption (AES), public-key (RSA), and random data generation.
Stars: ✭ 115 (-9.45%)
Mutual labels:  cryptography
Chromium Gost
Chromium с поддержкой алгоритмов ГОСТ
Stars: ✭ 123 (-3.15%)
Mutual labels:  cryptography
Crylogger
CRYLOGGER: Detecting Crypto Misuses for Android and Java Apps Dynamically
Stars: ✭ 125 (-1.57%)
Mutual labels:  cryptography
Solar
🌞 Stellar wallet. Secure and user-friendly.
Stars: ✭ 117 (-7.87%)
Mutual labels:  cryptography
Pycryptodome
A self-contained cryptographic library for Python
Stars: ✭ 1,817 (+1330.71%)
Mutual labels:  cryptography
I2pd
🛡 I2P: End-to-End encrypted and anonymous Internet
Stars: ✭ 1,796 (+1314.17%)
Mutual labels:  cryptography
Foundational Knowledge For Programmers
List of resources about foundational knowledge for programmers (supposed to last a few decades)
Stars: ✭ 115 (-9.45%)
Mutual labels:  cryptography
Cryptolib4pascal
Crypto for Modern Object Pascal
Stars: ✭ 127 (+0%)
Mutual labels:  cryptography
Endesive
en-crypt, de-crypt, si-gn, ve-rify - smime, pdf, xades and plain files in pure python
Stars: ✭ 122 (-3.94%)
Mutual labels:  cryptography
Noise
A decentralized P2P networking stack written in Go.
Stars: ✭ 1,695 (+1234.65%)
Mutual labels:  cryptography
Cryptogotchas
A collection of common (interesting) cryptographic mistakes.
Stars: ✭ 118 (-7.09%)
Mutual labels:  cryptography
Distaff
Zero-knowledge virtual machine written in Rust
Stars: ✭ 119 (-6.3%)
Mutual labels:  cryptography
Vrf.js
A pure Javascript Implementation of Verifiable Random Functions
Stars: ✭ 124 (-2.36%)
Mutual labels:  cryptography
Multi Party Schnorr
Rust implementation of multi-party Schnorr signatures over elliptic curves.
Stars: ✭ 115 (-9.45%)
Mutual labels:  cryptography
Password4j
Password4j is a user-friendly cryptographic library that supports Argon2, Bcrypt, Scrypt, PBKDF2 and various cryptographic hash functions.
Stars: ✭ 124 (-2.36%)
Mutual labels:  cryptography
Charm
A really tiny crypto library.
Stars: ✭ 116 (-8.66%)
Mutual labels:  cryptography
Chest
Bash glue to encrypt and hide files
Stars: ✭ 123 (-3.15%)
Mutual labels:  cryptography
Torchbear
🔥🐻 The Speakeasy Scripting Engine Which Combines Speed, Safety, and Simplicity
Stars: ✭ 128 (+0.79%)
Mutual labels:  cryptography
Feathercoin
Stars: ✭ 126 (-0.79%)
Mutual labels:  cryptography
Noise
.NET Standard 1.3 implementation of the Noise Protocol Framework (revision 33 of the spec)
Stars: ✭ 124 (-2.36%)
Mutual labels:  cryptography

RustCrypto: stream ciphers Rust Version Project Chat dependency status HAZMAT

Collection of stream cipher algorithms written in pure Rust.

⚠️ Security Warning: Hazmat!

Crates in this repository do not ensure ciphertexts are authentic (i.e. by using a MAC to verify ciphertext integrity), which can lead to serious vulnerabilities if used incorrectly!

Aside from the chacha20 crate, no crates in this repository have yet received any formal cryptographic and security reviews/audits.

USE AT YOUR OWN RISK!

Crates

Name Crates.io Documentation Build Status
cfb-mode crates.io Documentation build
cfb8 crates.io Documentation build
chacha20 crates.io Documentation build
ctr crates.io Documentation build
hc-256 crates.io Documentation build
ofb crates.io Documentation build
rabbit crates.io Documentation build
salsa20 crates.io Documentation build

Minimum Supported Rust Version

Rust 1.41 or higher.

Minimum supported Rust version can be changed in the future, but it will be done with a minor version bump.

Usage

Crates functionality is expressed in terms of traits defined in the cipher crate.

Let's use AES-128-OFB to demonstrate usage of synchronous stream cipher:

use aes::Aes128;
use ofb::Ofb;

// import relevant traits
use ofb::cipher::{NewStreamCipher, SyncStreamCipher};

// OFB mode implementation is generic over block ciphers
// we will create a type alias for convenience
type AesOfb = Ofb<Aes128>;

let key = b"very secret key.";
let iv = b"unique init vect";
let plaintext = b"The quick brown fox jumps over the lazy dog.";

let mut buffer = plaintext.to_vec();

// create cipher instance
let mut cipher = AesOfb::new_var(key, iv)?;

// apply keystream (encrypt)
cipher.apply_keystream(&mut buffer);

// and decrypt it back
AesOfb::new_var(key, iv)?.apply_keystream(&mut buffer);

// stream ciphers can be used with streaming messages
let mut cipher = AesOfb::new_var(key, iv).unwrap();
for chunk in buffer.chunks_mut(3) {
    cipher.apply_keystream(chunk);
}

License

All crates licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].