✨ Message Hash Logic for < 1.0.0
Safe Versions
#9
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
🕓 Changelog
Safe multisig versions
< 1.0.0
use a legacy (i.e. the parameter valuebaseGas
was calleddataGas
previously)SAFE_TX_TYPEHASH
value:Starting with version
1.0.0
,baseGas
was introduced: safe-global/safe-smart-account#90.This PR introduces additional logic to the script to accommodate the breaking change in Safe versions. Furthermore, all Safe versions
< 0.1.0
are not supported and the script issues as warning to the user.Testing
Ethereum:
The Safe multisig
0xecd11858a4bcc35A51084Ebe672beaCe01142fcA
is based on version0.1.0
.Run:
./safe_hashes.sh --network ethereum --address 0xecd11858a4bcc35A51084Ebe672beaCe01142fcA --nonce 61
To verify the domain hash, you can use
cast
:cast call 0xecd11858a4bcc35A51084Ebe672beaCe01142fcA "domainSeparator()" -r https://eth.llamarpc.com
which will output:
0x4181d94ee9f43dc08d31a2c86eb37b704f2051787a9c84d1397a60d07136d1c1
For the message hash and the Safe transaction hash, you can use the
evaluate
feature of Tenderly in one of the multisig transactions:https://dashboard.tenderly.co/tx/mainnet/0xc139e324bc231c5f7b8a9a27e775295118e9cbc06995f89225261abd0420f362/debugger?trace=0.1.1.0
https://dashboard.tenderly.co/tx/mainnet/0xc139e324bc231c5f7b8a9a27e775295118e9cbc06995f89225261abd0420f362/debugger?trace=0.1.2