mirror of
https://github.com/trezor/trezor-firmware.git
synced 2025-01-10 23:40:58 +00:00
ethereum: fix get_address for very short paths
This commit is contained in:
parent
28455a8789
commit
2f6386e041
@ -17,7 +17,10 @@ async def ethereum_get_address(ctx, msg):
|
|||||||
address = sha3_256(public_key[1:]).digest(True)[12:] # Keccak
|
address = sha3_256(public_key[1:]).digest(True)[12:] # Keccak
|
||||||
|
|
||||||
if msg.show_display:
|
if msg.show_display:
|
||||||
network = networks.by_slip44(address_n[1] & 0x7fffffff)
|
if len(address_n) > 1: # path has slip44 network identifier
|
||||||
|
network = networks.by_slip44(address_n[1] & 0x7fffffff)
|
||||||
|
else:
|
||||||
|
network = None
|
||||||
hex_addr = _ethereum_address_hex(address, network)
|
hex_addr = _ethereum_address_hex(address, network)
|
||||||
|
|
||||||
while True:
|
while True:
|
||||||
|
Loading…
Reference in New Issue
Block a user