Understand SipHash variants and specifications
masterSipHash is a family of pseudorandom functions (PRFs) optimized for short messages. The default implementation is SipHash-2-4, which uses a 128-bit key, 2 compression rounds, 4 finalization rounds, and returns a 64-bit tag.
Available Variants
| Variant | Key Size | Word Size | Tag Size | Description |
|---|---|---|---|---|
| SipHash-c-d | 128-bit | 64-bit | 64-bit | The standard version (e.g., SipHash-2-4). |
| SipHash-c-d-128 | 128-bit | 64-bit | 128-bit | Returns a 128-bit tag instead of 64-bit. |
| HalfSipHash-c-d-32 | 64-bit | 32-bit | 32-bit | Optimized for 32-bit words and 64-bit keys. |
| HalfSipHash-c-d-64 | 64-bit | 32-bit | 64-bit | Optimized for 32-bit words and 64-bit keys. |
Security Considerations
- Key Usage: SipHash is a keyed hash function. It must always be used with a secret key to remain secure. It is not a key-less hash function like BLAKE3 or SHA-3.
- PRF Security: For maximum security, it is expected that $c \ge 2$ and $d \ge 4$.
- Limits: Security is bounded by the key size (128 bits for standard SipHash) and the output tag size.