Commit graph

8 commits

Author SHA1 Message Date
SomberNight
bc0036297b fast hmac on python 3.7+ 2018-06-28 19:55:54 +02:00
SomberNight
59c1d03f01
ecc.py: properly handle point at infinity 2018-06-16 06:34:03 +02:00
SomberNight
7ebff5616e
ecc.py: _MyVerifyingKey.from_signature is raising low level exception
Traceback (most recent call last):
  File "...\electrum\gui\qt\util.py", line 645, in run
    result = task.task()
  File "...\electrum\lib\wallet.py", line 1500, in sign_transaction
    k.sign_transaction(tx, password)
  File "...\electrum\plugins\keepkey\keepkey.py", line 67, in sign_transaction
    self.plugin.sign_transaction(self, tx, prev_tx, xpub_path)
  File "...\electrum\plugins\keepkey\keepkey.py", line 263, in sign_transaction
    tx.update_signatures(signatures)
  File "...\electrum\lib\transaction.py", line 667, in update_signatures
    public_key = ecc.ECPubkey.from_sig_string(sig_string, recid, pre_hash)
  File "...\electrum\lib\ecc.py", line 180, in from_sig_string
    ecdsa_verifying_key = _MyVerifyingKey.from_signature(sig_string, recid, msg_hash, curve=SECP256k1)
  File "...\electrum\lib\ecc.py", line 152, in from_signature
    Q = inv_r * ( s * R + minus_e * G )
  File "...\Python\Python36-32\lib\site-packages\ecdsa\ellipticcurve.py", line 143, in __rmul__
    return self * other
  File "...\electrum\lib\ecc_fast.py", line 120, in mul
    public_pair_bytes = b'\4' + self.x().to_bytes(32, byteorder="big") + self.y().to_bytes(32, byteorder="big")
OverflowError: int too big to convert
2018-06-14 20:14:38 +02:00
SomberNight
facb7bbc0e
ecc: (minor) use ECPubkey.from_point 2018-05-27 03:55:10 +02:00
SomberNight
ac94d6d055
ecc: ECPrivkey.sign clean-up 2018-05-26 19:26:13 +02:00
SomberNight
dc1d6ac1fe
avoid hardcoding the curve generator ourselves 2018-05-25 18:29:44 +02:00
SomberNight
7c53712750
load_library: remove ctypes.util.find_library calls. remove some code dupe
find_library was giving priority to system dll against local dll
2018-05-25 18:20:56 +02:00
SomberNight
16e4827e8c
use libsecp256k1 if available. abstract away ecc stuff. move symmetric crypto and hash functions to crypto.py 2018-05-25 15:43:06 +02:00