Open Access
Issue
Wuhan Univ. J. Nat. Sci.
Volume 31, Number 3, June 2026
Page(s) 241 - 249
DOI https://doi.org/10.1051/wujns/2026313241
Published online 24 June 2026

© Wuhan University 2026

Licence Creative CommonsThis is an Open Access article distributed under the terms of the Creative Commons Attribution License (https://creativecommons.org/licenses/by/4.0), which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.

0 Introduction

Quantum computing is an exciting technology at the intersection of computer science and physics, leveraging the unique properties of quantum mechanics to increase the speed of classical computational operations in certain cases. Advances in quantum computing present a serious challenge to the existing public-key cryptosystems, as schemes such as Rivest-Shamir-Adleman (RSA) and ELGamal can be efficiently broken by Shor's algorithm [1-2]. Therefore, studying cryptanalysis in the context of quantum computing has become increasingly important[3].Because the RSA cryptosystem is widely used in industry and government, fast cracking RSA has become an important research direction of modern cryptanalysis. The security of RSA depends on the intractability of the integer factorization problem. Therefore, the core approach to attacking RSA is to design efficient algorithms for factoring its modulus.

One of the most groundbreaking developments in integer factorization occurred in 1994, when Shor discovered a quantum algorithm capable of factoring integers in polynomial time[1-2]. If implemented on a practical quantum computer with several thousand quantum bits, Shor's algorithm can factor integers in probabilistic quantum polynomial time O((log n)3)Mathematical equation, representing a significant improvement over the classical number field sieve algorithm[4], whose runtime is sub-exponential runtime of the form O(exp (c(log n)1/3(log log n)2/3))Mathematical equation where c=(64/9)1/31.92Mathematical equation. This discovery poses a direct threat to the security of RSA encryption. Although Shor's algorithm operates on a classical computer, its remarkable efficiency stems from a key quantum subroutine. In the following sections, we present a simplified version of this algorithm as shown in Fig. 1, where r is the order of an element a in the multiplicative group (Z/nZ)*Mathematical equation, denoted by order (a,n)Mathematical equation, or la(n)Mathematical equation for short.

Thumbnail: Fig.1 Refer to the following caption and surrounding text. Fig.1 Simplified flowchart of Shor's algorithm

The emergence of Shor's algorithm has injected new vitality into the research of quantum computing, which has provided a driving force to promote quantum computing research in the last twenty years[5-12]. Current research on quantum factoring mainly focuses on improved or compiled versions of Shor's algorithm, using different techniques that have been proposed and studied. In a word, there are two important research directions in quantum integer factorization. On the one hand, people try to build a (practical) quantum computer, or even other types of physical computers, in order to implement the full version or compiled version of the Shor's algorithm [13-18]. On the other hand, people try to improve, modify and simplify Shor's original algorithm, or even invent new quantum factoring algorithms to be run on quantum computers with fewer quantum bits[19-24]. Ref. [23] proposed a compilied (simplified) and optimized version of Shor's algorithm by computing just the case for order(a,n)=2Mathematical equation, as this is the simplest possible order for the algorithm to be used to factor nMathematical equation, which only need two qubits.

So far, there are no quantum computers yet that capable of running Shor's algorithm on the large semiprimes n currently used in RSA encryption algorithms. Simulating Grover's algorithm has been achieved. Therefore, from another perspective, we propose an algorithm based on Grover's algorithm, which finds aMathematical equation satisfying a2kMathematical equation 1 (mod n)Mathematical equation while using fewer qubits.

The organization of the paper is as follows. In Section 1, we demonstrate through computational examples that finding a suitable aMathematical equation such that la(n)=2Mathematical equation holds is computationally as difficult as the Integer Factorization Problem the modulus n(IFP(n))Mathematical equation, that is,

Computing aMathematical equation such that la(n)=2 IFP(n).Mathematical equation

On the other hand, we shall look for some more suitable aMathematical equation for high orders, that is, la(n)=2k,k>1Mathematical equation. In Section 1, our results show that the higher the order, the greater the number of aMathematical equation. Therefore, from another perspective, instead of directly attempting to find la(n)Mathematical equation, we aim to identify a suitable aMathematical equation such that a2k1 (mod n)Mathematical equation. We propose a quantum algorithm for finding aMathematical equation in a2k1 (mod n)Mathematical equation with k1Mathematical equation based on Grover's search[25] in Section 2. The conclusion is given in Section 3.

1 Computational Evidence for Suitable Values of a

In this section, we give some numerical computations and pieces of evidences of suitable aMathematical equation for which la(n)Mathematical equation are small and relatively easy to obtain, in the light of quantum integer factorization.

Firstly, it is evident that in the computation of la(n)=2Mathematical equation (i.e., order (a,n)=2Mathematical equation ), the task will be significantly easy for a quantum computer if the period rMathematical equation is short, in particular, r=2Mathematical equation is the shortest possible order one can expect[19].

For a21 (mod n)Mathematical equation, if the prime factorization of n=pqMathematical equation is known, then aMathematical equation can be found by computing a±ppq±qqp(mod n)Mathematical equation, where

p q 1 / p   ( m o d   q ) ,   q p 1 / q   ( m o d   p ) Mathematical equation

For example, let n=221=13×17Mathematical equation. Then we have

a 1 p p q + q q p = 13 × 4 + 17 × 10 = 222 1   ( m o d   221 ) Mathematical equation

a 2 p p q - q q p = 13 × 4 - 17 × 10 = - 118 103   ( m o d   221 ) Mathematical equation

a 3 - p p q + q q p = - 13 × 4 + 17 × 10 = 118 - a 2   ( m o d   221 ) Mathematical equation

a 4 - p p q - q q p = - 13 × 4 - 17 × 10 = - 222 - a 1   ( m o d   221 ) Mathematical equation

S o ,   a = { ± 1 , ± 118 } .   C l e a r l y ,   a = ± 1   a r e   t r i v i a l .   T h u s ,   g c d   ( ± 118 ± 1 , n ) = { 13,17 } . Mathematical equation

For n=RSA-768Mathematical equation (a number with 232 digits and 768 bits), since we know its prime factorization, we get

a 1 p p q + q q p 1   ( m o d   n ) Mathematical equation

a 2 p p q - a 2 p p q - 1   029   031   793   302   493   258   003   488   818   376   905   875   264   575   120   178   567   995   715   921   117   383   374   063   780   955   476   265   714   655   965   556   097   487   715   509   708   453   134   212   472   071   241   551   710   737   667   646   125   017   671   995   537   319   749   739   035   045   343   586   527   599   466   828   935   082   557   618   400   047   627   481   255   809   299   529   939   ( m o d   n ) , Mathematical equation

           a 3 - p p q + q q p 201   154   891   227   624   497   127   006   140   008   056   845   508   278   449   416   766   796   481   401   334   768   352   336   726   308   181   253   030   546   234   230   371   902   240   965   234   320   929   633   453   121   315   774   592   716   063   902   143   490   245   030   584   823   163   722   635   383   870   725   074   621   773   650   339   655   236   462   265   303   792   116   204   047   602   613   474   ( m o d   n ) - a 2 ( m o d   n ) , Mathematical equation

           a 4 - p p q - q q p - a 1 - 1   ( m o d   n ) Mathematical equation

Thus,

a = ± 1 = ± 201   154   891   227   624   497   127   006   140   008   056   845   508   278   449   416   766   796   481   401   334   768   352   336   726   308   181   253   030   546   234   230   371   902   240   965   234   320   929   633   453   121   315   774   592   716   063   902   143   490   245   030   584   823   163   722   635   383   870   725   074   621   773   650   339   655   236   462   265   303   792   116   204   047   602   613   474 . Mathematical equation

In Table 1, we list the values of a satisfying a21 (mod n)Mathematical equation, when nMathematical equation is a factorized RSA modulus.

Proposition 1   Computing aMathematical equation such that la(n)=2IFP(n).Mathematical equation

Proof   Because we compute aMathematical equation such that la(n)=2Mathematical equation, that is, we obtain aMathematical equation satisfying a21 (mod n)Mathematical equation.

So we can compute gcd (a±1,n)=(p,q)Mathematical equation, that is, we obtain the factors of nMathematical equation.

Since n=pqMathematical equation with pMathematical equation and qMathematical equation two distinct prime numbers, then aMathematical equation can be obtained by computing a±ppq±qqp(mod n)Mathematical equation, where

p q 1 / p   ( m o d   q ) , q p 1 / q   ( m o d   p ) . Mathematical equation

Thus, the two non-trivial solutions are ± a mod nMathematical equation, and the two trivial solutions are ± 1 mod nMathematical equation.That is, we obtain aMathematical equation such that la(n)=2Mathematical equation.

Then we shall present some numerical evidences of suitable aMathematical equation such that la(n)=2kMathematical equation with k>1Mathematical equation, since there should be more numbers of aMathematical equation in such cases rather than just two aMathematical equation in a21 (mod n)Mathematical equation.

We give some computation evidences of different aMathematical equation for certain high order la(n) Mathematical equation; note that we shall only consider the case when la(n)=2kMathematical equation with k>1Mathematical equation, since odd orders are not useful in quantum integer factorization.

Let n=221Mathematical equation, then for different possible with k>1Mathematical equation, we get the corresponding aMathematical equation and the number of aMathematical equation (see Table 2).

As can be observed, as the value of rMathematical equation increases, the corresponding number of a also increases, but it dose not grow in a linear manner.

For n=391Mathematical equation, we have the result of Table 3.

This also shows that as the value of rMathematical equation increases, the number of aMathematical equation also increases. Compared with the case r=2Mathematical equation, there are two nontrivial values for aMathematical equation. However, for instance, when r=176Mathematical equation, there are a total of 160 values of aMathematical equation that satisfy the condition a1761 ( mod 391 )Mathematical equation.

In short, the above computing results indicted that the higher the order, the larger the number of aMathematical equation.

Table 1

The solutions to a21 (mod n)Mathematical equation for RSA modulus n with known factorization

Table 2

The corresponding aMathematical equation and the number of aMathematical equation for n=221Mathematical equation

Table 3

The corresponding aMathematical equation and the number of aMathematical equation for n=391Mathematical equation

2 A Quantum Algorithm for Breaking RSA

2.1 The New Algorithm

Through some numerical computations and pieces of evidences of suitable aMathematical equation for which la(n)Mathematical equation is small and relatively easy to obtain, in Section 1, in the light of quantum integer factorization, we find that the higher the order, the larger the number of aMathematical equation. Therefore, from a different perspective, rather than attempting to find the order rMathematical equation of a mod nMathematical equation, we aim to find a suitable value of a such that a2k1 (mod n)Mathematical equation. To avoid ambiguity, we explicitly exclude the trivial solution a1 (mod n)Mathematical equation, since only nontrivial solutions are useful for the factorization of nMathematical equation. Therefore, in this section, we present a quantum algorithm for finding aMathematical equation in a2k1 (mod n)Mathematical equation with k1Mathematical equation based on Grover's search as follows.

Algorithm 1 This algorithm aims to find a solution aMathematical equation in congruence a2k1 (mod n)Mathematical equation with k1Mathematical equation, so that one can compute gcd(ak±1,n)=(p,q)Mathematical equation in order to factor n=pqMathematical equation.

Step 1   Find a number qMathematical equation, a power of 2 , say 2tMathematical equation, such that t=log n2Mathematical equation.

Step 2   Initialize the two quantum registers, Reg1 and Reg2, to the all-zero state: |Ψ0=|0|0Mathematical equation.

Step 3   Perform a Hadamard transform on Reg1, we get

H :   | Ψ 0 | Ψ 1 = 1 q a = 0 q - 1 | a | 0 . Mathematical equation

Step 4   Perform the modular exponentiations UfMathematical equation on Reg2, we get

U f   :   | Ψ 1 | Ψ 2 = 1 q a = 0 q - 1 | a | a 2 k ( m o d   n ) , Mathematical equation

where Uf :|x|y|x|yf(x), f(x)=x2k(mod n).Mathematical equation

Step 5   Repeat the following steps O(q)Mathematical equation times.

Step 5-1   Perform a conditional phase shift UO'Mathematical equation on Reg2, with |1Mathematical equation receiving a phase shift of -Mathematical equation1 , at the same time perform a conditional phase shift UO''Mathematical equation on Reg1, with |1Mathematical equation receiving a phase shift of -Mathematical equation1 , thus

                U O ' U O ' '   :   | Ψ 2 | Ψ 3 Mathematical equation

= 1 q a = 0 q - 1 ( - 1 ) δ 1 , a ( - 1 ) δ 1 , a 2 k   m o d   n | a | a 2 k ( m o d   n ) . Mathematical equation

Suppose that the number of solutions of the function a2k1 (mod n) Mathematical equation is m'Mathematical equation , and these solutions are {a1,a2,,am'}.Mathematical equation UO'Mathematical equation denoted the operator UO'=I-2i=1m'|aiai|Mathematical equation, and the definition of function δMathematical equation is as follows,

δ 1 , a 2 k   m o d   n : = { 1 ,   w h e n   a 2 k   m o d   n 1 , 0 ,   w h e n   a 2 k   m o d   n 1 . Mathematical equation

U O ' ' Mathematical equation denoted the operator UO"=I-2|11|Mathematical equation.

Step 5-2   Perform the unitary operation UMathematical equation on Reg2, where U : |a|b|a|ba2k(mod n)Mathematical equation, obtaining

U   :   | Ψ 3 | Ψ 4 = 1 q a = 0 q - 1 ( - 1 ) δ 1 , a ( - 1 ) δ 1 , a 2 k   m o d   n | a | 0 . Mathematical equation

Step 5-3   Perform a Hadamard transform on Reg1.

Step 5-4   Perform a conditional phase shift on Reg1, with every computational basis state expect |0tMathematical equation receiving a phase shift of -Mathematical equation1.

Step 5-5   Perform a Hadamard transform on Reg1.

Step 6   Measure Reg1. Suppose the state |cMathematical equation has been observed. In fact, the observed cMathematical equation satisfying c2k1 (mod n) Mathematical equation with  k1 Mathematical equation has a higher probability of being close to 1.

2.2 Algorithm Analysis

The new algorithm has the following properties:

1) The complexity of the algorithm depends on the number of iterations, requiring O(q)Mathematical equation operations. It is only a quadratic speed up algorithm compared with

classical algorithm.

2) The success probability of the algorithm also depends on the number of iterations. Ref. [25] has shown that the upper bound on the required number of iterations is

R π 4 N M   , Mathematical equation

where NMathematical equation is the total number of a search space, MMathematical equation is the number of the solutions of the search problem. That is, in the algorithm, R=O(q)Mathematical equation. Grover iterations must be performed in order to obtain a solution to the congruence equation a2k1 (mod n), k1Mathematical equation, with the success probability closed to 1.

3) Compared with Shor's original algorithm which chooses qMathematical equation satisfying n2q=2t<2n2Mathematical equation, this algorithm chooses qMathematical equation satisfying n2<q=2t<nMathematical equation with t=log n2Mathematical equation. So the algorithm requires 3log n2Mathematical equation qubits, and Shor's algorithm for breaking RSA requires 3log nMathematical equation qubits. Obviously 3log n2<3log nMathematical equation, which indicates that the proposed approach significantly reduces the number of required qubits.

4) Shor's original algorithm tried to fix aMathematical equation and find the smallest rMathematical equation satisfying ar1 (mod n) Mathematical equation which chooses  q' Mathematical equation satisfying n2q'=2t<2n2Mathematical equation, with the time complexity O(q')Mathematical equation. Whereas in the algorithm, we try to find a suitable aMathematical equation, such that a2k1 (mod n)Mathematical equation with k1Mathematical equation. The most significant advantage of the algorithm is that it uses fewer quantum bits, which will be helpful for building a quantum computer with fewer quantum bits, and that in turn is relatively easy to build compared to a quantum computer with more quantum bits.

5) Once the aMathematical equation satisfying a2k1 (mod n)Mathematical equation with k1 Mathematical equation is found, one can compute gcd(ak±1,n)=(p,q)Mathematical equation, provided that n=pqMathematical equation with pMathematical equation and qMathematical equation prime. This can be used to break the famous and widely used RSA cryptographic system.

2.3 Example

We give a complete example, explicitly showing each computational steps of the algorithm.

Example 1 Let n=15, k=1Mathematical equation, that is, we can find a solution aMathematical equation satisfying a21 (mod 15)Mathematical equation.

Step 1   Find a number qMathematical equation, a power of 2, say 2tMathematical equation, such that t=log 152=3Mathematical equation.

Step 2   Initialize the two quantum registers, Reg1 and Reg2 with zeroes |Ψ0=|0|0Mathematical equation.

Step 3   Perform a Hadamard transform on Reg1, we get

H   :   | Ψ 0 | Ψ 1 = 1 8 a = 0 7 | a | 0 . Mathematical equation

Step 4   Perform the modular exponentiations UfMathematical equation on Reg2, we get

       U f   :   | Ψ 1 | Ψ 2 Mathematical equation

       = 1 8 a = 0 7 | a | a 2 ( m o d   15 ) Mathematical equation

       = 1 8 ( | 0 | 0 + | 1 | 1 + | 2 | 4 + | 3 | 9 Mathematical equation

       + | 4 | 1 + | 5 | 10 + | 6 | 6 + | 7 | 4 ) , Mathematical equation

where Uf : |x|y|x|yf(x), f(x)=x2(mod 15).Mathematical equation

Step 5   Repeat the following steps 2 times.

Step 5-1   Perform a conditional phase shift UO'Mathematical equation on Reg2, with |1Mathematical equation receiving a phase shift of -Mathematical equation1, and at the same time perform a conditional phase shift UO''Mathematical equation on Reg1, with |1Mathematical equation receiving a phase shift of -Mathematical equation1 , thus

       U O ' U O ' '   :   | Ψ 2 | Ψ 3 Mathematical equation

       = 1 8 a = 0 7 ( - 1 ) δ 1 , a ( - 1 ) δ 1 , a 2   m o d   15 | a | a 2   ( m o d   15 ) Mathematical equation

       = 1 8 ( | 0 | 0 + | 1 | 1 + | 2 | 4 + | 3 | 9 Mathematical equation

           - | 4 | 1 + | 5 | 10 + | 6 | 6 + | 7 | 4 ) . Mathematical equation

Step 5-2   Perform the unitary operation UMathematical equation on Reg2, where U : |a|b|a|ba2 (mod 15)Mathematical equation, obtaining

U :   | Ψ 3 | Ψ 4 Mathematical equation

= 1 8 a = 0 7 ( - 1 ) δ 1 , a ( - 1 ) δ 1 , a 2 m o d   15 | a | 0 Mathematical equation

= 1 8 ( | 0 + | 1 + | 2 + | 3 - | 4 + | 5 + | 6 Mathematical equation

+ | 7 ) | 0 Mathematical equation

Step 5-3   Perform a Hadamard transform on Reg1.

H :   | Ψ 4 | Ψ 5 Mathematical equation

= H :   [ 1 8 ( | 000 + | 001 + | 010 + | 011 - | 100 Mathematical equation

         + | 101 + | 110 + | 111 ) ] Mathematical equation

= 1 8 H ( | 000 + | 001 + | 010 + | 011 - | 100 Mathematical equation

      + | 101 + | 110 + | 111 ) Mathematical equation

= 1 8 1 8 [ ( | 0 + | 1 ) ( | 0 + | 1 ) ( | 0 + | 1 )       + ( | 0 + | 1 ) ( | 0 + | 1 ) ( | 0 - | 1 )       + ( | 0 + | 1 ) ( | 0 - | 1 ) ( | 0 + | 1 )       + ( | 0 + | 1 ) ( | 0 - | 1 ) ( | 0 - | 1 )       - ( | 0 - | 1 ) ( | 0 + | 1 ) ( | 0 + | 1 )       + ( | 0 - | 1 ) ( | 0 + | 1 ) ( | 0 - | 1 )       + ( | 0 - | 1 ) ( | 0 - | 1 ) ( | 0 + | 1 )       + ( | 0 - | 1 ) ( | 0 - | 1 ) ( | 0 - | 1 ) ] = 1 4 ( 3 | 000 - | 001 - | 010 - | 011 + | 100 + | 101       + | 110 + | 111 ) . Mathematical equation

Step 5-4   Perform a conditional phase shift on Reg1 with every computational basis state, except |13Mathematical equation receiving a phase shift of -Mathematical equation1 .

| Ψ 6 = 1 4 ( 3 | 000 + | 001 + | 010 + | 011 - | 100 - | 101 - | 110 - | 111 ) . Mathematical equation

Step 5-5   Perform a Hadamard transform on Reg1.

H :   | Ψ 6 | Ψ 7 = H :   [ 1 4 ( 3 | 000 + | 001 + | 010 + | 011 - | 100       - | 101 - | 110 - | 111 ) ] Mathematical equation

= 1 4 1 8 [ 3 ( ( | 0 + | 1 ) ( | 0 + | 1 ) ( | 0 + | 1 ) )       + ( | 0 + | 1 ) ( | 0 + | 1 ) ( | 0 - | 1 )       + ( | 0 + | 1 ) ( | 0 - | 1 ) ( | 0 + | 1 )       + ( | 0 + | 1 ) ( | 0 - | 1 ) ( | 0 - | 1 )       - ( | 0 - | 1 ) ( | 0 + | 1 ) ( | 0 + | 1 )       - ( | 0 - | 1 ) ( | 0 + | 1 ) ( | 0 - | 1 )       - ( | 0 - | 1 ) ( | 0 - | 1 ) ( | 0 + | 1 ) Mathematical equation

      - ( | 0 - | 1 ) ( | 0 - | 1 ) ( | 0 - | 1 ) ] = 1 4 2 ( | 000 + | 001 + | 010 + | 011 + 5 | 100 Mathematical equation

           + | 101 + | 110 + | 111 ) . Mathematical equation

Perform Step 5-1 to Step 5-5 again, we can get

| Ψ ' 7 = 1 8 2 ( - | 000 - | 001 - | 010 - | 011 + 11 | 100 - | 101 - | 110 - | 111 ) . Mathematical equation

Step 6   Measure Reg1. Suppose that the state |100Mathematical equation is observed with a higher probability 121128Mathematical equation, that is, a=|100=4Mathematical equation, satisfying a21 (mod 15)Mathematical equation.

By Example 1, since the desired a=4Mathematical equation is obtained, we can efficiently compute gcd (a±1,n)=gcd (4±1,15)=(3,5)Mathematical equation on a classical computer, leading to the prime factorization 15=3×5Mathematical equation.

In order to more clearly present all of the different algorithms, Table 4 provides a detailed comparison of several algorithms in terms of the success probability, time complexity, and the number of required quantum bits. In Table 4, 3ϕ(r)/π2rPShor <4ϕ(r)/π2rMathematical equation, and ϕ(r)Mathematical equation is the Euler fuction.

Algorithm 1 inherits the same amplitude amplification property as Grover's search, and its success probability can be made arbitrarily close to 1 after a sufficient number of iterations. Therefore, the success probability of Algorithm 1 is denoted by ≈1 in Table 4.

The idea of Shor's algorithm is surprisingly simple: to factor nMathematical equation, one first computes the order rMathematical equation of an element a Mathematical equation in the multiplicative group n*Mathematical equation , order (a,n)Mathematical equation. If the computed rMathematical equation is even, then one further computes, with high probability, gcd(ar/2±1,n)={p,q}Mathematical equation, with 1<{p,q}<nMathematical equation. Consequently, if a practical quantum computer capable of efficiently executing Shor's algorithm can be built, the security of RSA would be fundamentally compromised. However, up to now there are no yet quantum computers that could run Shor's algorithm for the large semiprimes nMathematical equation currently used in RSA encryption algorithms. Since the simulation of Grover's algorithm has been demonstrated, we propose an alternative algorithm inspired by Grover's algorithm, which aims to compute la(n)Mathematical equation using fewer qubits. In fact, based on Grover's algorithm, one can find an integer rMathematical equation satisfying ar1 (mod n) ,Mathematical equation where the algorithm selects  q' Mathematical equation such that n2q'=2tMathematical equation<2n2Mathematical equation, with a time complexity of O(q')Mathematical equation . That is the algorithm based on Grover's algorithm in Table 4. Whereas in Algorithm 1, we try to find a suitable aMathematical equation such that a2k1 (mod n)Mathematical equation with k1Mathematical equation.The most significant advantage of the algorithm lies in its use of fewer quantum bits. This will facilitate the construction of quantum computers using fewer quantum bits, thereby making practical applications more feasible compared with those systems that require more quantum bits.

Table 4

Comparison of resource consumption among different algorithms

3 Conclusion

In this paper, through some numerical computations and pieces of evidences of suitable aMathematical equation for which la(n)Mathematical equation are small and relatively easy to obtain, in the light of quantum integer factorization, we find that the higher the order, the larger the number of aMathematical equation. Therefore, from another perspective, it inspires us that, instead of trying to find la(n)Mathematical equation, we should attempt to find a suitable aMathematical equation such that a2k1 (mod n)Mathematical equation. Moreover, we propose a quantum algorithm for finding aMathematical equation in a2k1 (mod n)Mathematical equation with k1Mathematical equation based on Grover's search, but using fewer quantum bits. Moreover, the success probability is close to 1. As this type of nMathematical equation is commonly used as an RSA modulus, once such an aMathematical equation is found, the famous and widely used RSA cryptographic system will be broken completely. As a future direction, one could investigate a quantum algorithm for attacking RSA by exploiting lattice-based shortest vector problems, in conjunction with properties of the Euler totient function and techniques that reduce integer factorization to related computational problems.

References

  1. Shor P W. Algorithms for quantum computation: Discrete logarithms and factoring [C]//Proceedings of 35th Annual Symposium on Foundations of Computer Science. New York:IEEE Computer Society Press, 1994:124-134. [Google Scholar]
  2. Shor P W. Polynomial-time algorithms for prime factorization and discrete logarithms on a quantum computer[J]. SIAM Journal on Computing, 1997, 26(5): 1484-1509. [Google Scholar]
  3. Zhang H G, Han W Y, Lai X J, et al. Survey on cyberspace security[J]. Science China Information Sciences, 2024, 58: 1-43. [Google Scholar]
  4. Lenstra A K, Lenstra H W. The development of the number field sieve[C]//Lecture Notes in Mathematics 1554. Berlin:Springer-Verlag, 1993. [Google Scholar]
  5. Battarbee C, Kahrobaei D, Perret L, et al. A subexponential quantum algorithm for the semidirect discrete logarithm problem[C]//Post-Quantum Cryptography. Cham: Springer-Vrverlag, 2024: 202-226. [Google Scholar]
  6. Wu W Q, Zhang H G, Mao S W, et al. A public key cryptosystem based on data complexity under quantum environment[J]. Science China Information Sciences, 2015, 58(11): 1-11. [NASA ADS] [Google Scholar]
  7. Zhang H G, Mao S W, Wu W Q, et al. Overview of quantum computation complexity theory[J]. Chinese Journal of Computers, 2016, 39(12): 2403-2428(Ch). [Google Scholar]
  8. Regev O. An efficient quantum factoring algorithm[J]. Journal of the ACM, 2025, 72(1): 1-13. [Google Scholar]
  9. Biswas S, Das P. Analysis of quantum cryptology and the RSA algorithms defense against attacks using Shor's algorithm in a post quantum environment[M]//Computational Intelligence in Communications and Business Analytics. Cham: Springer-Verlag, 2023: 72-87. [Google Scholar]
  10. Wu W Q, Wu J H, Guo L N. Multi-party quantum private comparison based on bell states[J]. Entropy, 2023, 25(8): 1156. [Google Scholar]
  11. Imran M, Ivanyos G. Efficient quantum algorithms for some instances of the semidirect discrete logarithm problem[J]. Designs, Codes and Cryptography, 2024, 92(10): 2825-2843. [Google Scholar]
  12. Ha J, Lee J, Heo J. Resource analysis of quantum computing with noisy qubits for Shor's factoring algorithms[J]. Quantum Information Processing, 2022, 21(2): 60. [Google Scholar]
  13. Wang C, Wang Q D, Hong C L, et al. Quantum annealing public key cryptographic attack algorithm based on D-wave advantage[J]. Chinese Journal of Computers, 2024, 47(5): 1030-1044(Ch). [Google Scholar]
  14. Wang B N, Yao H N, Hu F, et al. Quantum annealing distributed integer decomposition study of local field coefficient h and coupling coefficient J with stability Ising model[J]. Scientia Sinica: Physica, Mechanica & Astronomica, 2020, 50(3):030301(Ch). [Google Scholar]
  15. Xu N Y, Zhu J, Lu D W, et al. Quantum factorization of 143 on a dipolar-coupling nuclear magnetic resonance system[J]. Physical Review Letters, 2012, 108(13): 130501. [Google Scholar]
  16. Lucero E, Barends R, Chen Y, et al. Computing prime factors with a Josephson phase qubit quantum processor[J]. Nature Physics, 2012, 8(10): 719-723. [Google Scholar]
  17. Monz T, Nigg D, Martinez E A, et al. Realization of a scalable Shor algorithm[J]. Science, 2016, 351(6277): 1068-1070. [Google Scholar]
  18. Kumar M, Mondal B. Study on implementation of Shor's factorization algorithm on quantum computer[J]. SN Computer Science, 2024, 5(4): 413. [Google Scholar]
  19. Cao Z J, Cao Z F, On Shor's factoring algorithm with more registers and the problem to certify quantum computers[EB/OL]. [2014-09-10]. https://arxiv.org/abs/1409.7352. [Google Scholar]
  20. Ekerå M, Håstad J. Quantum algorithms for computing short discrete logarithms and factoring RSA integers[C]//Post-Quantum Cryptography. Cham: Springer International Publishing, 2017: 347-363. [Google Scholar]
  21. Tesoro M, Siloi, Jaschke D, et al. Quantum inspired factorization up to 100-bit RSA number in polynomial time[EB/OL]. [2024-12-12]. https://arxiv.org/abs/2410.16355. [Google Scholar]
  22. Wang Y H, Zhang H G. Quantum algorithm for attacking RSA based on Fourier transform and fixed-point[J]. Wuhan University Journal of Natural Sciences, 2021, 26(6): 489-494. [Google Scholar]
  23. Smolin J A, Smith G, Vargo A. Oversimplifying quantum factoring[J]. Nature, 2013, 499(7457): 163-165. [CrossRef] [PubMed] [Google Scholar]
  24. Xiao L, Luo L, Mateus P. Distributed Shor's algorithm[J]. Quantum Information and Computation, 2022, 23(1&2):27-44. [Google Scholar]
  25. Nielsen M A, Chuang I L. Quantum Computation and Quantum Information[M]. Cambridge: Cambridge University Press, 2000. [Google Scholar]
  26. Liu L H, Cao Z J. On computing Formula and its application[J]. Information and Computation, 2006, 204(7): 1173-1178. [Google Scholar]

All Tables

Table 1

The solutions to a21 (mod n)Mathematical equation for RSA modulus n with known factorization

Table 2

The corresponding aMathematical equation and the number of aMathematical equation for n=221Mathematical equation

Table 3

The corresponding aMathematical equation and the number of aMathematical equation for n=391Mathematical equation

Table 4

Comparison of resource consumption among different algorithms

All Figures

Thumbnail: Fig.1 Refer to the following caption and surrounding text. Fig.1 Simplified flowchart of Shor's algorithm
In the text

Current usage metrics show cumulative count of Article Views (full-text article views including HTML views, PDF and ePub downloads, according to the available data) and Abstracts Views on Vision4Press platform.

Data correspond to usage on the plateform after 2015. The current usage metrics is available 48-96 hours after online publication and is updated daily on week days.

Initial download of the metrics may take a while.