#cipher #no-std #spritz

no-std spritz_cipher

A Rust implementation of the Spritz Cipher using https://github.com/abderraouf-adjal/ArduinoSpritzCipher as a base

1 unstable release

0.1.0 Oct 16, 2019

#86 in #cipher

MIT license

42KB
877 lines

spritz_cipher

A Rust implementation of the Spritz Cipher using https://github.com/abderraouf-adjal/ArduinoSpritzCipher as a base.

See the generated documentation for examples and usage.


lib.rs:

Spritz Cipher

spritz_cipher is a Rust implementation of the Spritz Cipher.

Spritz - a spongy RC4-like stream cipher and hash function.

Spritz is an improvement on RC4 based upon this paper

The tests and examples have Encryption, Hash and MAC implementations. It requires no dependencies when used as a library. The tests and examples use rand and libc to compare against 2 different C implementations.

Limitations

Spritz is not as robust as other ciphers. There are known theortical attacks that may or may not allow an attacker to comprise the communication. Spritz is also slower than SHA3. That said, it is better than nothing

Dependencies

~0.3–1.2MB
~25K SLoC