Module ImportFrom alias TryExcept body ImportFrom alias handlers ExceptHandler type NameLoad body Assign NameStore NameLoad ClassDef bases NameLoad body Pass decorator_list ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam NameParam NameParam defaults body Expr Str Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Return AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Return CompareEq BinOpMod BinOpSub BinOpMult NameLoad NameLoad BinOpAdd BinOpAdd BinOpMult BinOpMult NameLoad NameLoad NameLoad BinOpMult AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr Num decorator_list FunctionDef arguments args NameParam defaults body Return Call AttributeLoad Str attr AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return Call AttributeLoad Str attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list decorator_list ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults NameLoad body Expr Str Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad If BoolOpAnd AttributeLoad NameLoad attr UnaryOpNot Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad body Raise Call NameLoad Call AttributeLoad Str attr NameLoad NameLoad NameLoad If NameLoad body Assert CompareEq BinOpMult NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str If BoolOpAnd CompareEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr CompareEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr CompareEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Return Num orelse Return Num decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str If CompareEq NameLoad NameLoad body Return NameLoad If CompareEq NameLoad NameLoad body Return NameLoad Assert CompareEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr If CompareEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr body If CompareEq BinOpMod BinOpAdd AttributeLoad NameLoad attr AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr Num body Return NameLoad orelse Return Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Assign NameStore BinOpMod BinOpMult BinOpSub AttributeLoad NameLoad attr AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr BinOpSub AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore BinOpMod BinOpSub BinOpSub BinOpMult NameLoad NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad Assign NameStore BinOpMod BinOpSub BinOpMult NameLoad BinOpSub AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr NameLoad Return Call NameLoad AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str FunctionDef arguments args NameParam defaults body Assert CompareGt NameLoad Num Assign NameStore Num While CompareLtE NameLoad NameLoad body Assign NameStore BinOpMult Num NameLoad Return BinOpFloorDiv NameLoad Num decorator_list Assign NameStore NameLoad If AttributeLoad NameLoad attr body Assign NameStore BinOpMod NameLoad AttributeLoad NameLoad attr If CompareEq NameLoad Num body Return NameLoad If CompareEq NameLoad NameLoad body Return NameLoad Assert CompareGt NameLoad Num If NameLoad body Return Call AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore BinOpMult Num NameLoad Assign NameStore Call NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr UnaryOpUSub AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign NameStore BinOpFloorDiv Call NameLoad NameLoad Num Assign NameStore NameLoad While CompareGt NameLoad Num body Assign NameStore Call AttributeLoad NameLoad attr If BoolOpAnd CompareNotEq BinOpBitAnd NameLoad NameLoad Num CompareEq BinOpBitAnd NameLoad NameLoad Num body Assign NameStore BinOpAdd NameLoad NameLoad If BoolOpAnd CompareEq BinOpBitAnd NameLoad NameLoad Num CompareNotEq BinOpBitAnd NameLoad NameLoad Num body Assign NameStore BinOpAdd NameLoad NameLoad Assign NameStore BinOpFloorDiv NameLoad Num Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Return BinOpMult NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Return Call AttributeLoad Str attr AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body If CompareEq NameLoad NameLoad body Return Str Return BinOpMod Str TupleLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str If CompareEq NameLoad NameLoad body Return NameLoad Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Assign NameStore BinOpMod BinOpMult BinOpAdd BinOpMult BinOpMult Num AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad Call AttributeLoad NameLoad attr BinOpMult Num AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore BinOpMod BinOpSub BinOpMult NameLoad NameLoad BinOpMult Num AttributeLoad NameLoad attr NameLoad Assign NameStore BinOpMod BinOpSub BinOpMult NameLoad BinOpSub AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr NameLoad Return Call NameLoad AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Return AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return TupleLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return AttributeLoad NameLoad attr decorator_list decorator_list Assign NameStore Call NameLoad NameLoad NameLoad NameLoad FunctionDef arguments args defaults body ClassDef bases NameLoad body Pass decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam NameParam defaults body Expr Str Assign NameStore Call NameLoad NameLoad NameLoad NameLoad Assign NameStore Call NameLoad NameLoad NameLoad NameLoad Assign NameStore BinOpAdd NameLoad NameLoad Print BinOpMod Str TupleLoad NameLoad NameLoad NameLoad If BoolOpOr CompareNotEq Call AttributeLoad NameLoad attr NameLoad CompareNotEq Call AttributeLoad NameLoad attr NameLoad body Raise Call NameLoad BinOpMod Str TupleLoad NameLoad NameLoad orelse Print Str decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults body Expr Str Assign NameStore Call NameLoad NameLoad NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr Print BinOpMod Str TupleLoad NameLoad NameLoad If BoolOpOr CompareNotEq Call AttributeLoad NameLoad attr NameLoad CompareNotEq Call AttributeLoad NameLoad attr NameLoad body Raise Call NameLoad BinOpMod Str TupleLoad NameLoad NameLoad orelse Print Str decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore NameLoad Assign NameStore Call AttributeLoad NameLoad attr Print BinOpMod Str TupleLoad NameLoad NameLoad If BoolOpOr CompareNotEq Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr CompareNotEq Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr body Raise Call NameLoad BinOpMod Str TupleLoad Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr orelse Print Str decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam defaults body Expr Str Assign NameStore Call NameLoad NameLoad NameLoad NameLoad Assign NameStore BinOpMult NameLoad NameLoad Print BinOpMod Str TupleLoad NameLoad NameLoad NameLoad If BoolOpOr CompareNotEq Call AttributeLoad NameLoad attr NameLoad CompareNotEq Call AttributeLoad NameLoad attr NameLoad body Raise Call NameLoad BinOpMod Str TupleLoad NameLoad NameLoad orelse Print Str decorator_list Assign NameStore Call NameLoad Num Num Num Expr Call NameLoad NameLoad Num Num Num Num Num Num Expr Call NameLoad NameLoad Num Num Num Num Expr Call NameLoad NameLoad Num Num Num Num Num Num Expr Call NameLoad NameLoad Num Num Num Num Num Expr Call NameLoad NameLoad Assign NameStore Call NameLoad NameLoad Num Num Num Assign NameStore NameLoad For NameStore Call NameLoad BinOpAdd Num Num body Assign NameStore BinOpMult BinOpMod NameLoad Num NameLoad Print BinOpMod Str TupleLoad NameLoad NameLoad NameLoad NameLoad If CompareEq NameLoad NameLoad body Print Str orelse Raise Call NameLoad Str Assign NameStore BinOpAdd NameLoad NameLoad Assign NameStore Num Assign NameStore Num Assign NameStore Num Assign NameStore Num Assign NameStore Num Assign NameStore Num Assign NameStore Call NameLoad NameLoad Num NameLoad Assign NameStore Call NameLoad NameLoad NameLoad NameLoad NameLoad Assign NameStore Num Assign NameStore BinOpMult NameLoad NameLoad If CompareNotEq Call AttributeLoad NameLoad attr Num body Raise Call NameLoad Str orelse Print Str Assign NameStore Num Assign NameStore BinOpMult NameLoad NameLoad If BoolOpOr CompareNotEq Call AttributeLoad NameLoad attr Num CompareNotEq Call AttributeLoad NameLoad attr Num body Raise Call NameLoad Str orelse Print Str Assign NameStore Num Assign NameStore Num Assign NameStore BinOpAdd BinOpMult NameLoad NameLoad BinOpMult NameLoad NameLoad If BoolOpOr CompareNotEq Call AttributeLoad NameLoad attr Num CompareNotEq Call AttributeLoad NameLoad attr Num body Raise Call NameLoad Str orelse Print Str decorator_list If CompareEq NameLoad Str body Expr Call NameLoad
N/A N/A numbertheory N/A N/A native.library NATIVE_LIBRARY N/A N/A N/A ImportError N/A N/A NATIVE_LIBRARY None NoSuchPointError N/A ValueError N/A N/A N/A CurveFp N/A object N/A N/A Elliptic Curve over the field of integers modulo a prime. __init__ N/A N/A self p a b N/A N/A N/A The curve of points satisfying y^2 = x^3 + a*x + b (mod p). N/A N/A self __p p N/A N/A self __a a N/A N/A self __b b N/A p N/A N/A self N/A N/A N/A N/A self __p N/A a N/A N/A self N/A N/A N/A N/A self __a N/A b N/A N/A self N/A N/A N/A N/A self __b N/A contains_point N/A N/A self x y N/A N/A N/A Is the point (x,y) on this curve? N/A N/A N/A N/A N/A y y N/A N/A N/A N/A x x x N/A N/A self __a x N/A self __b N/A self __p 0 N/A __repr__ N/A N/A self N/A N/A N/A N/A N/A {}({!r},{!r},{!r}) format N/A N/A self __class__ __name__ N/A self __p N/A self __a N/A self __b N/A __str__ N/A N/A self N/A N/A N/A N/A N/A y^2 = x^3 + {}*x + {} (mod {}) format N/A self __a N/A self __b N/A self __p N/A N/A Point N/A object N/A N/A A point on an elliptic curve. Altering x and y is forbidden,
     but they can be read by the x() and y() methods. __init__ N/A N/A self curve x y order N/A None N/A N/A curve, x, y, order; order (optional) is the order of this point. N/A N/A self __curve curve N/A N/A self __x x N/A N/A self __y y N/A N/A self __order order N/A N/A N/A self __curve N/A N/A N/A N/A self __curve contains_point x y N/A N/A N/A NoSuchPointError N/A N/A ({},{}) is not on the curve {} format x y curve N/A order N/A N/A N/A N/A self order INFINITY N/A __eq__ N/A N/A self other N/A N/A N/A Return 1 if the points are identical, 0 otherwise. N/A N/A N/A N/A self __curve N/A other __curve N/A N/A self __x N/A other __x N/A N/A self __y N/A other __y N/A N/A 1 N/A N/A 0 N/A __add__ N/A N/A self other N/A N/A N/A Add one point to another point. N/A N/A other INFINITY N/A N/A self N/A N/A self INFINITY N/A N/A other N/A N/A N/A self __curve N/A other __curve N/A N/A N/A self __x N/A other __x N/A N/A N/A N/A N/A N/A self __y N/A other __y N/A N/A N/A self __curve p 0 N/A N/A INFINITY N/A N/A N/A N/A self double N/A p N/A N/A N/A self __curve p N/A l N/A N/A N/A N/A other __y N/A self __y N/A N/A numbertheory inverse_mod N/A N/A other __x N/A self __x p p N/A x3 N/A N/A N/A N/A l l N/A self __x N/A other __x p N/A y3 N/A N/A N/A l N/A N/A self __x x3 N/A self __y p N/A N/A Point N/A self __curve x3 y3 N/A __mul__ N/A N/A self other N/A N/A N/A Multiply a point by an integer. leftmost_bit N/A N/A x N/A N/A N/A N/A x 0 N/A result 1 N/A N/A result x N/A N/A result N/A 2 result N/A N/A result 2 N/A N/A e other N/A N/A self __order N/A N/A e N/A e N/A self __order N/A N/A e 0 N/A N/A INFINITY N/A N/A self INFINITY N/A N/A INFINITY N/A N/A e 0 N/A NATIVE_LIBRARY N/A N/A N/A N/A NATIVE_LIBRARY fast_mul self other N/A e3 N/A 3 e N/A negative_self N/A Point N/A self __curve N/A self __x N/A N/A self __y N/A self __order N/A i N/A N/A leftmost_bit e3 2 N/A result self N/A N/A i 1 N/A N/A result N/A N/A result double N/A N/A N/A N/A e3 i 0 N/A N/A e i 0 N/A N/A result N/A result self N/A N/A N/A N/A e3 i 0 N/A N/A e i 0 N/A N/A result N/A result negative_self N/A i N/A i 2 N/A result N/A __rmul__ N/A N/A self other N/A N/A N/A Multiply a point by an integer. N/A N/A self other N/A __repr__ N/A N/A self N/A N/A N/A N/A N/A {}({!r},{!r},{!r},{!r}) format N/A N/A self __class__ __name__ N/A self __curve N/A self __x N/A self __y N/A self __order N/A __str__ N/A N/A self N/A N/A N/A N/A self INFINITY N/A N/A infinity N/A N/A (%d,%d) N/A N/A self __x N/A self __y N/A double N/A N/A self N/A N/A N/A Return a new point that is twice the old. N/A N/A self INFINITY N/A N/A INFINITY N/A p N/A N/A N/A self __curve p N/A a N/A N/A N/A self __curve a N/A l N/A N/A N/A N/A N/A 3 N/A self __x N/A self __x a N/A N/A numbertheory inverse_mod N/A 2 N/A self __y p p N/A x3 N/A N/A N/A l l N/A 2 N/A self __x p N/A y3 N/A N/A N/A l N/A N/A self __x x3 N/A self __y p N/A N/A Point N/A self __curve x3 y3 N/A x N/A N/A self N/A N/A N/A N/A self __x N/A y N/A N/A self N/A N/A N/A N/A self __y N/A pair N/A N/A self N/A N/A N/A N/A N/A self __x N/A self __y N/A curve N/A N/A self N/A N/A N/A N/A self __curve N/A order N/A N/A self N/A N/A N/A N/A self __order N/A N/A N/A INFINITY N/A Point None None None __main__ N/A N/A N/A N/A FailedTest N/A Exception N/A N/A N/A test_add N/A N/A c x1 y1 x2 y2 x3 y3 N/A N/A N/A We expect that on curve c, (x1,y1) + (x2, y2 ) = (x3, y3). N/A p1 N/A Point c x1 y1 N/A p2 N/A Point c x2 y2 N/A p3 N/A p1 p2 N/A N/A %s + %s = %s N/A p1 p2 p3 N/A N/A N/A N/A N/A p3 x x3 N/A N/A N/A p3 y y3 N/A N/A N/A FailedTest N/A Failure: should give (%d,%d). N/A x3 y3 N/A N/A  Good. N/A test_double N/A N/A c x1 y1 x3 y3 N/A N/A N/A We expect that on curve c, 2*(x1,y1) = (x3, y3). N/A p1 N/A Point c x1 y1 N/A p3 N/A N/A p1 double N/A N/A %s doubled = %s N/A p1 p3 N/A N/A N/A N/A N/A p3 x x3 N/A N/A N/A p3 y y3 N/A N/A N/A FailedTest N/A Failure: should give (%d,%d). N/A x3 y3 N/A N/A  Good. N/A test_double_infinity N/A N/A c N/A N/A N/A We expect that on curve c, 2*INFINITY = INFINITY. N/A p1 INFINITY N/A p3 N/A N/A p1 double N/A N/A %s doubled = %s N/A p1 p3 N/A N/A N/A N/A N/A p3 x N/A N/A INFINITY x N/A N/A N/A p3 y N/A N/A INFINITY y N/A N/A N/A FailedTest N/A Failure: should give (%d,%d). N/A N/A N/A INFINITY x N/A N/A INFINITY y N/A N/A  Good. N/A test_multiply N/A N/A c x1 y1 m x3 y3 N/A N/A N/A We expect that on curve c, m*(x1,y1) = (x3,y3). N/A p1 N/A Point c x1 y1 N/A p3 N/A p1 m N/A N/A %s * %d = %s N/A p1 m p3 N/A N/A N/A N/A N/A p3 x x3 N/A N/A N/A p3 y y3 N/A N/A N/A FailedTest N/A Failure: should give (%d,%d). N/A x3 y3 N/A N/A  Good. N/A N/A c N/A CurveFp 23 1 1 N/A N/A test_add c 3 10 9 7 17 20 N/A N/A test_double c 3 10 7 12 N/A N/A test_add c 3 10 3 10 7 12 N/A N/A test_multiply c 3 10 2 7 12 N/A N/A test_double_infinity c N/A g N/A Point c 13 7 7 N/A check INFINITY N/A i N/A range N/A 7 1 N/A N/A p N/A N/A i 7 g N/A N/A %s * %d = %s, expected %s . . . N/A g i p check N/A N/A p check N/A N/A  Good. N/A N/A N/A FailedTest Bad. N/A check N/A check g N/A p 6277101735386680763835789423207666416083908700390324961279 N/A r 6277101735386680763835789423176059013767194773182842284081 N/A c 1191689908718309326471930603292001425137626342642504031845 N/A b 2455155546008943817740293915197451784769108058161191238065 N/A Gx 602046282375688656758213480587526111916698976636884684818 N/A Gy 174050332293622031404857552280219410364023488927386650641 N/A c192 N/A CurveFp p -3 b N/A p192 N/A Point c192 Gx Gy r N/A d 651056770906015076056810763456358567190100156695615665659 N/A Q N/A d p192 N/A N/A N/A N/A Q x 2419923217401292748504953371159479209793178847833016309413 N/A N/A N/A FailedTest p192 * d came out wrong. N/A N/A p192 * d came out right. N/A k 6140507067065001063065065565667405560006161556565665656654 N/A R N/A k p192 N/A N/A N/A N/A N/A R x 3342403536405981729393488334694600415596881826869351677613 N/A N/A N/A R y 3849051909973213559292901169586614769114867258435646249013 N/A N/A N/A FailedTest k * p192 came out wrong. N/A N/A k * p192 came out right. N/A u1 2563697409189434185194736134579731015366492496392189760599 N/A u2 6266643813348617967186477710235785849136406323338782220568 N/A temp N/A N/A u1 p192 N/A u2 Q N/A N/A N/A N/A N/A temp x 3342403536405981729393488334694600415596881826869351677613 N/A N/A N/A temp y 3849051909973213559292901169586614769114867258435646249013 N/A N/A N/A FailedTest u1 * p192 + u2 * Q came out wrong. N/A N/A u1 * p192 + u2 * Q came out right. N/A N/A N/A __name__ __main__ N/A N/A N/A __main__