TL;DR
This paper provides the first comprehensive security analysis of BLAKE2, the high-performance successor to the SHA-3 finalist BLAKE. While the authors find that BLAKE2’s speed-oriented "tweaks"—like removing constants—make its internal permutation theoretically more vulnerable to rotational attacks, the overall hash function maintains a robust security margin, even improving resistance to certain differential attacks due to its new initialization process.
What Problem Does This Paper Address?
In the world of cryptography, "tweaking" a proven design for better performance is a double-edged sword. BLAKE2 was introduced to be faster than its predecessor (BLAKE) and even rival MD5 in speed, while supporting modern features like parallelism and tree-hashing. To achieve this, the designers removed constants from the round function, changed rotation amounts, and simplified the initialization.
The core question the authors tackle is: Did these performance optimizations create security backdoors? Specifically, they investigate how these changes affect standard cryptanalytic techniques like differential, impossible differential, and rotational cryptanalysis.
Methods
The authors employ several advanced cryptanalytic frameworks to "stress test" BLAKE2:
- Rotational Cryptanalysis: This technique exploits the fact that in ARX (Addition-Rotation-XOR) primitives, if you rotate the input, the output is often a rotated version of the original output. The authors specifically target the lack of constants in BLAKE2’s $G$ function, which usually acts as a "breaker" for such symmetry.
- Internal Differentials (Squeeze Attack): They look for symmetries within the internal state columns to see if an attacker can predict how differences propagate.
- Impossible Differential Cryptanalysis: Using a "miss-in-the-middle" approach, they find two differential paths (one forward, one backward) that are individually possible but logically contradict each other when they meet, allowing them to discard incorrect key/state guesses.
- Automated Differential Search: The authors developed improved search algorithms to find the best (highest probability) differential characteristics for the modified rotation constants in BLAKE2.
Datasets
As a theoretical cryptanalysis paper, it does not use traditional training datasets. Instead, the "data" consists of the mathematical specifications and permutations of the BLAKE and BLAKE2 families (including BLAKE-256, BLAKE-512, BLAKE2s, and BLAKE2b). The authors also utilize the message permutations defined in the original standards to track difference propagation.
Key Insights and Ideas
- The "Constant" Trade-off: The most significant finding is that removing constants from the $G$ function makes the underlying permutation much weaker. They show a rotational attack can penetrate all 12 rounds of the BLAKE2b permutation. However, they note this is a theoretical weakness; in the actual hash function, the initialization vectors (IVs) are non-rotational, which blocks this attack in practice.
- Initialization as a Defense: Surprisingly, the new initialization method in BLAKE2—which fixes more state words than the original BLAKE—actually restricts the attacker’s freedom. This makes it harder to find high-probability differential paths, effectively increasing the security of the compression function against certain attacks.
- Rotation Sensitivity: The authors found that the specific rotation constants chosen for BLAKE2b are more resistant to certain automated differential searches than those used in BLAKE-256, showing that the "tweaked" constants were well-chosen for security, not just software performance.
Key Results
The paper presents a detailed comparison of attacked rounds between BLAKE and BLAKE2 (summarized in Table 1 and 2):
- Impossible Differentials: The authors improved the best-known results for both families, finding a 6.5-round impossible differential for the permutations of BLAKE-256, BLAKE-512, BLAKE2s, and BLAKE2b.
- Differential Distinguishers: They found a 3.5-round differential for the BLAKE2b hash function (compared to 2.5 rounds for BLAKE) and a 4.5-round differential for the compression function.
- Rotational Attacks: While BLAKE is immune, the authors demonstrated a theoretical distinguisher for the full 12 rounds of the BLAKE2b permutation and 7 rounds for BLAKE2s.
- Overall Security: Despite the theoretical vulnerabilities in the permutation, the authors conclude that the BLAKE2 hash function has a security margin only slightly lower than BLAKE, remaining very secure against practical attacks.
Limitations and Future Work
The primary limitation is that the most powerful attacks (like the 12-round rotational attack) apply only to the internal permutation or the compression function with a chosen IV. In the standard "fixed IV" setting required for a secure hash function, these attacks are mitigated.
The authors suggest that future work could involve refining the search for differential characteristics in ARX designs or exploring if the "weak" IVs they identified could be exploited in specific application-layer protocols where an attacker might have some influence over the initialization parameters.
Summary updated