From dda9e5b327389be6d48da2f60eb97fcd81aefcbc Mon Sep 17 00:00:00 2001 From: Brian Warner Date: Thu, 21 Jan 2016 16:57:20 -0800 Subject: CurveFp needs __str__ now --- ecdsa/ellipticcurve.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'ecdsa/ellipticcurve.py') diff --git a/ecdsa/ellipticcurve.py b/ecdsa/ellipticcurve.py index c83088f..0739807 100644 --- a/ecdsa/ellipticcurve.py +++ b/ecdsa/ellipticcurve.py @@ -59,6 +59,8 @@ class CurveFp(object): """Is the point (x,y) on this curve?""" return (y * y - (x * x * x + self.__a * x + self.__b)) % self.__p == 0 + def __str__(self): + return "CurveFp(p=%d, a=%d, b=%d)" % (self.__p, self.__a, self.__b) class Point(object): """A point on an elliptic curve. Altering x and y is forbidding, -- cgit v1.2.1