Added the RLP weakness workaround in client

This commit is contained in:
Alexandre Paillier
2023-11-20 18:00:33 +01:00
parent 8bab762147
commit bd41a1460d
2 changed files with 14 additions and 4 deletions

View File

@@ -109,7 +109,7 @@ class EthAppClient:
suffix = [int(tx_params["chainId"]), bytes(), bytes()]
decoded = rlp.decode(tx)[:-3] # remove already computed signature
tx = prefix + rlp.encode(decoded + suffix)
chunks = self._cmd_builder.sign(bip32_path, tx)
chunks = self._cmd_builder.sign(bip32_path, tx, suffix)
for chunk in chunks[:-1]:
with self._send(chunk):
pass