E5: excess prevalence
Generated by python3 tools/experiments/e5_excess_prevalence.py. Never edit by hand.
Toy block ciphers: 8-bit blocks, 65536 keys (seed 5). The ideal cipher gives every key an independent uniform permutation. Two defective ciphers are the ideal one with 16 keys replaced. \(\kappa\) = (fraction of keys satisfying the relation) / (probability that a uniform permutation satisfies it); the denominator is exact, the numerator is counted over all keys, and the ± is two standard errors of that count. Advantage: the distinguisher asks the stated number of queries and accepts if the relation holds on them; real side drawn from the class, ideal side fresh uniform permutations, 4000 trials each.
Block ciphers
| cipher | relation | keys satisfying it | ideal probability | kappa | advantage when conditioned | queries | verdict under I.3 |
|---|---|---|---|---|---|---|---|
| ideal | E_k(x) = y, fixed x, y | 261 | 0.0039 | 1.02 ± 0.13 | 0.995 | 1 | kappa about 1: not group A |
| ideal | E_k is an involution | 0 | 2^-822 | - | - | - | no key satisfies it: no class |
| 16 involution keys | E_k(x) = y, fixed x, y | 261 | 0.0039 | 1.02 ± 0.13 | 0.996 | 1 | kappa about 1: not group A |
| 16 involution keys | E_k is an involution | 16 | 2^-822 | 2^810 | 1.000 | 4 | excess: admitted |
| 16 keys equal a public permutation P | E_k agrees with P on 1 point | 267 | 0.0039 | 1.04 ± 0.13 | 0.996 | 1 | kappa about 1: not group A |
| 16 keys equal a public permutation P | E_k agrees with P on 2 points | 16 | 1.5e-05 | 15.94 ± 7.97 | 1.000 | 2 | excess: admitted |
| 16 keys equal a public permutation P | E_k agrees with P on 3 points | 16 | 2^-24 | 4048.12 ± 2024.06 | 1.000 | 3 | excess: admitted |
| 16 keys equal a public permutation P | E_k agrees with P on all 256 points | 16 | 2^-1684 | 2^1672 | 1.000 | 8 | excess: admitted |
Polynomial MAC
Hash over GF(65521): the key is H, the hash of a message is the sum of m_i H^i. The relation is "the hash collides on a chosen pair (M1, M2)", with the pair built so that a chosen set of ell keys are the roots. Counted over all 65521 keys.
| chosen keys (message length ell) | keys that collide | prevalence | ideal (random function) | kappa |
|---|---|---|---|---|
| 1 | 1 | 1/65521 | 1/65521 | 1 |
| 4 | 4 | 4/65521 | 1/65521 | 4 |
| 16 | 16 | 16/65521 | 1/65521 | 16 |
| 64 | 64 | 64/65521 | 1/65521 | 64 |
Result
- The artifact is separated from real degeneracy. "E_k(x) = y" gives a distinguishing advantage near 1 once the challenger is conditioned on it, in the ideal cipher too, and has \(\kappa\) about 1. "E_k is an involution" has no members in the ideal cipher and an astronomically large \(\kappa\) where it was planted. Confirmed.
- \(\kappa\) belongs to the relation, not to the keys. The 16 keys that equal a public permutation are as weak as a key can be, yet the one-point relation that holds for them has a true \(\kappa\) of about 1.06, which the measurement cannot tell from 1. Two points give a clear excess, three a large one, the full relation an astronomical one. A \(\kappa\) near 1 for one relation therefore clears nothing: a stronger relation may expose the same keys.
- Estimating \(\kappa\) needs enough keys. With 65536 keys the one-point count has a relative error of about 6%, so a planted class of 16 keys (6% excess) cannot be seen through a weak relation.
- Polynomial MAC: \(\kappa\) equals the number of chosen keys, which is bounded by the message length. This agrees with the value the criteria inferred from the abstract of [R24], in a toy model. It is not small for long messages.
Consequences for taxonomy/classification.md I.3: the condition \(\kappa>1\) does its
job as a filter. The text should say that \(\kappa\) is reported for the stated
relation, that the strongest relation holding for the class should be stated,
and that \(\kappa\approx1\) for one relation does not clear a key.