keccak-f is a fixed-size permutation: it maps every input state to an output state of the same size and can be reversed. SHA-3 uses it inside a sponge construction. section 2.5.2
Understand its role through three pieces:
- Permutation: assigns each possible input to one output, with no two inputs sharing an output. section 2.5.2
- Sponge state: divides the permutation’s input and output into a rate and a capacity. section 2.5.2
- Absorption and squeezing: XORs message blocks with the rate, applies keccak-f, then repeatedly permutes and reads rate bits for the digest. section 2.5.2
An 8-bit mental model
Imagine keccak-f mapping every possible 8-bit string to another 8-bit string. A sponge can XOR input such as 00101 into a five-bit rate, apply the permutation, and repeat for longer inputs. section 2.5.2
Figure 2.13 The permutation f randomizes an input of size 8 bits into an output of the same size. In a sponge construction, this permutation’s input and output are divided into two parts: the rate (of size r and the capacity (of size c).
Use the rate-and-capacity diagram to see how a fixed-size permutation becomes the state transformation inside a sponge. section 2.5.2
