Skip to content

Commit

Permalink
eth/vm: fix accidental override of ensure_no_static() in Constantinople.
Browse files Browse the repository at this point in the history
This made the EVM no longer care that SSTORE within a STATICCALL is
forbidden.

ethereum#1579 (comment)
  • Loading branch information
veox committed Dec 12, 2018
1 parent 3c3aa30 commit 130ebf6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions eth/vm/forks/constantinople/opcodes.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
opcode_values,
)
from eth.vm.forks.byzantium.opcodes import (
BYZANTIUM_OPCODES
BYZANTIUM_OPCODES,
ensure_no_static
)
from eth.vm.forks.constantinople.constants import (
GAS_EXTCODEHASH_EIP1052
Expand Down Expand Up @@ -56,7 +57,7 @@
gas_cost=constants.GAS_CREATE,
)(),
opcode_values.SSTORE: as_opcode(
logic_fn=sstore_eip1283,
logic_fn=ensure_no_static(sstore_eip1283),
mnemonic=mnemonics.SSTORE,
gas_cost=constants.GAS_NULL,
),
Expand Down

0 comments on commit 130ebf6

Please sign in to comment.