ethernaut icon indicating copy to clipboard operation
ethernaut copied to clipboard

Solidity 0.5 Version: Elevator outdated advice

Open bergarces opened this issue 6 years ago • 0 comments

:computer: Environment Solidity 0.5 Version of Ethernaut (https://solidity-05.ethernaut.openzeppelin.com/)

:memo: Details After finishing the Elevator level (11) in Ethernaut, a tip appears stating that solidity does nothing to prevent a view function from modifying the state.

According to the latest Solidity documentation, using Byzantium or a newer EVM version for the compiler (which is already the default) will use the opcode STATICCALL for view functions, which enforces the state to stay unmodified.

:1234: Steps to reproduce Complete Elevator level (11) of Ethernaut with Solidity 0.5.

bergarces avatar Nov 30 '19 14:11 bergarces