Skip to main content
QUICK REVIEW

[Paper Review] Estimating the cost of generic quantum pre-image attacks on SHA-2 and SHA-3

Matthew Amy, Olivia Di Matteo|arXiv (Cornell University)|Mar 30, 2016
Quantum Computing Algorithms and ArchitectureComputer Science18 references7 citations
TL;DR

This paper estimates the resource cost of generic quantum pre-image attacks on SHA-256 and SHA3-256 using Grover’s algorithm on a surface code-based fault-tolerant quantum computer. It introduces a time-area cost model that accounts for logical qubits and circuit depth in surface code cycles, revealing that the true cost is approximately $2^{166.5}$ logical-qubit-cycles—over 275 billion times higher than naive query-based estimates—due to the overhead of magic state distillation and error correction.

ABSTRACT

We investigate the cost of Grover's quantum search algorithm when used in the context of pre-image attacks on the SHA-2 and SHA-3 families of hash functions. Our cost model assumes that the attack is run on a surface code based fault-tolerant quantum computer. Our estimates rely on a time-area metric that costs the number of logical qubits times the depth of the circuit in units of surface code cycles. As a surface code cycle involves a significant classical processing stage, our cost estimates allow for crude, but direct, comparisons of classical and quantum algorithms. We exhibit a circuit for a pre-image attack on SHA-256 that is approximately $2^{153.8}$ surface code cycles deep and requires approximately $2^{12.6}$ logical qubits. This yields an overall cost of $2^{166.4}$ logical-qubit-cycles. Likewise we exhibit a SHA3-256 circuit that is approximately $2^{146.5}$ surface code cycles deep and requires approximately $2^{20}$ logical qubits for a total cost of, again, $2^{166.5}$ logical-qubit-cycles. Both attacks require on the order of $2^{128}$ queries in a quantum black-box model, hence our results suggest that executing these attacks may be as much as $275$ billion times more expensive than one would expect from the simple query analysis.

Motivation & Objective

  • To assess the true cost of quantum pre-image attacks on SHA-2 and SHA-3 hash functions beyond simple query complexity.
  • To model the resource overhead of fault-tolerant quantum computation, particularly for surface code architectures.
  • To quantify how much more expensive quantum pre-image attacks are in practice due to error correction and magic state distillation.
  • To provide a realistic comparison between classical and quantum attack costs using a time-area metric.
  • To evaluate the impact of error correction and logical gate implementation on the overall feasibility of quantum cryptanalysis.

Proposed method

  • Constructing reversible quantum circuits for SHA-256 and SHA3-256 using the Clifford+T gate set.
  • Optimizing the circuits for minimal T-count and T-depth using the T-par quantum circuit optimization tool.
  • Estimating fault-tolerant resource costs via surface code encoding with logical Clifford+T operations.
  • Modeling magic state distillation overhead using the surface code, assuming a threshold error rate of $10^{-5}$.
  • Computing the total cost as the product of logical qubits and surface code cycles, using a time-area metric.
  • Deriving the total cost as $2^{166.4}$ for SHA-256 and $2^{166.5}$ for SHA3-256, dominated by magic state distillation.

Experimental results

Research questions

  • RQ1How much more expensive are quantum pre-image attacks on SHA-256 and SHA3-256 when accounting for fault-tolerant quantum error correction?
  • RQ2What is the dominant resource bottleneck in executing Grover’s algorithm on a surface code-based quantum computer for hash pre-image search?
  • RQ3To what extent does magic state distillation increase the total cost of a quantum pre-image attack compared to the number of queries?
  • RQ4How do the resource requirements scale when using a realistic error-correcting architecture instead of a query-only model?
  • RQ5Can the time-area cost metric provide a more accurate comparison between classical and quantum attacks than the standard query complexity model?

Key findings

  • The total cost of a quantum pre-image attack on SHA-256 is estimated at $2^{166.4}$ logical-qubit-cycles, with $2^{153.8}$ surface code cycles and $2^{12.6}$ logical qubits.
  • For SHA3-256, the attack cost is $2^{166.5}$ logical-qubit-cycles, requiring $2^{146.5}$ surface code cycles and $2^{20}$ logical qubits.
  • The dominant cost factor is magic state distillation, requiring 294 distillation factories to keep up with the $T$-gate demand, increasing physical qubit count to $1.63 \times 10^8$.
  • The attack depth is limited by magic state generation, which takes approximately $7.23 \times 10^{29}$ years at a 200 ns cycle time.
  • The time-area cost is over 275 billion times higher than the naive query complexity estimate of $2^{128}$, due to error correction and distillation overhead.
  • The results suggest that even though Grover’s algorithm provides a quadratic speedup, the practical cost of fault-tolerant implementation severely limits the feasibility of such attacks.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.