#crypto #hash #siphash

siphasher

SipHash functions from rust-core < 1.13

9 releases

0.3.0 Dec 20, 2018
0.2.3 Jul 30, 2018
0.2.2 Mar 23, 2017
0.2.1 Jan 24, 2017
0.1.2 Oct 26, 2016

#1 in Cryptography

Download history 26526/week @ 2018-10-17 31778/week @ 2018-10-24 30023/week @ 2018-10-31 31837/week @ 2018-11-07 30759/week @ 2018-11-14 27207/week @ 2018-11-21 30280/week @ 2018-11-28 33698/week @ 2018-12-05 34142/week @ 2018-12-12 25786/week @ 2018-12-19 23372/week @ 2018-12-26 30415/week @ 2019-01-02 32656/week @ 2019-01-09 33041/week @ 2019-01-16 33505/week @ 2019-01-23

125,880 downloads per month
Used in 1,373 crates (29 directly)

MIT/Apache

43KB
1K SLoC

SipHash implementation for Rust

SipHash was recently removed from rust-core.

This crate brings SipHasher, SipHasher13 and SipHash24 back. It is based on the original implementation from rust-core and exposes the same API.

In addition, it can return 128-bit tags.

The sip module implements the standard 64-bit mode, whereas the sip128 module implements the 128-bit mode.

Usage

In Cargo.toml:

[dependencies]
siphasher = "0.3"

64-bit mode:

extern crate siphasher;

use siphasher::sip::{SipHasher, SipHasher13, SipHasher24};

128-bit mode:

use siphasher::sip128::{Hasher128, Siphasher, SipHasher13, SipHasher24};

API documentation

No runtime deps