liveBook · Manning

Keccak-f

As explained in Real-World Cryptography

keccak-f is the fixed-size permutation used as the internal transformation in SHA-3.

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

How Real-World Cryptography covers it

How deep it goes
Explains reversibility, rate and capacity, and sponge operations, but defers keccak-f’s design.
Examples
Uses shape mappings, an 8-bit permutation, rate-capacity diagrams, and XOR absorption of 00101.
What it assumes
Teaches permutations from an intuitive mapping example and assumes only the surrounding SHA-3 hashing context.
What you can do after
Evaluate/understand how SHA-3 uses keccak-f to absorb input and produce digest output.
How it connects
Connects keccak-f with SHA-3, sponge construction, rate, capacity, XOR, and AES.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Real-World Cryptography. The section links point to the parts of the book it draws on.