Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

secp256k1 data: tweak formatting for consistency

  • Loading branch information...
commit f50eecd8be2b53bc98a2343d1df9ae336ed11825 1 parent 4c5b45f
@warner authored
Showing with 6 additions and 5 deletions.
  1. +3 −2 ecdsa/curves.py
  2. +3 −3 ecdsa/ecdsa.py
View
5 ecdsa/curves.py
@@ -29,8 +29,9 @@ def __init__(self, name, curve, generator, oid):
(1, 3, 132, 0, 34))
NIST521p = Curve("NIST521p", ecdsa.curve_521, ecdsa.generator_521,
(1, 3, 132, 0, 35))
-SECP256k1 = Curve("SECP256k1", ecdsa.curve_secp256k1,
- ecdsa.generator_secp256k1, (1, 3, 132, 0, 10))
+SECP256k1 = Curve("SECP256k1",
+ ecdsa.curve_secp256k1, ecdsa.generator_secp256k1,
+ (1, 3, 132, 0, 10))
curves = [NIST192p, NIST224p, NIST256p, NIST384p, NIST521p, SECP256k1]
View
6 ecdsa/ecdsa.py
@@ -264,10 +264,10 @@ def point_is_valid( generator, x, y ):
# Certicom secp256-k1
_a = 0x0000000000000000000000000000000000000000000000000000000000000000L
_b = 0x0000000000000000000000000000000000000000000000000000000000000007L
-_p = 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFC2FL
-_Gx = 0x79BE667EF9DCBBAC55A06295CE870B07029BFCDB2DCE28D959F2815B16F81798L
+_p = 0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2fL
+_Gx = 0x79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798L
_Gy = 0x483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8L
-_r = 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141L
+_r = 0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141L
curve_secp256k1 = ellipticcurve.CurveFp( _p, _a, _b)
generator_secp256k1 = ellipticcurve.Point( curve_secp256k1, _Gx, _Gy, _r)
Please sign in to comment.
Something went wrong with that request. Please try again.