@@ -73,6 +73,7 @@ There are four test suites, three for the original Pearson module, and one
7373more for the wrapper. To run them all, do this:
7474
7575 python setup.py test
76+ tox -e coverage
7677
7778On my 2014 Mac Mini, the combined tests take about 20 seconds to run. On a
78792.4GHz P4 Linux box, they take 81 seconds.
@@ -118,7 +119,8 @@ is to call `s=sk.to_string()`, and then re-create it with
118119` SigningKey.from_string(s, curve) ` . This short form does not record the
119120curve, so you must be sure to tell from_string() the same curve you used for
120121the original key. The short form of a NIST192p-based signing key is just 24
121- bytes long.
122+ bytes long. If the point encoding is invalid or it does not lie on the
123+ specified curve, ` from_string() ` will raise MalformedPointError.
122124
123125 from ecdsa import SigningKey, NIST384p
124126 sk = SigningKey.generate(curve=NIST384p)
@@ -132,7 +134,8 @@ formats that OpenSSL uses. The PEM file looks like the familiar ASCII-armored
132134is a shorter binary form of the same data.
133135` SigningKey.from_pem()/.from_der() ` will undo this serialization. These
134136formats include the curve name, so you do not need to pass in a curve
135- identifier to the deserializer.
137+ identifier to the deserializer. In case the file is malformed ` from_der() `
138+ and ` from_pem() ` will raise UnexpectedDER or MalformedPointError.
136139
137140 from ecdsa import SigningKey, NIST384p
138141 sk = SigningKey.generate(curve=NIST384p)
0 commit comments