Skip to content

Commit 79ff6b1

Browse files
committed
test(eth): transformERC20 clear-signs without AdvancedMode (revert 7.15 workaround)
The firmware now clear-signs transformERC20 at any calldata size (pinned 0x proxy, bounded by displayed amounts) instead of forcing the blind-sign path, so restore the original no-AdvancedMode test. Supersedes the interim AdvancedMode workaround.
1 parent 531756a commit 79ff6b1

1 file changed

Lines changed: 5 additions & 7 deletions

File tree

tests/test_msg_ethereum_erc20_0x_signtx.py

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -164,14 +164,12 @@ def test_sign_longdata_swap(self):
164164
# test transformERC20
165165
def test__sign_transformERC20(self):
166166
self.requires_fullFeature()
167-
# 7.15 behavior change: transformERC20 calldata exceeds the 1024-byte
168-
# initial chunk, so the contract clear-sign handler no longer matches
169-
# (handlers now require the entire calldata in the first chunk). The tx
170-
# goes through the blind-sign path, which requires AdvancedMode. The
171-
# signed bytes -- and therefore the signature below -- are unchanged.
172-
self.requires_firmware("7.15.0")
167+
# transformERC20 is pinned to the 0x ExchangeProxy and bounded by its
168+
# displayed input/min-output amounts, so it clear-signs WITHOUT
169+
# AdvancedMode at any calldata size (the transformations[] tail exceeds
170+
# one chunk). No AdvancedMode policy is set here on purpose.
171+
self.requires_firmware("7.1.5")
173172
self.setup_mnemonic_nopin_nopassphrase()
174-
self.client.apply_policy("AdvancedMode", 1)
175173

176174
sig_v, sig_r, sig_s = self.client.ethereum_sign_tx(
177175
# Data from:

0 commit comments

Comments
 (0)