MetaMask / metamask-extension

:globe_with_meridians: :electric_plug: The MetaMask browser extension enables browsing Ethereum blockchain enabled websites
https://metamask.io
Other
11.93k stars 4.88k forks source link

[Feat]: Further EIP-2612 support - handle 'allowed' values #27269

Open digiwand opened 2 weeks ago

digiwand commented 2 weeks ago

What is this about?

Check that an EIP-2612 with allowed specified instead of value works as expected. Is it reflected on the Permit Simulation? Will it be supported by the upcoming Signature API?

Backwards Compatibility

Scenario

No response

Design

No response

Technical Details

No response

Threat Modeling Framework

No response

Acceptance Criteria

No response

Stakeholder review needed before the work gets merged

References

No response

cryptotavares commented 1 week ago

Can we break down each highlighted item into its own ticket?

digiwand commented 1 week ago

Updated this ticket to address the first bulletpoint only. Created https://github.com/MetaMask/metamask-extension/issues/27357 to address the ensure owner != address(0) bulletpoint.

Looking into the second bulletpoint,

There is also an implementation in the token Stake (Ethereum address 0x0Ae055097C6d159879521C384F1D2123D1f195e6) with the same ABI as dai but with different semantics: it lets users issue “expiring approvals”, that only allow transferFrom to occur while expiry >= block.timestamp.

It does appear that this happens onchain, so I think there is no need to address this one. Removed from board