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

VIP: Add support for EXTCODEHASH #1765

Closed
fubuloubu opened this issue Dec 12, 2019 · 2 comments · Fixed by #1801
Closed

VIP: Add support for EXTCODEHASH #1765

fubuloubu opened this issue Dec 12, 2019 · 2 comments · Fixed by #1801
Labels
VIP: Approved VIP Approved

Comments

@fubuloubu
Copy link
Member

fubuloubu commented Dec 12, 2019

Simple Summary

Add support for the EXTCODEHASH opcode, which was added in Constantinople via EIP-1052 which allows a user to obtain the keccak256 hash of a contract's deployed bytecode.

Motivation

This feature is helpful for users who want to check that a particular configuration of a contract's bytecode is a given value, such as the use of proxy/registry contracts, and other uses.

Specification

Add the attribute address.codehash which returns the hash of the given account's address per EIP-1052 by calling that opcode. Note the updated gas costs in #1653.

Backwards Compatibility

No backwards incompatibilities.

Dependencies

No dependencies

Copyright

Copyright and related rights waived via CC0


Edits:

#1818 - Modified syntax from get_extcodehash(address) to address.codehash

@fubuloubu fubuloubu added the VIP: Discussion Used to denote VIPs and more complex issues that are waiting discussion in a meeting label Dec 12, 2019
@iamdefinitelyahuman
Copy link
Contributor

This will be easy to implement after #1783 - and give us something to list in the documentation under changes when targeting constantinople :)

@fubuloubu
Copy link
Member Author

Meeting: change function name to get_extcodehash(address)

@jacqueswww jacqueswww added the VIP: Approved VIP Approved label Jan 6, 2020
@fubuloubu fubuloubu removed the VIP: Discussion Used to denote VIPs and more complex issues that are waiting discussion in a meeting label Jan 6, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
VIP: Approved VIP Approved
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants