fix(ampd): fix nonce for multiversx being keccak256 hash instead of created at #593
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.
Because of a confusion of types from the AxelarAmplifierGateway contract (see here), we assumed that the
nonce
should be a keccak256 hash.Instead, for both the EVM and Sui implementations, it is the
created_at
date (u64) represented as a uint256. Both keccak256 & uint256 have the same 32 byte length, hence the confusion.The only other place that needs updating is our multisig contract, which we will also handle.
This will also simplify the Relayer implementation, since previously it was not possible for us to go from the keccak256 hash back to the created_at date, which is needed for the
verify_verifier_set
call on the Voting Verifier.