Tool for generation of data from cryptoprimitives (block and stream ciphers, hash functions). Cryptoprimitives are round-reduced and the data can be configured for multiple testing scenarios.
Enables to configure initial state of the HW counter. Helps with generating various different sequences with low hamming weight. User can control the starting offset and thus partition the combination space precisely.
State is an integer array with the length of the current Hamming weight.
Each element encodes the position of the currently enabled bit. It forms strictly increasing sequence, with minimum index 0 and maximum index (8 * osize - 1).
Initial state for HW4 is [0, 1, 2, 3].
Example: the HW4 on osize=2 goes from state [0, 13, 14, 15] to [1, 2, 3, 4]
HW counter reformated with clang-format (also existing code to keep it compliant)
(8 * osize - 1)
.[0, 1, 2, 3]
.[0, 13, 14, 15]
to[1, 2, 3, 4]
Configuration example: