Research Article

An Efficient Collision Detection Method for Computing Discrete Logarithms with Pollard's Rho

Algorithm 2

Experiments for distinguished point method and the new algorithm.
Input: Iteration function 𝐹 ∢ 𝐺 β†’ 𝐺
Output: The average ratio √ ( n u m b e r o f s t e p s ) / 𝑛 ∢ 𝑅 𝑖 1 and 𝑅 𝑖 2 for distinguished point method and the new algorithm, respectively
(1) for 𝑖 = 3 1 to 36  do
(2)  for 𝑗 = 1 to 20  do
(3)   repeat
(4)    Choose a random prime number π‘ž ∈ [ 2 𝑖 + 1 , 2 𝑖 + 3 ]
(5)    Choose two random numbers π‘Ž , 𝑏 ∈ 𝔽 q, where 4 π‘Ž 3 + 2 7 𝑏 2 β‰  0
(6)    𝑛 ← the largest prime factor of # 𝐸 π‘Ž , 𝑏
(7)   until 2 𝑖 ≀ 𝑛 ≀ 2 𝑖 + 1
(8)   Choose a random point π‘Š ∈ 𝐸 π‘Ž , 𝑏 , where the order of π‘Š equal to # 𝐸 π‘Ž , 𝑏
(9)    𝑃 ← ( # 𝐸 π‘Ž , 𝑏 / 𝑛 ) βˆ— π‘Š (the generator of 𝐺 )
(10)   for 𝑙 = 1 to 3 2 0 0 / 2 𝑖 βˆ’ 3 1   do
(11)    Choose a random number 𝑐 ∈ [ 0 , 𝑛 βˆ’ 1 ] , 𝑄 ← 𝑐 βˆ— 𝑃
(12)    Choose a random point in 𝐺 be the initial point π‘Œ 0
(13)     π‘˜ ← 1
(14)    repeat
(15)      π‘Œ π‘˜ ← 𝐹 ( π‘Œ π‘˜ βˆ’ 1 )
(16)     Check whether the Hamming weight of π‘Œ π‘˜ less than certain value
(17)     Check whether the π‘₯ -coordinate of π‘Œ π‘˜ is a minimum value
(18)     if there is a match among distinguished points  then
(19)       π‘˜ 1 ← π‘˜
(20)     end if
(21)     if there is a match among minimum values  then
(22)       π‘˜ 2 ← π‘˜
(23)     end if
(24)    until  Both of two methods have found the match
(25)     𝑅 𝑙 1 ← π‘˜ 1 / √ 𝑛 for distinguished point method
(26)     𝑅 𝑙 2 ← π‘˜ 2 / √ 𝑛 for the new algorithm
(27)    end for
(28)    𝑅 𝑗 1 βˆ‘ 𝑅 ← ( 𝑙 1 ) / 3 2 0 0 / 2 𝑖 βˆ’ 3 1 for distinguished point method
(29)    𝑅 𝑗 2 βˆ‘ 𝑅 ← ( 𝑙 2 ) / 3 2 0 0 / 2 𝑖 βˆ’ 3 1 for the new algorithm
(30)  end for
(31)   𝑅 𝑖 1 βˆ‘ 𝑅 ← ( 𝑗 1 ) / 2 0 for distinguished point method
(32)  𝑅 𝑖 2 βˆ‘ 𝑅 ← ( 𝑗 2 ) / 2 0 for the new algorithm
(33) end for