Created
September 16, 2019 10:54
Solve DLP on Elliptic Curves.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Curve parameters | |
p = 1048583 | |
a, b = 1, -1 | |
# Target secret key | |
d = 4121 | |
# Setup curve | |
E = EllipticCurve(GF(p), [a, b]) | |
G = E.gen(0) | |
P = d * G # (429940 : 231132 : 1) | |
dl = discrete_log(P, G, G.order(), operation='+') | |
assert dl == d |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment