Introduction

On the Security of Hash Functions

Unlike block ciphers, hash functions have no secret key: every party can evaluate them on any input. This absence of a key removes the standard quantity cryptographers use to talk about the “security” of a primitive: there is no key-recovery advantage to bound, no distinguishing game against a keyed oracle. However, hash functions are expected to “resist” attackers, in some sense. Many modern designs, and in particular all arithmetization-oriented hash functions, are built around a fixed, public permutation.

In the absence of a key, there are in practice two broad families of proxies to evaluate the security of a permutation (beyond the obvious cryptanalysis of a hash function using it): the CICO-k problem, and distinguishers for the permutation.

Constrained-Input, Constrained-Output

A CICO problem asks: given a permutation π\pi and constraints on a subset of the input and output bits (typically fixing the field elements corresponding to the sponge’s capacity to zero), find an input/output pair satisfying them. If there are kk field elements that must be set to zero in both the input and in the output, we call the problem CICO-k. CICO problems are a convenient formalization because:

  • they isolate the permutation from the mode, letting cryptanalysts focus purely on the algebraic/statistical behavior of π\pi;
  • many concrete attack goals (finding a sponge collision or preimage) reduce naturally to a CICO instance with specific constraints derived from the mode’s parameters (e.g. fixing a part of the output to be a digest targeted in a preimage attack);
  • CICO has been used in many cryptanalysis papers, meaning that it provides a good basis for the comparison of primitives.

Techniques used to solve or bound CICO problems typically include MITM-style approaches, and algebraic methods (Gröbner bases, guess-and-determine…) which are particularly relevant in the AO context.

Distinguishers

Alternatively, one can study the permutation as if it were a keyed primitive with the key fixed to a known constant, and search for distinguishers: properties that separate π\pi from a permutation drawn uniformly at random, without necessarily yielding a collision or preimage. This includes differential distinguishers (in particular limited-birthday distinguishers, which trade an unusually structured differential property for a search space smaller than what generic birthday-bound attacks would need), linear/statistical biases, rotational distinguishers, zero-sum properties, integral/higher-order distinguishers…

Distinguishers are, intuitively, a somewhat weaker statement than an explicit attack: a distinguisher does not need to translate directly into a break of any of the security goals of the hash function. However, they may still break the assumptions on which a security proof is based. In particular, the indifferentiability proof of the sponge-based hash function12 can fall apart.

From another angle, distinguishers can also be thought of as early warning signs that the permutation deviates from “ideal” behavior in some exploitable region. In fact, historically, some of them have eventually evolved into full-blown attacks (see the cryptanalysis of SHA-1 which started as differential distinguishers against the compression function), or have driven a modification of some parameters despite the absence of an associated full break (as happened, for instance, when the number of rounds of the permutation used in SHA-3 was increased following3).

Attacks vs. Security Argument

A security analysis can be based on two approaches: finding as good an attack as possible, or arguing that attacks of a given type cannot work. In the non-AO case, cryptographers are expected to provide a detailed (but perhaps not so complicated) argument justifying that differential attacks cannot work. The corresponding result is then used to choose the number of rounds of the permutation in such a way as to ensure that such an attack cannot work.

In the AO case, designers are still expected to provide such arguments, but they are usually easy to make. However, for so-called “algebraic” or “POlynomial System SOlving (PoSSo)” based attacks, arguing security can be difficult—if at all possible with the tools currently at our disposal.

When assessing a primitive, attacks provide an upper-bound on the security it can offer, while security arguments provide a lower bound.

Two Regimes of Parameters

Most of the literature on the cryptanalysis of Arithmetization-Oriented hash functions (AO-HF) has focused on finding attacks that are relevant when the hash function deals with few elements of a very big prime field. Typically, this corresponds to AO-HFs relying on a permutation defined over Fp3\mathbb{F}_p^3, where pp is a 256- or 384-bit prime. In this context, finding solutions to the CICO-1 problem is very meaningful. We will nickname this regime of parameters FB: Few Big field elements. There has been a lot of cryptanalysis in the FB setting, for instance456.

However, when dealing with proof systems operating on smaller primes (typically 30- or 60-bit long), the CICO-1 problem becomes irrelevant: it can be solved by brute-force, and doing so does not achieve much from a cryptography standpoint. In this case, the underlying permutations operate over Many Small field elements: we call this the MS setting. Unfortunately, the current literature contains much less information in the MS setting, both in terms of attack technique and in terms of security argument.

In what follows, we summarize the state of the art in the MS case for all hash functions that we deemed relevant. Relevance is assessed based on the following two criteria:

  • they have either been accepted for publication at a relevant venue, or are used in practice, and
  • they are well defined in the MS context.

This list consists, in alphabetic order, of

  • Anemoi7,
  • Griffin8,
  • Monolith9,
  • Poseidon10,
  • Poseidon211,
  • Rescue12,
  • Tip513, and
  • XHASH14.

Best Attacks

In the FB Setting

Many primitives have been successfully attacked in the FB setting, meaning for CICO-1 or CICO-2.

  • The FreeLunch4 consists in writing a system of equations modeling a CICO-1 problem using a different approach than the one considered by most primitive designers. The key insight is that this new system, coupled with a dedicated custom monomial ordering, is immediately a Gröbner basis: an entire step of the cryptanalysis is thus bypassed. This led to many attacks in the FB setting, in particular against Griffin.
  • Techniques based on resultants were later introduced in15, and then improved in6 and in16. These proved devastating: on top of better attacks against Griffin, these also successfully targeted Anemoi and some variants of Rescue.

In this context, only one family has come out unscathed: that of Poseidon (and Poseidon2).

In the MS Setting

Far fewer analyses have been made in this context. Some works investigated distinguishers against Monolith1718 and Tip51819 that involve controlling a space of dimension much larger than 2 in both the input and output.

Algebraic attacks have received less attention in this setting. In some previous works, it has been possible to find dedicated solving algorithms for CICO-1 and CICO-2 that are much more efficient than the generic ones (i.e. proper calls to F4/F5 or to FGLM are entirely avoided); however, such shortcuts are not known in the CICO-k setting when k>3k > 3. This means that algebraic attacks in the MS setting face an important hurdle.

On the other hand, in this context, the attacker has a lot of degrees of freedom that can be expanded to bypass non-linear functions when writing a system of equations. This technique, nicknamed round-skip20, has been shown to be particularly efficient against Poseidon221.

The picture is thus very different in the MS setting:

  • none of the hash functions under consideration has been the target of any significant break,
  • at the same time, Poseidon (and in particular Poseidon2) is in a more difficult position than in the FB setting: skipping the first 4 rounds could be devastating due to the structure of the primitive, and its algebraic attack seems to be more amenable to such improvements than the other candidates due to its monomial S-box. Still, the best round skips only cover 2.5 rounds at this stage, and the techniques needed to prevent round skip seem to boil down to the use of a strong and fast diffusion—a well known criterion in the non-AO world.

We stress that the conclusion to draw here is not that Poseidon(2) is broken in this setting, only that MS and FB are two very different beasts. We also insist that our conclusion is not that AO algorithms are inherently less secure than non-AO ones; instead, we want to highlight research directions that require further investigation.

On Arguable Security

On the Ideal Degree

In the FB setting, the ideal degree has emerged as an important quantity that determines the complexity of algebraic attacks. Thus, lower bounding it is a convincing way to argue security in the CICO-1 setting.

However, in the MS setting, it becomes possible for an attacker to proceed as follows. Among all the unknowns in the system of equations, they can pick one, and go through all possible values for it. For each value, they obtain a restricted system of equations that is a priori unlikely to have a solution, but which is overdefined. As a consequence, its ideal degree22 drops to 0… which is not a great lower bound for an attack complexity.

Known Ideal Degrees in the MS Setting

Setting aside the potential solving method outlined above, the ideal degree can still give us a tool to compare primitives. The best attacks in the well defined (i.e., not over defined) setting have a complexity which is at least linear in this quantity (it corresponds to the final step of the attack), though this quantity also intervenes in the complexity of other steps (in particular, in that of FGLM and variants). In this last case, the dependency in the algebraic degree is of higher degree, often at least quadratic.

Below, we plug in the numbers in the formulae from23 for the ideal degree corresponding to CICO-8 (for 32-bit primes) and CICO-4 (for Goldilocks), i.e., to a 256-bit capacity/digest. This corresponds to a 128-bit secure hash function. The number of branches does not change the ideal degree, but it needs to be large enough that the function is useful (i.e. 16 for 32-bit primes and 8 for Goldilocks).

The resulting table is below (for the complete per-primitive cryptanalysis surveys, see Chapter 2 of Final Report v1.0):

PrimitiveIdeal degree formulaKoalaBearMersenneGoldilocks
Anemoi(α+2)kr(\alpha+2)^{kr}185.75224.59164.84
Griffin(α(α(3k−1)+1))R\big(\alpha\left(\alpha(3^k-1)+1\right)\big)^R158.49155.9195.51
PoseidonαkRF+RP\alpha^{kR_F + R_P}137.89199.69151.60
Poseidon2αkRF+RP\alpha^{kR_F + R_P}137.89199.69151.60
XHASH-partialα2k+2t/3\alpha^{2k+2t/3}undefined445.81269.51

For Monolith, Rescue and Tip5, these quantities are not known. While it might be possible to get it for Rescue by tweaking known techniques, the split-and-lookup operations in Monolith and Tip5 are likely to be an issue in this context. On the other hand, thanks to these split-and-lookup operations, their safety against the CICO-k problem can be hoped to be argued using more classical techniques.

Where to Go From Here

In order to choose a hash function, assessing the security of Poseidon and Poseidon2 actually means comparing it with its competitors. Still, we need to overcome a significant technical hurdle: most of the literature has focused on the “Few Big field elements” setting, meaning on hash functions defined over prime fields that are hundreds of bits long and on permutations that need to resist CICO-1. This is not very useful for us: in the “Many Small field elements” setting, which corresponds to hash functions operating on the fields of size KoalaBear, Mersenne, or Goldilocks, the picture looks substantially different. Worse, the tools developed to argue security in the FB setting lose a lot of their strength in the MS setting.

Nevertheless, there are still good reasons not to worry too much.

  • So far, no primitive has been broken in the MS setting. In fact, a permutation like Griffin, soundly broken in the FB setting, provides quite some security in the MS setting.
  • “Classical” design techniques, meaning better understood methods used to design non-AO primitives, seem to be the way to go to prevent one of the more threatening attack vectors (round skips).

References


  1. Guido Bertoni, Joan Daemen, Michaël Peeters, and Gilles Van Assche. Cryptographic sponge functions. Technical report, 2011. ↩︎

  2. Guido Bertoni, Joan Daemen, Michaël Peeters, and Gilles Van Assche. Sponge functions. ECRYPT Hash Workshop 2007, 2007. ↩︎

  3. Christina Boura, Anne Canteaut, and Christophe De Cannière. Higher-order differential properties of Keccak and Luffa. In Antoine Joux, editor, Fast Software Encryption – FSE 2011, volume 6733 of Lecture Notes in Computer Science, pages 252–269. Springer, Berlin, Heidelberg, February 2011. ↩︎

  4. Augustin Bariant, Aurélien Boeuf, Axel Lemoine, Irati Manterola Ayala, Morten Øygarden, Léo Perrin, and Håvard Raddum. The algebraic FreeLunch: Efficient Gröbner basis attacks against arithmetization-oriented primitives. In Leonid Reyzin and Douglas Stebila, editors, Advances in Cryptology – CRYPTO 2024, Part IV, volume 14923 of Lecture Notes in Computer Science, pages 139–173. Springer, Cham, August 2024. ↩︎ ↩︎

  5. Katharina Koschatko, Reinhard Lüftenegger, and Christian Rechberger. Exploring the six worlds of Gröbner basis cryptanalysis: Application to anemoi. IACR Transactions on Symmetric Cryptology, 2024(4):138–190, 2024. ↩︎

  6. Augustin Bariant, Aurélien Boeuf, Pierre Briaud, Maël Hostettler, Morten Øygarden, and Håvard Raddum. Improved resultant attack against arithmetization-oriented primitives. In Yael Tauman Kalai and Seny F. Kamara, editors, Advances in Cryptology – CRYPTO 2025, Part V, volume 16004 of Lecture Notes in Computer Science, pages 335–367. Springer, Cham, August 2025. ↩︎ ↩︎

  7. Clémence Bouvier, Pierre Briaud, Pyrros Chaidos, Léo Perrin, Robin Salen, Vesselin Velichkov, and Danny Willems. New design techniques for efficient arithmetization-oriented hash functions: Anemoi permutations and Jive compression mode. In Helena Handschuh and Anna Lysyanskaya, editors, Advances in Cryptology – CRYPTO 2023, Part III, volume 14083 of Lecture Notes in Computer Science, pages 507–539. Springer, Cham, August 2023. ↩︎

  8. Lorenzo Grassi, Yonglin Hao, Christian Rechberger, Markus Schofnegger, Roman Walch, and Qingju Wang. Horst meets fluid-SPN: Griffin for zero-knowledge applications. In Helena Handschuh and Anna Lysyanskaya, editors, Advances in Cryptology – CRYPTO 2023, Part III, volume 14083 of Lecture Notes in Computer Science, pages 573–606. Springer, Cham, August 2023. ↩︎

  9. Lorenzo Grassi, Dmitry Khovratovich, Reinhard Lüftenegger, Christian Rechberger, Markus Schofnegger, and Roman Walch. Monolith: Circuit-friendly hash functions with new nonlinear layers for fast and constant-time implementations. IACR Transactions on Symmetric Cryptology, 2024(3):44–83, 2024. ↩︎

  10. Lorenzo Grassi, Reinhard Lüftenegger, Christian Rechberger, Dragos Rotaru, and Markus Schofnegger. On a generalization of substitution-permutation networks: The HADES design strategy. In Anne Canteaut and Yuval Ishai, editors, Advances in Cryptology – EUROCRYPT 2020, Part II, volume 12106 of Lecture Notes in Computer Science, pages 674–704. Springer, Cham, May 2020. ↩︎

  11. Lorenzo Grassi, Dmitry Khovratovich, and Markus Schofnegger. Poseidon2: A faster version of the poseidon hash function. In Nadia El Mrabet, Luca De Feo, and Sylvain Duquesne, editors, AFRICACRYPT 23: 14th International Conference on Cryptology in Africa, volume 14064 of Lecture Notes in Computer Science, pages 177–203. Springer, Cham, July 2023. ↩︎

  12. Abdelrahaman Aly, Tomer Ashur, Eli Ben-Sasson, Siemen Dhooghe, and Alan Szepieniec. Design of symmetric-key primitives for advanced cryptographic protocols. IACR Transactions on Symmetric Cryptology, 2020(3):1–45, 2020. ↩︎

  13. Alan Szepieniec, Alexander Lemmens, Jan Ferdinand Sauer, and Bobbin Threadbare. The Tip5 hash function for recursive STARKs. Cryptology ePrint Archive, Report 2023/107, 2023. ↩︎

  14. Tomer Ashur, Amit Singh Bhati, Al Kindi, Mohammad Mahzoun, Léo Perrin, and Sundas Tariq. The xhash family for zk-friendly hash functions. Des. Codes Cryptogr., 94(6):132, 2026. ↩︎

  15. Ziyu Zhao, Antonio Sanso, Giuseppe Vitto, and Jintai Ding. Graeffe-based attacks on poseidon and NTT lower bounds. Cryptology ePrint Archive, Report 2025/1916, 2025. ↩︎

  16. Antoine Bak, Augustin Bariant, Maël Hostettler, and Vincent Neiger. Resultants meet resultant: Improving CICO-1 and CICO-2 attacks on ZK-friendly permutations. Cryptology ePrint Archive, Paper 2026/1281, 2026. ↩︎

  17. Antoine Bak, Guilhem Jazeron, Pierre Galissant, and Léo Perrin. Attacking split-and-lookup-based primitives using probabilistic polynomial system solving applications to round-reduced monolith and full-round skyscraper. IACR Transactions on Symmetric Cryptology, 2025(3):337–367, 2025. ↩︎

  18. Fukang Liu, Katharina Koschatko, Lorenzo Grassi, Hailun Yan, Shiyao Chen, Subhadeep Banik, and Willi Meier. Opening the blackbox: Collision attacks on round-reduced Tip5, Tip4, Tip4’ and monolith. IACR Transactions on Symmetric Cryptology, 2024(4):97–137, 2024. ↩︎ ↩︎

  19. Antoine Bak and Léo Perrin. On the security of split-and-lookup-based ZK-friendly primitives. IACR Transactions on Symmetric Cryptology, 2025(2):87–123, 2025. ↩︎

  20. Augustin Bariant, Clémence Bouvier, Gaëtan Leurent, and Léo Perrin. Algebraic attacks against some arithmetization-oriented primitives. IACR Transactions on Symmetric Cryptology, 2022(3):73–101, 2022. ↩︎

  21. Simon-Philipp Merz and Àlex Rodríguez García. Skipping class: Algebraic attacks exploiting weak matrices and operation modes of poseidon2(b). Cryptology ePrint Archive, Paper 2026/306, 2026. ↩︎

  22. Formally, the ideal degree is the number of solutions of the system in the algebraic closure of the underlying field. As a consequence, for an overdefined system, it is equal to 0. On the other hand, the resolution of the corresponding system remains very difficult: the fact that it is not possible to lower bound its running time using the algebraic degree does not mean that this time is small. ↩︎

  23. Antoine Bak, Augustin Bariant, Aurélien Boeuf, Pierre Briaud, Morten Øygarden, and Atharva Phanse. The algebraic CheapLunch: Extending FreeLunch attacks on arithmetization-oriented primitives beyond CICO-1. Cryptology ePrint Archive, Report 2025/2040, 2025. ↩︎