Abstract:$\mathsf{XS}$-circuits describe cryptographic primitives that utilize two operations on binary words of fixed length: bitwise modulo $2$ addition ($\mathsf{X}$) and substitution ($\mathsf{S}$). The words are interpreted as elements of a field of characteristic $2$. In this paper, we develop a model of $\mathsf{XS}$-circuits according to which several instances of a simple round circuit containing only one $\mathsf{S}$ operation are linked together and form a compound circuit called a cascade. $\mathsf{S}$ operations of a cascade are interpreted as independent round oracles. When a cascade processes a pair of different inputs, some round oracles get different queries, these oracles are activated. The more activations, the higher security guarantees against differential cryptanalysis the cascade provides. We introduce the notion of the guaranteed number of activations, that is, the minimum number of activations over all choices of the base field, round oracles and pairs of inputs. We show that the guaranteed number of activations is related to the minimum distance of the linear code associated with the cascade. It is also related to the minimum number of occurrences of units in segments of binary linear recurrence sequences whose characteristic polynomial is determined by the round circuit. We provide an algorithm for calculating the guaranteed number of activations. We show how to use this algorithm to deal with linear activations related to linear cryptanalysis.
Key words:circuit, differential cryptanalysis, linear cryptanalysis, linear code, linear recurrence sequence.