Skip to main content
typo
Source Link
kelalaka
  • 49.5k
  • 12
  • 118
  • 205
Thoug the question not clear, now, have an update.
Source Link
kelalaka
  • 49.5k
  • 12
  • 118
  • 205

For the inverse you need to solveinverting the discrete logarithm problem; namelyprivate key from public key, given $P = [x]G$ overwe have a prime curve $E$ with the generatorwell defined problem; $G$the discrete logarithm problem; namely, find $x$.

  • given $P$ over a prime curve $E(\mathbb{F}_p)$ with the generator $G$, find $x$ such that $P= [x]G$ .

There are many works for speeding the discrete logarithm, currentlylogarithm;

Currently best achievement arefor Secp256k1 is performed with Pollard's Rho and this is based on the on the Floyd's cycle-finding algorithmparallel Pollard's kangaroo. Best record can achieve 112-bit.

If you where to run the script and input a private key it will print the points calculated in the process of deriving the public key. Now take any of the calculated points (𝑅π‘₯,𝑅𝑦) and indicate([2] or [1]) if it was derived using point doubling or point addition formula and I'll reverse the calculation the give you the value of 𝑄π‘₯ and 𝑄𝑦 that was used in deriving the new points 𝑅π‘₯ 𝑅𝑦 (Deleted comment)

The obtaining the public key from the private key $k$ fromand base point $G$ is calculated as $P = [k]G$ that, this is scalar multiplication and means add $G$ itself $k$-times ( consider integer value of $k$).

$$[k]G : = \underbrace{G + G + \cdots + G}_{k-times}$$

This is a very long method and we performhave better alternatives like double-and-add method*; ( if $k$ is integer than it takes roughly $\lfloor \log_2{k}\rfloor+1 $-time.)

Now, this speeds up the calculation, and notice that it is depending on the value of bits of the $k$.

There is always doubling, however, there can be point addition only if the current bit value of $k$ is 1Actually, this is not good since can cause side channel attacks. So, for every bit of the key, there is no test value for the reversing, so you need toWe use a tree structuredouble-and-add method to follow the the cases. Do you see where is is going? In the final you will have $2^{n}$ where $n$ is the number of bits of $k$, possible values ondemonstrate the treeproblem. Notice two points;

  1. YouThere is always doubling
  2. There can be point addition only if the current bit value of $k$ is 1.

So, for every bit of the key;

  • we may return back to either only doubled case or added and doubled case.

  • There is no test value for the reversing, i.e. how to determine that it was only double or add-and-double.

  • So one needs to use a tree structure to follow the the cases. Can we see where is is going?

  • For every step, we need to branch and this is exactly, two branch.

  • In the final, the tree will have depth $n$ where $n$ is the number of bits of $k$, possible values on the tree and $2^n$ leaves.

  • This is exactly same as the number of the bits of the key that needed to determine.

Now, one faces two problems;

  1. One cannot store such tree since you need around $2^{256}$ storage for Secp256k1, and
  2. YouOne cannot compute such tree since you need reach $2^{256}$ computing power for Secp256k1. The best available one, the bitcoin miners can reach $2^{93}$ in a year, so you still need $2^{163}$ year to achieve this.

For the inverse you need to solve the discrete logarithm problem; namely, given $P = [x]G$ over a prime curve $E$ with the generator $G$, find $x$.

There are many works for speeding the discrete logarithm, currently best achievement are performed with Pollard's Rho and this is based on the on the Floyd's cycle-finding algorithm Best record can achieve 112-bit.

If you where to run the script and input a private key it will print the points calculated in the process of deriving the public key. Now take any of the calculated points (𝑅π‘₯,𝑅𝑦) and indicate([2] or [1]) if it was derived using point doubling or point addition formula and I'll reverse the calculation the give you the value of 𝑄π‘₯ and 𝑄𝑦 that was used in deriving the new points 𝑅π‘₯ 𝑅𝑦

The obtaining the private key $k$ from base point $G$ is calculated as $P = [k]G$ that is scalar multiplication and means add $G$ itself $k$-times ( consider integer value of $k$). This is a long method and we perform double-and-add method*;

Now, this speeds up the calculation, and notice that it is depending on the value of bits of the $k$.

There is always doubling, however, there can be point addition only if the current bit value of $k$ is 1. So, for every bit of the key, there is no test value for the reversing, so you need to use a tree structure to follow the the cases. Do you see where is is going? In the final you will have $2^{n}$ where $n$ is the number of bits of $k$, possible values on the tree.

  1. You cannot store such tree since you need around $2^{256}$ storage
  2. You cannot compute such tree since you need reach $2^{256}$ computing power.

For the inverting the private key from public key, we have a well defined problem; the discrete logarithm problem; namely,

  • given $P$ over a prime curve $E(\mathbb{F}_p)$ with the generator $G$, find $x$ such that $P= [x]G$ .

There are many works for speeding the discrete logarithm;

Currently best achievement for Secp256k1 is performed with parallel Pollard's kangaroo. Best record can achieve 112-bit.

If you where to run the script and input a private key it will print the points calculated in the process of deriving the public key. Now take any of the calculated points (𝑅π‘₯,𝑅𝑦) and indicate([2] or [1]) if it was derived using point doubling or point addition formula and I'll reverse the calculation the give you the value of 𝑄π‘₯ and 𝑄𝑦 that was used in deriving the new points 𝑅π‘₯ 𝑅𝑦 (Deleted comment)

The obtaining the public key from the private key $k$ and base point $G$ is calculated as $P = [k]G$, this is scalar multiplication and means add $G$ itself $k$-times ( consider integer value of $k$).

$$[k]G : = \underbrace{G + G + \cdots + G}_{k-times}$$

This is a very long method and we have better alternatives like double-and-add method* ( if $k$ is integer than it takes roughly $\lfloor \log_2{k}\rfloor+1 $-time.)

Now, this speeds up the calculation, and notice that it is depending on the value of bits of the $k$. Actually, this is not good since can cause side channel attacks. We use double-and-add method to demonstrate the problem. Notice two points;

  1. There is always doubling
  2. There can be point addition only if the current bit value of $k$ is 1.

So, for every bit of the key;

  • we may return back to either only doubled case or added and doubled case.

  • There is no test value for the reversing, i.e. how to determine that it was only double or add-and-double.

  • So one needs to use a tree structure to follow the the cases. Can we see where is is going?

  • For every step, we need to branch and this is exactly, two branch.

  • In the final, the tree will have depth $n$ where $n$ is the number of bits of $k$, possible values on the tree and $2^n$ leaves.

  • This is exactly same as the number of the bits of the key that needed to determine.

Now, one faces two problems;

  1. One cannot store such tree since you need around $2^{256}$ storage for Secp256k1, and
  2. One cannot compute such tree since you need reach $2^{256}$ computing power for Secp256k1. The best available one, the bitcoin miners can reach $2^{93}$ in a year, so you still need $2^{163}$ year to achieve this.
Post Undeleted by kelalaka
Post Deleted by kelalaka
polish
Source Link
kelalaka
  • 49.5k
  • 12
  • 118
  • 205

For the inverse you need to solve the discrete logarithm problem; namely, given $P = [x]G$ over a prime curve $E$ witwith the generator $G$, find $x$.

There are many works for speeding the discrete logarithm, currently best achievement are performed with Pollard's Rho and this is based on the on the Floyd's cycle-finding algorithm Best record can achieve 112-bit.

If you where to run the script and input a private key it will print the points calculated in the process of deriving the public key. Now take any of the calculated points (𝑅π‘₯,𝑅𝑦) and indicate([2] or [1]) if it was derived using point doubling or point addition formula and I'll reverse the calculation the give you the value of 𝑄π‘₯ and 𝑄𝑦 that was used in deriving the new points 𝑅π‘₯ 𝑅𝑦

The obtaining the private key $k$ from base point $G$ is calculated as $P = [k]G$ that is scalar multiplication and means add $G$ itself $k$-times ( consider integer value of $k$). This is a long method and we perform double-and-add method*;

let bits = bit_representation(s) # the vector of bits (from LSB to MSB) representing s
let temp = P # track doubled P val
for bit in bits: 
    if bit == 1:            
        res = res + temp # point add
    temp = temp + temp # double
return res

Now, this speeds up the calculation, and notice that it is depending on the value of bits of the $k$.

There is always doubling, however, there can be point addition only if the current bit value of $k$ is 1. So, for every bit of the key, there is no test value for the reversing, so you need to use a tree structure to follow the the cases. Do you see where is is going? In the final you will have $2^{n}$ where $n$ is the number of bits of $k$, possible values on the tree.

  1. You cannot store such tree since you need around $2^{256}$ storage
  2. You cannot compute such tree since you need reach $2^{256}$ computing power.

Well, on the other hand Pollard's $\rho$ has complexity around $\mathcal{O}\sqrt{p}$$\mathcal{O}(\sqrt{p})$, where $p$ is the size of the group generated by the $G$. whichThis is far better than above.


*Similar arguments can make for the Montgomery and Joyce ladder, too.

For the inverse you need to solve the discrete logarithm problem; namely, given $P = [x]G$ over a prime curve $E$ wit the generator $G$, find $x$.

There are many works for speeding the discrete logarithm, currently best achievement are performed with Pollard's Rho and this is based on the on the Floyd's cycle-finding algorithm Best record can achieve 112-bit.

If you where to run the script and input a private key it will print the points calculated in the process of deriving the public key. Now take any of the calculated points (𝑅π‘₯,𝑅𝑦) and indicate([2] or [1]) if it was derived using point doubling or point addition formula and I'll reverse the calculation the give you the value of 𝑄π‘₯ and 𝑄𝑦 that was used in deriving the new points 𝑅π‘₯ 𝑅𝑦

The obtaining the private key $k$ from base point $G$ is calculated as $P = [k]G$ that is scalar multiplication and means add $G$ itself $k$-times ( consider integer value of $k$). This is a long method and we perform double-and-add method*;

let bits = bit_representation(s) # the vector of bits (from LSB to MSB) representing s
let temp = P # track doubled P val
for bit in bits: 
    if bit == 1:            
        res = res + temp # point add
    temp = temp + temp # double
return res

Now, this speeds up the calculation, and notice that it is depending on the value of bits of the $k$.

There is always doubling, however, there can be point addition only if the current bit value of $k$ is 1. So, for every bit of the key, there is no test value for the reversing, so you need to use a tree structure to follow the the cases. Do you see where is is going? In the final you will have $2^{n}$ where $n$ is the number of bits of $k$, possible values on the tree.

  1. You cannot store such tree since you need around $2^{256}$ storage
  2. You cannot compute such tree since you need reach $2^{256}$ computing power.

Well, on the other hand Pollard's $\rho$ has complexity around $\mathcal{O}\sqrt{p}$. which is far better than above.


*Similar arguments can make for the Montgomery and Joyce ladder, too.

For the inverse you need to solve the discrete logarithm problem; namely, given $P = [x]G$ over a prime curve $E$ with the generator $G$, find $x$.

There are many works for speeding the discrete logarithm, currently best achievement are performed with Pollard's Rho and this is based on the on the Floyd's cycle-finding algorithm Best record can achieve 112-bit.

If you where to run the script and input a private key it will print the points calculated in the process of deriving the public key. Now take any of the calculated points (𝑅π‘₯,𝑅𝑦) and indicate([2] or [1]) if it was derived using point doubling or point addition formula and I'll reverse the calculation the give you the value of 𝑄π‘₯ and 𝑄𝑦 that was used in deriving the new points 𝑅π‘₯ 𝑅𝑦

The obtaining the private key $k$ from base point $G$ is calculated as $P = [k]G$ that is scalar multiplication and means add $G$ itself $k$-times ( consider integer value of $k$). This is a long method and we perform double-and-add method*;

let bits = bit_representation(s) # the vector of bits (from LSB to MSB) representing s
let temp = P # track doubled P val
for bit in bits: 
    if bit == 1:            
        res = res + temp # point add
    temp = temp + temp # double
return res

Now, this speeds up the calculation, and notice that it is depending on the value of bits of the $k$.

There is always doubling, however, there can be point addition only if the current bit value of $k$ is 1. So, for every bit of the key, there is no test value for the reversing, so you need to use a tree structure to follow the the cases. Do you see where is is going? In the final you will have $2^{n}$ where $n$ is the number of bits of $k$, possible values on the tree.

  1. You cannot store such tree since you need around $2^{256}$ storage
  2. You cannot compute such tree since you need reach $2^{256}$ computing power.

Well, on the other hand Pollard's $\rho$ has complexity around $\mathcal{O}(\sqrt{p})$, where $p$ is the size of the group generated by the $G$. This is far better than above.


*Similar arguments can make for the Montgomery and Joyce ladder, too.

added 308 characters in body
Source Link
kelalaka
  • 49.5k
  • 12
  • 118
  • 205
Loading
Source Link
kelalaka
  • 49.5k
  • 12
  • 118
  • 205
Loading