trailofbits / manticore

Symbolic execution tool
https://blog.trailofbits.com/2017/04/27/manticore-symbolic-execution-for-humans/
GNU Affero General Public License v3.0
3.68k stars 472 forks source link

Timeout option does not work. #1581

Open sunbeomso opened 4 years ago

sunbeomso commented 4 years ago

OS / Environment

Host OS: Ubuntu 18.04.2 Used image via docker pull trailofbits/manticore (digest: sha256:8399fab57924a875dbc813b0ccda658d1cc8bbf46185bdaf34eebd901d60641a)

Manticore version

0.3.2.1

Python version

3.6.9 (the one in the docker image)

Summary of the problem

Manticore's timeout option often does not work.

Step to reproduce the behavior

My command was:

sudo docker exec CONTNAME manticore /tmp/FILE.sol --contract MaxHouse --core.timeout 60 --solc-solcs-bin solc-0.4.19

where CONTNAME is the name of the docker container, and FILE.sol is the name of the file.

FILE.sol is a contract from: https://etherscan.io/address/0x8d397626b256be03dd718b77e217eee82c4940b4#code

Expected behavior

I think Manticore should have terminated within 1 minute or a little over, since I provided an option --core.timeout 60.

Actual behavior

Manticore does not terminate even after 5 minutes.

Though I specifically provided one example in this issue, I encountered such situations (i.e., timeout option does not work) fairly often.

ehennenfent commented 4 years ago

Can you provide the traceback dumped after killing Manticore? The timeout argument is a little deceiving in that it only applies to state exploration. Other activities, like initialization and finalizing testcases, have independent timeouts. It's possible that Manticore is getting stuck in one of those other stages.