-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Creator Contract abstraction #143
Comments
would it handle running the initialization code for new contracts also? |
It has to because it returns the deployed contract address. |
There has been no activity on this issue for two months. It will be closed in a week if no further activity occurs. If you would like to move this EIP forward, please respond to any outstanding feedback or add a comment indicating that you have addressed all required feedback and are ready for a review. |
This issue was closed due to inactivity. If you are still pursuing it, feel free to reopen it and respond to any feedback or request a review in a comment. |
This is a follow up to #86 with the intent of moving more logic to contract abstractions.
Motivation
Replace the special
CREATE
opcode and the special case of external transactions, which cause a contract to be deployed, with a contract.Abstract
The creator contract (at address
TBD
) takes bytecode to be deployed as the input and returns 20 bytes output consisting of the 160-bit contract address.The EVM opcode
CREATE
is mapped to be aCALL
to the creator contract.Implementation
Initially, this contract could only be implemented as a precompile, which has special access to the state. Later, with eWASM, it would be possible to have a privileged set of imported methods to system contracts and the creator contract could be implemented natively in eWASM.
For the current address algorithm it also needs to have access to the sender's nonce (
sha3(rlp([sender, sender_nonce]))
), but with the proposed new Metropolis algorithm (sha3(sender + bytecode)
) that is not necessary.Furthermore, the creator contract in eWASM could include the feature set of the Sentinel Contract to support deploying both EVM1 and eWASM, including validation and metering injection.
The text was updated successfully, but these errors were encountered: