An open API service indexing awesome lists of open source software.

https://github.com/cryptape/hasher


https://github.com/cryptape/hasher

Last synced: 11 months ago
JSON representation

Awesome Lists containing this project

README

          

# Hasher

Package `hasher` provides a Hasher trait.

```rs
pub trait Hasher {
const LENGTH: usize;

fn digest(&self, data: &[u8]) -> Vec;
}
```

Add this to your `Cargo.toml`:

```toml
[dependencies]
hasher = "0.1"
```

# Supported algorithms

- blake2b
- keccak
- sm3

# Test

```
$ cargo test --all-features
```