starkbank/ecdsa-python

Random number generator used by default is Not Secure

sirk390 opened this issue · 3 comments

It seems the random number generator used by default when generating a private key is not secure:
When you call:
>privateKey = PrivateKey()
It does
randint(1, curve.N - 1)
While "randint" is imported from "random" module.
Instead random should use " random.SystemRandom"

Yes, this is good, but you have also the same issue for signature (ecdsa.py line 14).

True. I updated the PR, I will close this issue now.