diff --git a/Makefile b/Makefile index 870e1ba2..ea4bf7d2 100644 --- a/Makefile +++ b/Makefile @@ -47,7 +47,7 @@ PATH_APP_LOAD_PARAMS = "" # Application version APPVERSION_M = 1 APPVERSION_N = 1 -APPVERSION_P = 4 +APPVERSION_P = 5 APPVERSION_SUFFIX = # if not empty, appended at the end. Do not add a dash. ifeq ($(APPVERSION_SUFFIX),) diff --git a/src/handler/withdraw.c b/src/handler/withdraw.c index 80d9ba24..798e7f77 100644 --- a/src/handler/withdraw.c +++ b/src/handler/withdraw.c @@ -60,14 +60,16 @@ static unsigned char const BSM_SIGN_MAGIC[] = {'\x18', 'B', 'i', 't', 'c', 'o', #error "COIN_VARIANT is not defined" #elif COIN_VARIANT == COIN_VARIANT_ACRE // Mainnet hash +// Mainnet Chain ID - 1 (0x01) static const uint8_t abi_encoded_chain_id[32] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01}; #elif COIN_VARIANT == COIN_VARIANT_ACRE_TESTNET // Testnet hash +// Sepolia Chain ID - 11155111 (0xaa36a7) static const uint8_t abi_encoded_chain_id[32] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x05, 0x77}; + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xaa, 0x36, 0xa7}; #else #error "Unsupported COIN_VARIANT value" #endif @@ -823,4 +825,4 @@ void handler_withdraw(dispatcher_context_t* dc, uint8_t protocol_version) { PRINTF("Error in ui_post_processing_confirm_withdraw"); } return; -} \ No newline at end of file +} diff --git a/tests/snapshots/flex/test_dashboard/00001.png b/tests/snapshots/flex/test_dashboard/00001.png index c3851fb5..db38aea5 100644 Binary files a/tests/snapshots/flex/test_dashboard/00001.png and b/tests/snapshots/flex/test_dashboard/00001.png differ diff --git a/tests/snapshots/nanosp/test_dashboard/00001.png b/tests/snapshots/nanosp/test_dashboard/00001.png index 6a2052be..b2cd426e 100644 Binary files a/tests/snapshots/nanosp/test_dashboard/00001.png and b/tests/snapshots/nanosp/test_dashboard/00001.png differ diff --git a/tests/snapshots/nanox/test_dashboard/00001.png b/tests/snapshots/nanox/test_dashboard/00001.png index 6a2052be..b2cd426e 100644 Binary files a/tests/snapshots/nanox/test_dashboard/00001.png and b/tests/snapshots/nanox/test_dashboard/00001.png differ diff --git a/tests/snapshots/stax/test_dashboard/00001.png b/tests/snapshots/stax/test_dashboard/00001.png index 280404f9..06431dec 100644 Binary files a/tests/snapshots/stax/test_dashboard/00001.png and b/tests/snapshots/stax/test_dashboard/00001.png differ diff --git a/tests/test_sign_withdraw.py b/tests/test_sign_withdraw.py index abedd61a..e7836559 100644 --- a/tests/test_sign_withdraw.py +++ b/tests/test_sign_withdraw.py @@ -22,12 +22,12 @@ def test_sign_withdraw(navigator: Navigator, firmware: Firmware, client: RaggerC gasToken= "0x0000000000000000000000000000000000000000", refundReceiver= "0x0000000000000000000000000000000000000000", nonce= "0x8", - ) # tx_hash: 0xed3a7a50496ccca6173ddd9a1ad786d61ea737b70541887ab2c2fadcbe36eeaf + ) # tx_hash: 0xa580c0c5a0b8e731f7b7fe8ea3ee41cf0dbe78b352b55ae090160659e2d7410c path = "m/44'/0'/0'/0/0" result = client.sign_withdraw(data, path, navigator, instructions=withdrawal_instruction_approve(firmware), testname=test_name) - assert result == "IEZDsLh2JweulEOzl2dgLrYvtIqWUW8gFeYdMLAYSk7PeH72uN0JQJGVCYZSpJ5HYRaKZrmSBiG3Ypl+oelXEAM=" + assert result == "Hy2UpLBXRUkHBRfXIEYFB8PEteLtjxrqJ7kJ3Qe+i67wP0bzDkFl5Z4bYBFfT/3+xwgPrw3T0rkq6dv53Cff+p0=" def test_sign_withdraw_wrong_address(navigator: Navigator, firmware: Firmware, client: RaggerClient, test_name: str): data = AcreWithdrawalData(