Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature]: Support for minimal proxy contracts (EIP-1167) #1536

Open
1 task done
CedarMist opened this issue Sep 11, 2024 · 1 comment
Open
1 task done

[Feature]: Support for minimal proxy contracts (EIP-1167) #1536

CedarMist opened this issue Sep 11, 2024 · 1 comment
Labels
feature New feature or request

Comments

@CedarMist
Copy link
Member

CedarMist commented Sep 11, 2024

Is there an existing issue for this?

  • I have searched the existing issues

SUMMARY

Detect EIP-1167 proxies, show information about the target contract (and whether it's verified)

DESCRIPTION

EIP-1167 minimal proxy contracts have a well known bytecode format, unfortunately they can also not be verified using Sourcify.

This makes it difficult to find information about a contract if it was deployed using minimal proxies (such as clone factories).

For example, the following contract is an EIP-1167 proxy: https://explorer.oasis.io/testnet/sapphire/address/0xbA7F3eE55b7939294caFA0F1e096E79722e1BD88/code#code

The runtime bytecode is 0x363d3d373d3d3d363d73243e9b626bc3ca61795600ed5295377423cd4e695af43d82803e903d91602b57fd5bf3, the target of this contract is 0x243e9b626bc3ca61795600ed5295377423cd4e69 - the target contract is verified.

For more details on the minimal proxy: https://blog.openzeppelin.com/deep-dive-into-the-minimal-proxy-contract

So, while the proxy contract isn't verified, the target of the proxy is verified.


Suggestion:

  • In the 'Verification' row, if it's an EIP-1167 proxy, show that it's a proxy, and extract the destination contract with a link.
@CedarMist CedarMist added the feature New feature or request label Sep 11, 2024
@CedarMist
Copy link
Member Author

CedarMist commented Sep 11, 2024

Etherscan also supports a variety of proxy contracts, including EIP-1967 and EIP-1167.

The Etherscan UI isn't great though, in fact in some places it's really just annoying. So maybe not the best influence to take inspiration from.

EIP-1167

image

EIP-1967

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant