Path: blob/master/Discrete-Logarithm-Problem/Elliptic-Curve-DLP/Algo-Pollard-Rho/README.md
2142 views
Pollard Rho Algorithm for solving ECDLP
Prerequisites:
Pollard Rho Algorithm for solving ECDLP will give a unique solution in cases where order of the group, over which the DLP is defined, is a prime number. Otherwise, it can give multiple solutions.
To find any two pairs
&
such that

Once we have these pairs, we can write:

Let base point P have order = n. Then we can write:
, provided GCD((B-b), n) == 1
But the problem is, how do we calculate (a, b) and (B, b)?
Brute Forcing such pairs will be of the order
which is even larger than the brute force algorithm for solving ECDLP:
.
We can use Floyd's Cycle Finding Algorithm to reduce the complexity! Have a look at how the Cycle Finding algorithm can be efficiently used to solve ECDLP:
Basically, the algorithm is
Initially select any integral values for the two pairs
, 
Keep calculating
and
,
until 
Check if
,If true, then start again from (1)
If false, then return
as x
How to calculate
,
, 



Note: Since
is a point and not an integer, we simply partition using x-coordinate of 
We can conclude from the above formula that the value of
depends upon the set (S_1, S_2, S_3) to which
belongs.
Now, we need to calculate values of
and
. Both of them will also depend upon the set(S_1, S_2, S_3) to which X_i belongs.
I implemented the algorithm in python/sage (with appropriate comments/explanation) here: pollardrho.py
