Skip to content

Conversation

KolbyML
Copy link
Member

@KolbyML KolbyML commented Oct 16, 2025

fixes NIT-3993

problem

For benchmarking purposes, we would like to write to storage slots of existing contracts without private keys for the contracts. To do that, we want to be able to replace any contract code with a simple permissive contract code. This custom contract code will implement method facilitating the arbitrary writes to the contract's storage.

solution

  • Add a method to the ArbDebug procompile which overwrites the specified contracts code
  • Add a test to make sure the new method works as expected

I also had to update ArbDebug's solidity interface in OffchainLabs/nitro-precompile-interfaces

^ so this should probably be reviewed first

@KolbyML KolbyML changed the title Add arbdebug_overwriteContractCode method to ArbDebug precompile Add OverwriteContractCode method to ArbDebug precompile Oct 16, 2025
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.

2 participants