funga/crypto_dev_signer/eth/encoding.py

6 lines
148 B
Python
Raw Normal View History

2021-04-12 19:09:11 +02:00
ethereum_recid_modifier = 35
def chain_id_to_v(chain_id, signature):
v = signature[64]
return (chain_id * 2) + ethereum_recid_modifier + v