[This blogpost is based on a talk titled A DFA Attack on White-Box Implementations of AES with External Encodings by A. Amadori, W. Michiels and P. Roelse @ SAC2019]
The classical attack model on cryptographic algorithms is in the so-called black-box scenario, where the mathematical security of a cipher is uniquely deduced by observing the input and output of the algorithm. On the other hand, in the white box scenario, the main concern is the security of the actual implementation of the algorithm, because the attacker might have access to the code of the algorithm and might even modify and control the source code of the algorithm as well as the execution environment.
Attacks targeting the source code are known as algebraic attacks, because they exploit the algebraic operations of the internal structure. Once setup, these attacks are extremely powerful. However, in a more realistic scenario, the source code might not be easily available to the attacker and obtaining it might require expensive reverse engineering as well as de-obfuscation. Therefore the attacker is often left to look at the binary. Attacks performed on the binary are called side channel attacks.
Among side-channel attacks are the Differential Fault attacks (DFA). The paradigm of a DFA consists in modifying a state of the cipher so to get an “altered” output. From this modified output and looking at how the fault has spread, one can setup a system of equations, where the unknowns are parts of the round key. “Obfuscating” these outputs is an efficient countermeasure to avoid side-channel attacks: typically this is done by randomizing the outputs using a series of operations that in the white box framework are called external encodings. All side channel attacks fail if external encoding is applied. The strength of such countermeasures was only empirically proven but widely accepted.
The authors of this paper show for the first time that, in general, external encodings do not provide adequate security. They perform this analysis on an encoded version of AES. The attacks consists in several fault injection phases to obtain a randomized system of equations. Algebraic techniques are then used to reduce the entropy of the variables of the system until these equations are easy enough to be solved by elementary algebra. This attack gets rid of the external encodings. At this point, standard side-channel techniques can be used to recover the key.


