Closed Mikerah closed 4 years ago
Can you try increasing the solver-timeout, as that maybe a reason, default timeout might be a bit low this for contract.
I increased the solver-timeout to 10000, 100000 and 1000000 from the default 10000 and it still doesn't detect it.
I increased the max_depth of the MythrilAnalyzer and it correctly detected SWC-120 in the contract.
Description
I ran Mythril on a contract with address
0x3582f0e90a11d1e021b48e70421770a063cc9e57
for which the bytecode and contract source code are available on etherscan.io. This smart contract makes use of theBLOCKHASH
opcode i.e. makes a call toblockhash
in such a way that I think is an instance of SWC-120: Weak Sources of Randomness from Chain Attributes. As such, I believe Mythril has failed to detect this particular violation of SWC-120.How to Reproduce
I ran
myth analyze -a 0x3582f0e90a11d1e021b48e70421770a063cc9e57
and gotThe analysis was completed successfully. No issues were detected.
Expected behavior
I expected to at least see the output showing that the smart contract at that address is a violation of SWC-120.
Environment
Mythril version: 0.22.9 Solidity compiler and version: solc version 0.6.7+commit.b8d736ae.Linux.g++ Python version: 3.8.5 OS and Version: Fedora 32