Skip to content

Add Warnings in ERC-6492 Implementation #877

Open
@pcaversaccio

Description

@pcaversaccio

Summary

Since the exploit vector is publicly known, I consider the risk of discussing this matter openly to be low. Therefore, I'm opening a standard issue.

Last week a contract was exploited using the ERC-6492 reference implementation. An exemplary exploit contract can be retrieved here. So the major issue (apart from inheriting the implementation, which you should not do) is the combination of the identity precompile located at address 0x04 in combination with ERC-6492. Please note that there is an EIP proposal to replace the identity precompile with EVM code which we might can leverage in the future.

Actions to Discuss

  • Add a warning that the universal verifier should not be inherited.
  • We need to add a warning to the current ERC-6492 reference implementation regarding the usage of _signer = address(0x04) (and the combination with arbitrary calls). We could even go a step further, and either disallow that specific precompile address 0x04 or the full precompile address range: 0x00 - address(2**16-1).
  • Do we see any impacts of the newly discovered attack vector for ERC-1271 implementations?

Cc: @Ivshti @Agusx1211

h/t goes to @0xkarmacoma for raising this issue with me.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions