Skip to content

Conversation

@nicholaspai
Copy link
Member

  • 7683 settler incorrectly implements hashing function
  • speedUpV3Deposit uses incorrect type hash

…posit

1.  ERC7683Permit2Lib.hashOrderData does not include `depositNonce` in the hash despite it being a part of the `ACROSS_ORDER_DATA_TYPE_HASH`. This wouldn't result in any run-time bugs but it probably would not be interpreted correctly by ERC712 wallets or Permit2 interfaces.
2. speedUpDepositV3 signature cannot be filled via fillRelayWithUpdatedDeposit because the latter uses a different "hash type" than the former, which uses a hash type where `updatedRecipient` is an address despite converting it to bytes32 before hashing
@nicholaspai nicholaspai merged commit 644239d into master Apr 25, 2025
9 checks passed
@nicholaspai nicholaspai deleted the patch-hashes branch April 25, 2025 20:36
Reinis-FRP pushed a commit that referenced this pull request May 9, 2025
…re EIP712 type hash (#955)

* fix: Patch ERC7683Permit2Lib.hashOrderData and SpokePool. speedUpV3Deposit

1.  ERC7683Permit2Lib.hashOrderData does not include `depositNonce` in the hash despite it being a part of the `ACROSS_ORDER_DATA_TYPE_HASH`. This wouldn't result in any run-time bugs but it probably would not be interpreted correctly by ERC712 wallets or Permit2 interfaces.
2. speedUpDepositV3 signature cannot be filled via fillRelayWithUpdatedDeposit because the latter uses a different "hash type" than the former, which uses a hash type where `updatedRecipient` is an address despite converting it to bytes32 before hashing

* Add speedUpDeposit fix tests

* Add erc7683Permit2Lib tests

* add warnings in natspec to unsafe deposit and speed up deposit

* Add warning about re-using deposit nonce

* typo

Signed-off-by: Reinis Martinsons <reinis@umaproject.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants