| Crates.io | hs1-siv |
| lib.rs | hs1-siv |
| version | 0.2.0-pre.0 |
| created_at | 2025-01-22 14:36:28.380013+00 |
| updated_at | 2025-01-28 12:16:19.988083+00 |
| description | Pure Rust implementation of the HS1-SIV Authenticated Encryption with Additional Data Cipher. Based on ChaCha. |
| homepage | https://github.com/Demindiro/AEADs/tree/hs1-siv-prerelease/hs1-siv |
| repository | https://github.com/Demindiro/AEADs/tree/hs1-siv-prerelease |
| max_upload_size | |
| id | 1526676 |
| size | 47,319 |
Pure Rust implementation of HS1-SIV.
HS1-SIV is based on the ChaCha stream cipher. The tag is generated using a new hashing algorithm. It also doubles as a SIV (synthetic IV), providing resistance against nonce reuse.
The algorithm is configurable:
B: Block size, as a multiple of 16.T: "collision level" (higher is more secure).R: ChaCha rounds.L: Tag length in bytes.3 standard settings are provided:
| Name | B |
T |
R |
L |
|---|---|---|---|---|
Hs1SivLo |
4 | 2 | 8 | 8 |
Hs1SivMe |
4 | 4 | 12 | 16 |
Hs1SivHi |
4 | 6 | 20 | 32 |
Security per setting is (n = amount of messages generated):
| Name | Key search | SIV collision |
|---|---|---|
Hs1SivLo |
n/(2^256) |
(n^2)/(2^56) + (n^2)/(2^64) |
Hs1SivMe |
n/(2^256) |
(n^2)/(2^112) + (n^2)/(2^128) |
Hs1SivHi |
n/(2^256) |
(n^2)/(2^168) + (n^2)/(2^256) |