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

verify-bytecode: support arbitrary contract creation methods #9583

Open
adhusson opened this issue Dec 20, 2024 · 0 comments
Open

verify-bytecode: support arbitrary contract creation methods #9583

adhusson opened this issue Dec 20, 2024 · 0 comments
Labels
Cmd-forge-vb Command: forge verify-bytecode T-feature Type: feature

Comments

@adhusson
Copy link
Contributor

Component

Forge

Describe the feature you would like

forge supports verify-bytecode on:

  • predeploys
  • contracts deployed by the EOA by setting tx.to = ''
  • contracts deployed by setting tx.to = DEFAULT_CREATE2_DEPLOYER

In other cases it cannot find the contract creation code.

It would be useful to support arbitrarily nested calls to create and create2. For instance it would allow using a custom create2 deployer and still verifying with verify-bytecode.

I think this is achievable by stepping through the transaction and finding uses of CREATE/CREATE2 that return the created contract address, then reading the relevant memory segment when the opcode was used.

Additional context

No response

@adhusson adhusson added T-feature Type: feature T-needs-triage Type: this issue needs to be labelled labels Dec 20, 2024
@github-project-automation github-project-automation bot moved this to Todo in Foundry Dec 20, 2024
@zerosnacks zerosnacks added Cmd-forge-vb Command: forge verify-bytecode and removed T-needs-triage Type: this issue needs to be labelled labels Jan 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Cmd-forge-vb Command: forge verify-bytecode T-feature Type: feature
Projects
Status: Todo
Development

No branches or pull requests

2 participants