Shared SipHash state (v0..v3) with its round, compression, and finalization primitives.
More...
#include <siphash.h>
|
| ALWAYS_INLINE | SipHashState (uint64_t k0, uint64_t k1) noexcept |
| | Construct a SipHashState initialized with the specified key.
|
| ALWAYS_INLINE SipHashState | Copy () const noexcept |
| | Construct a copy of this state.
|
| ALWAYS_INLINE SipHashState & | Compress1 (uint64_t data) noexcept |
| | Mutably compress one block into this state, with 1 SipRound.
|
| ALWAYS_INLINE SipHashState & | Compress1Jumbo (const uint256 &data) noexcept |
| | Mutably compress one jumbo block into this state, with 1 SipRound.
|
| ALWAYS_INLINE SipHashState & | Compress2 (uint64_t data) noexcept |
| | Mutably compress one block into this state, with 2 SipRounds.
|
| ALWAYS_INLINE uint64_t | Finalize4 () noexcept |
| | Mutably finalize this state with 4 SipRounds, and return the resulting hash.
|
| ALWAYS_INLINE uint64_t | Finalize3U () noexcept |
| | Mutably finalize this state with 3 SipRounds using the unpadded finalizer, and return the resulting hash.
|
|
| ALWAYS_INLINE | SipHashState (uint64_t v0, uint64_t v1, uint64_t v2, uint64_t v3) noexcept |
| | Construct a SipHashState with the specified values as state.
|
| ALWAYS_INLINE void | SipRound () noexcept |
| | Mutably perform one SipRound on this state.
|
|
| static constexpr uint64_t | C0 {0x736f6d6570736575} |
| | SipHash initialization constants.
|
| static constexpr uint64_t | C1 {0x646f72616e646f6d} |
| static constexpr uint64_t | C2 {0x6c7967656e657261} |
| static constexpr uint64_t | C3 {0x7465646279746573} |
| static constexpr uint64_t | FINALIZER {0xFF} |
| | SipHash v2 finalizer constant.
|
| static constexpr uint64_t | FINALIZER_UNPADDED {0x6465646461706e75} |
| | SipHash custom unpadded finalizer constant.
|
Shared SipHash state (v0..v3) with its round, compression, and finalization primitives.
Internal building block, only meant to be composed by the hasher classes below.
Definition at line 17 of file siphash.h.
◆ SipHashState() [1/2]
| ALWAYS_INLINE SipHashState::SipHashState |
( |
uint64_t | v0, |
|
|
uint64_t | v1, |
|
|
uint64_t | v2, |
|
|
uint64_t | v3 ) |
|
inlineprivatenoexcept |
◆ SipHashState() [2/2]
| ALWAYS_INLINE SipHashState::SipHashState |
( |
uint64_t | k0, |
|
|
uint64_t | k1 ) |
|
inlineexplicitnoexcept |
◆ Compress1()
| ALWAYS_INLINE SipHashState & SipHashState::Compress1 |
( |
uint64_t | data | ) |
|
|
inlinenoexcept |
Mutably compress one block into this state, with 1 SipRound.
Definition at line 50 of file siphash.h.
◆ Compress1Jumbo()
Mutably compress one jumbo block into this state, with 1 SipRound.
Definition at line 58 of file siphash.h.
◆ Compress2()
| ALWAYS_INLINE SipHashState & SipHashState::Compress2 |
( |
uint64_t | data | ) |
|
|
inlinenoexcept |
Mutably compress one block into this state, with 2 SipRounds.
Definition at line 67 of file siphash.h.
◆ Copy()
Construct a copy of this state.
Definition at line 48 of file siphash.h.
◆ Finalize3U()
| ALWAYS_INLINE uint64_t SipHashState::Finalize3U |
( |
| ) |
|
|
inlinenoexcept |
Mutably finalize this state with 3 SipRounds using the unpadded finalizer, and return the resulting hash.
Definition at line 87 of file siphash.h.
◆ Finalize4()
| ALWAYS_INLINE uint64_t SipHashState::Finalize4 |
( |
| ) |
|
|
inlinenoexcept |
Mutably finalize this state with 4 SipRounds, and return the resulting hash.
Definition at line 76 of file siphash.h.
◆ SipRound()
| ALWAYS_INLINE void SipHashState::SipRound |
( |
| ) |
|
|
inlineprivatenoexcept |
Mutably perform one SipRound on this state.
Definition at line 34 of file siphash.h.
◆ C0
| uint64_t SipHashState::C0 {0x736f6d6570736575} |
|
staticconstexprprivate |
SipHash initialization constants.
Definition at line 20 of file siphash.h.
◆ C1
| uint64_t SipHashState::C1 {0x646f72616e646f6d} |
|
staticprivate |
◆ C2
| uint64_t SipHashState::C2 {0x6c7967656e657261} |
|
staticprivate |
◆ C3
| uint64_t SipHashState::C3 {0x7465646279746573} |
|
staticprivate |
◆ FINALIZER
| uint64_t SipHashState::FINALIZER {0xFF} |
|
staticconstexprprivate |
SipHash v2 finalizer constant.
Definition at line 22 of file siphash.h.
◆ FINALIZER_UNPADDED
| uint64_t SipHashState::FINALIZER_UNPADDED {0x6465646461706e75} |
|
staticconstexprprivate |
SipHash custom unpadded finalizer constant.
Definition at line 24 of file siphash.h.
◆ m_v0
| uint64_t SipHashState::m_v0 |
|
private |
◆ m_v1
| uint64_t SipHashState::m_v1 |
|
private |
◆ m_v2
| uint64_t SipHashState::m_v2 |
|
private |
◆ m_v3
| uint64_t SipHashState::m_v3 |
|
private |
The documentation for this class was generated from the following file: