funga

Signer and keystore daemon and library for cryptocurrency software development
Log | Files | Refs | README | LICENSE

commit 5ac0272e5c98f1893cf7913683933bffae0cb8b7
parent 441ace5ec40091d49cc524ef5839d057046df8b1
Author: nolash <dev@holbrook.no>
Date:   Mon,  6 Sep 2021 16:28:57 +0200

Revert "Remove rlp from signer method names"

This reverts commit af7a16aa3269f98fb91819f0a533fd1bd97407bf.

Diffstat:
Mcrypto_dev_signer/eth/signer/defaultsigner.py | 13+++----------
1 file changed, 3 insertions(+), 10 deletions(-)

diff --git a/crypto_dev_signer/eth/signer/defaultsigner.py b/crypto_dev_signer/eth/signer/defaultsigner.py @@ -40,18 +40,15 @@ class ReferenceSigner(Signer): return z - def sign_transaction_to_wire(self, tx, password=None): + def sign_transaction_to_rlp(self, tx, password=None): chain_id = int.from_bytes(tx.v, byteorder='big') sig = self.sign_transaction(tx, password) tx.apply_signature(chain_id, sig) return tx.rlp_serialize() - def sign_transaction_to_rlp(self, tx, password=None): - return self.sign_transaction_to_wire(tx, password=password) - - - def sign_message(self, address, message, password=None): + def sign_ethereum_message(self, address, message, password=None): + #k = keys.PrivateKey(self.keyGetter.get(address, password)) #z = keys.ecdsa_sign(message_hash=g, private_key=k) if type(message).__name__ == 'str': @@ -74,10 +71,6 @@ class ReferenceSigner(Signer): return z - def sign_ethereum_message(self, address, message, password=None): - return self.sign_message(address, message, password=None) - - # TODO: generic sign should be moved to non-eth context def sign_pure(self, address, message, password=None): pk = coincurve.PrivateKey(secret=self.keyGetter.get(address, password))