From d632798abb1316533d4825ce45e3787daf60cbac Mon Sep 17 00:00:00 2001 From: Josh Asplund Date: Mon, 4 Jun 2018 14:11:49 -0500 Subject: [PATCH 1/5] Adds tox testing --- .circleci/config.yml | 9 +- .gitignore | 176 +++++++++++++++++++++++++++++-- Pipfile | 18 +--- Pipfile.lock | 246 +++++++++++++++++++++++++++++-------------- tox.ini | 10 ++ 5 files changed, 355 insertions(+), 104 deletions(-) create mode 100644 tox.ini diff --git a/.circleci/config.yml b/.circleci/config.yml index 780e0c87..f8425ba9 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -30,13 +30,16 @@ jobs: - run: name: Unit-testing - command: cd /home/mythril && ./all_tests.sh + command: cd /home/mythril && tox + environment: + LC_ALL: C.UTF-8 + LANG: C.UTF-8 - store_test_results: - path: /tmp/test-reports + path: /home/mythril/.tox/output - store_artifacts: - path: /tmp/test-reports + path: /home/mythril/.tox/output - run: name: Ensuring that setup script is functional diff --git a/.gitignore b/.gitignore index b5eb4723..1c81bd7c 100644 --- a/.gitignore +++ b/.gitignore @@ -1,11 +1,173 @@ -.DS_Store + +# Created by https://www.gitignore.io/api/linux,macos,python,windows + +### Linux ### +*~ + +# temporary files which can be created if a process still has a handle open of a deleted file +.fuse_hidden* + +# KDE directory preferences +.directory + +# Linux trash folder which might appear on any partition or disk +.Trash-* + +# .nfs files are created when an open file is removed but is still being accessed +.nfs* + +### macOS ### +*.DS_Store +.AppleDouble +.LSOverride + +# Icon must end with two \r +Icon + +# Thumbnails +._* + +# Files that might appear in the root of a volume +.DocumentRevisions-V100 +.fseventsd +.Spotlight-V100 +.TemporaryItems +.Trashes +.VolumeIcon.icns +.com.apple.timemachine.donotpresent + +# Directories potentially created on remote AFP share +.AppleDB +.AppleDesktop +Network Trash Folder +Temporary Items +.apdisk + +### Python ### +# Byte-compiled / optimized / DLL files +__pycache__/ +*.py[cod] +*$py.class + +# C extensions +*.so + +# Distribution / packaging +.Python +build/ +develop-eggs/ +dist/ +downloads/ +eggs/ +.eggs/ +lib/ +lib64/ +parts/ +sdist/ +var/ +wheels/ +*.egg-info/ +.installed.cfg +*.egg + +# PyInstaller +# Usually these files are written by a python script from a template +# before PyInstaller builds the exe, so as to inject date/other infos into it. +*.manifest +*.spec + +# Installer logs +pip-log.txt +pip-delete-this-directory.txt + +# Unit test / coverage reports +htmlcov/ +.tox/ +.coverage +.coverage.* +.cache +.pytest_cache/ +nosetests.xml +coverage.xml +*.cover +.hypothesis/ + +# Translations +*.mo +*.pot + +# Flask stuff: +instance/ +.webassets-cache + +# Scrapy stuff: +.scrapy + +# Sphinx documentation +docs/_build/ + +# PyBuilder +target/ + +# Jupyter Notebook +.ipynb_checkpoints + +# pyenv .python-version -__pycache__ -*.pyc + +# celery beat schedule file +celerybeat-schedule.* + +# SageMath parsed files +*.sage.py + +# Environments +.env +.venv +env/ +venv/ +ENV/ +env.bak/ +venv.bak/ + +# Spyder project settings +.spyderproject +.spyproject + +# Rope project settings +.ropeproject + +# mkdocs documentation +/site + +# mypy +.mypy_cache/ + +### Windows ### +# Windows thumbnail cache files +Thumbs.db +ehthumbs.db +ehthumbs_vista.db + +# Folder config file +Desktop.ini + +# Recycle Bin used on file shares +$RECYCLE.BIN/ + +# Windows Installer files +*.cab +*.msi +*.msm +*.msp + +# Windows shortcuts +*.lnk + + +# End of https://www.gitignore.io/api/linux,macos,python,windows + *.asm -mythril.egg-info -build -dist *.rst *.lock !Pipfile.lock @@ -14,7 +176,5 @@ laser* lol* .idea* coverage_html_report/ -.coverage -.pytest_cache tests/testdata/outputs_current/ tests/mythril_dir/signatures.json diff --git a/Pipfile b/Pipfile index 63fe3b4e..459f1564 100644 --- a/Pipfile +++ b/Pipfile @@ -4,27 +4,15 @@ verify_ssl = true name = "pypi" [packages] -requests = "*" -plyvel = "*" -py-solc = "*" -coverage = "*" -BTrees = "*" -ethereum = ">=2.3.0" -zodb = ">=5.3.0" -eth-abi = "*" -"z3-solver" = ">=4.5" -eth-account = "*" -eth-tester = "*" -laser-ethereum = ">=0.5.20" -"jinja2" = "*" -rlp = "<1.0.0" +"e1839a8" = {path = ".", editable = true} + [dev-packages] pylint = "*" yapf = "*" pytest = "*" +pytest-mock = "*" [requires] -python_version = "3.6" [pipenv] allow_prereleases = true diff --git a/Pipfile.lock b/Pipfile.lock index f6c739de..72a7422d 100644 --- a/Pipfile.lock +++ b/Pipfile.lock @@ -1,12 +1,10 @@ { "_meta": { "hash": { - "sha256": "b8b7e52dd560311e7e06c0c51ab86c67503a1b7d7499e372ad00698acc16f43c" + "sha256": "54df73f8f1c17c3992638c8199c50acdf7b424476332de73f0e2b13cf086e2e0" }, "pipfile-spec": 6, - "requires": { - "python_version": "3.6" - }, + "requires": {}, "sources": [ { "name": "pypi", @@ -23,19 +21,52 @@ ], "version": "==0.24.0" }, + "atomicwrites": { + "hashes": [ + "sha256:240831ea22da9ab882b551b31d4225591e5e447a68c5e188db5b89ca1d487585", + "sha256:a24da68318b08ac9c9c45029f4a10371ab5b20e4226738e150e6e7c571630ae6" + ], + "version": "==1.1.5" + }, + "attrdict": { + "hashes": [ + "sha256:86aeb6d3809e0344409f8148d7cac9eabce5f0b577c160b5e90d10df3f8d2ad3" + ], + "version": "==2.0.0" + }, + "attrs": { + "hashes": [ + "sha256:4b90b09eeeb9b88c35bc642cbac057e45a5fd85367b985bd2809c62b7b939265", + "sha256:e0d0eb91441a3b53dab4d9b743eafc1ac44476296a2053b6ca3af0b139faf87b" + ], + "version": "==18.1.0" + }, "btrees": { "hashes": [ + "sha256:0b100e41ad3a0d16b8f07794af14acaf92b87ff5f4f1d942dc50f3f8105b2e67", + "sha256:147d3fd20c18200223c6c56316f352668858046afbd834dae464b7f73bedd53a", + "sha256:1b00572984986159db187a9d6cec3bcf48362d4162e72f53a3df362c53254c54", + "sha256:241cc088bc81c3977b7deb9b2f2239b82da814676affe6248d6df51744bc94fe", + "sha256:37e1529d3bd3257fa6b724383fef1a3420b16e2e3ce7d97b32cd7a8d5d3020af", + "sha256:399090e43c9ebf525a5cdced8fac18da3243cd78382333eae431ef3b2a6ae219", "sha256:46b02cb69b26a5238db771ea1955b503df73ecf254bb8063af4c61999fc75b5c", "sha256:4986f7ea25013e0370d88a4699490f83da92745705001b3d619de7d9600edc66", "sha256:4996f282254bc30ab3855df4b757a675d043edf069368ac8e9ac1fadcaebb89b", "sha256:4c77eed4ae3e182de559296893ae00b8da3201d51c51751787b53b34ac3b1a79", + "sha256:5e1831187360b78cc05d906e17944bef21583a1541506a26af3b6f25baaab208", + "sha256:64d655824d654d54021d65795e7c9d6f5d21a2427199c7dc0a25d259801f90f1", + "sha256:71235ac01a2f7989bce49f9bb9c0b43e5f19a3dbc2df51ad646950ee541b99a8", + "sha256:7f9dc2e73c46df0ece533bf432c1d54816eb94d3c7cd14e05c53a78addf61898", + "sha256:81039fb3060434036776da02b38b4b0872589377a873f432dad20f0c44f47f3c", "sha256:888c016774630b7be2339888df1d0e7c91e1e0139e1b9ec80309feb1fc6fd9ec", "sha256:895e5d173dd77989d8b9b9649e01a2509c6553ca3820c15f058e129fcbdab88c", + "sha256:8fcf0a87057c2558e5456aba6094ba3cf8a3641484608dbe86e7573d23e98b91", "sha256:a80c5f14eac095502b5ba6adfdbea7a891dc5d761efeef75d11c2dbed7a9e5f0", "sha256:acfdd66a3db6753cec1a06345fbef27b4cc592e269dfc162fa1f881230d1addc", + "sha256:b47db60a25cea6af29869e0a923705df71079137a99c9061008768c399ec4cd4", + "sha256:c8bf40f9f3078d373e71042198fefdd0588775df5f5e5a97525f2c32d0653c43", "sha256:df8a059fc7c43ae34c47806be00021432988efdc8b24e8422fa6a785c9c78150" ], - "index": "pypi", "version": "==4.5.0" }, "certifi": { @@ -142,7 +173,6 @@ "sha256:f3f501f345f24383c0000395b26b726e46758b71393267aeae0bd36f8b3ade80", "sha256:f8a923a85cb099422ad5a2e345fe877bbc89a8a8b23235824a93488150e45f6e" ], - "index": "pypi", "version": "==4.5.1" }, "cytoolz": { @@ -158,28 +188,30 @@ ], "version": "==0.0.1" }, + "e1839a8": { + "editable": true, + "path": "." + }, "eth-abi": { "hashes": [ - "sha256:3b965a707640cac5260208ceb58e02fd41b58b8e356dc95784dfdef8e3b1d4d0", - "sha256:58aed210e49da6bd318c026d306da2bf4c63022745460a791546ac10c4982162" + "sha256:717f33b654fdaed61c3276d26bfa6ca2006ce3254c98d6c8ed0ac645acd5b34b", + "sha256:a0a9bd9c6985f7d696c195911f097ec70adc2199553f61ac6236c7066eea5ba9" ], - "index": "pypi", - "version": "==1.0.0" + "version": "==1.1.1" }, "eth-account": { "hashes": [ - "sha256:8c33e63e1e04527a37e00616569313e009db1efc5619731f3d4ec8890eea5ca4", - "sha256:c386f0e3e2e3b56c6f564fa4001a05d5dca5844e69794750e8a7621083308941" + "sha256:165aa14c18526247c044221565fa6ef27332928abe5930aa949b207d6d6ac248", + "sha256:a94823dbc5f8b66e0466c388c7b1b61dde06d64982b75d4b956512915f56f3f0" ], - "index": "pypi", - "version": "==0.2.0" + "version": "==0.2.3" }, "eth-hash": { "hashes": [ - "sha256:43adcab75a957fcf8c453d5542be55e4e0bd4e166270f45b09ac69b4d6486a06", - "sha256:8695f5f3794497d1357b2ef6e84c67a7daf4bfec1dde9f76ff6b2022c2cc03a6" + "sha256:30536f6057128c9130598103fb574a6a3d75d482bda0b13c5488f2f68d9a1423", + "sha256:42e6604e879b998002c915c1061ab317927329d7f47d3cbb80b83132dc7b58a4" ], - "version": "==0.1.2" + "version": "==0.1.4" }, "eth-keyfile": { "hashes": [ @@ -197,18 +229,17 @@ }, "eth-rlp": { "hashes": [ - "sha256:1330ebf341cd13fefbd9edaa038054cb19bc38368f866eb777f1f880577ed499", - "sha256:773bd96b4b83939822ef5d7dffa90448d5ccc2d38e5aeb03850c808ae43c183d" + "sha256:05d8456981d85e16a9afa57f2f2c3356af5d1c49499cc8512cfcdc034b90dde5", + "sha256:a94744c207ea731a7266bd0894179dc6e51a6a8965316000c8e823b5d7e07694" ], - "version": "==0.1.0" + "version": "==0.1.2" }, "eth-tester": { "hashes": [ - "sha256:2e85782fc0627c5f29ed143865b8c3f27411bc28c78d6273ea797a24527e265c", - "sha256:836695b7c3159c9d9461de3397c5e1b044d798e785181c3de2012ad04be0a2f6" + "sha256:a3cb5076de16dfea1e08abe55a33ff4e0528fd1be2661e60823cfed24d466ad0", + "sha256:c88ae348436c331ebf90ae066fbbd468ed699474b5ce59731b78d3034e0066f6" ], - "index": "pypi", - "version": "==0.1.0b23" + "version": "==0.1.0b26" }, "eth-utils": { "hashes": [ @@ -221,7 +252,6 @@ "hashes": [ "sha256:69a22c2f793970d184777bb92589e67d0f622d56eda7c3c1bfc1f0edad522c1c" ], - "index": "pypi", "version": "==2.3.1" }, "future": { @@ -249,15 +279,13 @@ "sha256:74c935a1b8bb9a3947c50a54766a969d4846290e1e788ea44c1392163723c3bd", "sha256:f84be1bb0040caca4cea721fcbbbbd61f9be9464ca236387158b0feea01914a4" ], - "index": "pypi", "version": "==2.10" }, "laser-ethereum": { "hashes": [ - "sha256:720b35d554c7dbd160bfc8f8de630e8b856fec34950a89844eb340bdcd052338" + "sha256:c92e877039af22338b5632cfdb17f27036e79eed3e15570c897593f033a24d6c" ], - "index": "pypi", - "version": "==0.16.0" + "version": "==0.17.12" }, "markupsafe": { "hashes": [ @@ -265,6 +293,20 @@ ], "version": "==1.0" }, + "more-itertools": { + "hashes": [ + "sha256:2b6b9893337bfd9166bee6a62c2b0c9fe7735dcf85948b387ec8cba30e85d8e8", + "sha256:6703844a52d3588f951883005efcf555e49566a48afd4db4e965d69b883980d3", + "sha256:a18d870ef2ffca2b8463c0070ad17b5978056f403fb64e3f15fe62a52db21cc0" + ], + "version": "==4.2.0" + }, + "parsimonious": { + "hashes": [ + "sha256:ae0869d72a6e57703f24313a5f5748e73ebff836e6fe8b3ddf34ea0dc00d086b" + ], + "version": "==0.8.0" + }, "pbkdf2": { "hashes": [ "sha256:ac6397369f128212c43064a2b4878038dab78dab41875364554aaf2a684e6979" @@ -304,6 +346,14 @@ ], "version": "==4.2.4.2" }, + "pluggy": { + "hashes": [ + "sha256:7f8ae7f5bdf75671a718d2daf0a64b7885f74510bcd98b1a0bb420eb9a9d0cff", + "sha256:d345c8fe681115900d6da8d048ba67c25df42973bda370783cd58826442dcd7c", + "sha256:e160a7fcf25762bb60efc7e171d4497ff1d8d2d75a3d0df7a21b76821ecbf5c5" + ], + "version": "==0.6.0" + }, "plyvel": { "hashes": [ "sha256:059d5689ffe078061edfb12fe9251abcac9996aa20cfec9049fdd7391c8ed742", @@ -313,9 +363,15 @@ "sha256:adc2573a82d100db3d583da5348e74833cd47d4221cff299285d2c8e09570edf", "sha256:b7736bf08e83c1a95cce0cb91809f94eb612666158feaba8c4b7ef2d3f955a6e" ], - "index": "pypi", "version": "==1.0.4" }, + "py": { + "hashes": [ + "sha256:29c9fab495d7528e80ba1e343b958684f4ace687327e6f789a94bf3d1915f881", + "sha256:983f77f3331356039fdd792e9220b7b8ee1aa6bd2b25f567a963ff1de5a64f6a" + ], + "version": "==1.5.3" + }, "py-ecc": { "hashes": [ "sha256:c7808a70c08bfc5c07b328f4df4406cfd3e365dd81f63bdd997c3c1eae34334a", @@ -332,11 +388,10 @@ }, "py-solc": { "hashes": [ - "sha256:0e657cc639b91649084901c00f0b14b921d40ab1b2faed0fb1216e80999bda72", - "sha256:90b7308abe35825979a1a03294bc383b5282bebdf9db1dda58223142dc7e9955" + "sha256:d27d1a6cdd4dda6e5f01fac9b3e391fa8f68877ae879dfdd9cea4ca7922cdbe2", + "sha256:f49927fd8a84f4212a4efc6ad8d565b7ea9c9d411c024ea627407124f9adff4a" ], - "index": "pypi", - "version": "==2.1.0" + "version": "==3.0.0" }, "pycparser": { "hashes": [ @@ -408,6 +463,21 @@ ], "version": "==1.0.2" }, + "pytest": { + "hashes": [ + "sha256:39555d023af3200d004d09e51b4dd9fdd828baa863cded3fd6ba2f29f757ae2d", + "sha256:c76e93f3145a44812955e8d46cdd302d8a45fbfc7bf22be24fe231f9d8d8853a" + ], + "version": "==3.6.0" + }, + "pytest-mock": { + "hashes": [ + "sha256:53801e621223d34724926a5c98bd90e8e417ce35264365d39d6c896388dcc928", + "sha256:d89a8209d722b8307b5e351496830d5cc5e192336003a485443ae9adeb7dd4c0" + ], + "index": "pypi", + "version": "==1.10.0" + }, "pyyaml": { "hashes": [ "sha256:0c507b7f74b3d2dd4d1322ec8a94794927305ab4cebbe89cc47fe5e81541e6e8", @@ -439,7 +509,6 @@ "sha256:6a1b267aa90cac58ac3a765d067950e7dbbf75b1da07e895d1f594193a40a38b", "sha256:9c443e7324ba5b85070c4a818ade28bfabedf16ea10206da1132edaa6dda237e" ], - "index": "pypi", "version": "==2.18.4" }, "rlp": { @@ -507,7 +576,6 @@ "sha256:c802dbe5368743dd30dd2a684c15b83b17c3c95df54b66f97611a5988ae0f696", "sha256:e41001b7f43ecb9eb9bedf6762bd0e002561590487cc78c0b48f608a85ce02ac" ], - "index": "pypi", "version": "==4.5.1.0.post2" }, "zc.lockfile": { @@ -527,36 +595,21 @@ "hashes": [ "sha256:0b306042f4f0d558a477d65c34b0dd6e7604c6e583f55dfda52befa2fa13e076" ], - "index": "pypi", "version": "==5.4.0" }, "zodbpickle": { "hashes": [ - "sha256:04e6eca53b6e7f562ff7c53415fbdf277166f89f254b5d341db1bcc1f7f0b770", - "sha256:0a9788a37979715cfa98052e37d6ee1880463aa0fba635caf2ec64b6fdbd2e4a", - "sha256:1397a43cf7ad7f5c9b75cf30df9232b0f03a4d74154ee344afc5e09331a3b3a1", - "sha256:1f93b692fcc4dfa20a06e40f4b24e587fb0dd9c00834fac295ee73e1c2623090", - "sha256:2261f0f4958c48ba81e30e144f5a0ac937452200c2bf375489c38f0343f45902", - "sha256:23228cf8c33c6955ab215324c84688e82848c2669a06e1b1656b4facfff81fe0", - "sha256:33e6066759f4c462baf3a65e41095c0d93751f2817d19874405d3b2094ff9108", - "sha256:3af9169fb1d5901cf6693ab356b0dfda20ad2cacc5673fad59b4449ed50d5399", - "sha256:4ce6982ec92a85dd0af89671bf0252a7f7259f762d9fd5ec4bec0049309129a2", - "sha256:60bf75ac7efa1ab6d72b5460e86cb69979599f828f60175c1a8f05dda0e6184a", - "sha256:87c23cba15329957ff867471b8eef9c0b2174c40f61a6978d20a71f4c524d875", - "sha256:87f0467e944101a7dcd674b43a33a10d4f58b61fffcb9ac0efd2453726fd0309", - "sha256:8f22db458f3b682b1ed4a89e4f825cadbc278ce89b0915ed25d05b841630c86d", - "sha256:95fbaac0639f1d29008d09fd5eb421a8dbc87e5e4e282729772250866a028c52", - "sha256:96dce0fb50d4f9ae64fe289826904ea851fd7f5d30597296ca5fb0a69396c0be", - "sha256:9fb4630ac7893fc97f69c8069577d90a84974f96d2dcdb2c067c0698f232c02d", - "sha256:a31b82d1df4f34587f4c4be22165be00f0ec04e8818d8806169f28c0fd1adf11", - "sha256:abc02cb2adbdad9c64f03b9e3195cb118a3a2239139757dbb88d5693cd113d54", - "sha256:bcf7ecef9a5966facc3a3823ce2ca022d6289b3646860fc47260e55038e9d321", - "sha256:c259e38812691512a0b11d96ffc81e9ad3c78cbb9e37d2faf19ad5ce18870e4b", - "sha256:e781b3b33aef6e667725fcf4365d4422248e8eae9ea394006ace9d65e2c99ff8", - "sha256:efdd2589aab15cbed8bbe8958552dc9a2ceeb178d138217bfa6db6012847b4ed", - "sha256:f14109e4c3c5353cc1926e4a0b7a9fda74731e2ea98320701ab69e0b9787a424" + "sha256:05b919d70341da9df677f564f40a7c2c97aff3338f5929d9a9ece6077b3d3247", + "sha256:4964bf56b9459979b7228cc1d571c3683c55ad31b67b88133d6c0253df9bf456", + "sha256:5b07352a42547169027b5186ae1b0aba3d9c278adfa3d32b4e4e18c904c906a8", + "sha256:5c16c6209bd583096da144e2960a56d56e0577277f72e4826f77c960fc2ac34f", + "sha256:5fdfa84f05b25511a4e1190ec98728aa487e2eb6db016a951fdbb79bcc7307e0", + "sha256:6b232db8896a87bfe5acfbbeb6255448783502e1fbdd79627f895760808b12cd", + "sha256:6e98bf709b2662f1db5e200f5eed73126a22dc571fcb78052e2ea668b30106b6", + "sha256:86169ca92929e2d888ebbf25e1f8d7abeef08eaffedab5fea496c100831beefb", + "sha256:d64e4a2ce81e150f35674b2bb92ac85abadda3e24bca67764a35d5c168e5e99e" ], - "version": "==1.0" + "version": "==1.0.1" }, "zope.interface": { "hashes": [ @@ -576,10 +629,24 @@ "develop": { "astroid": { "hashes": [ - "sha256:35cfae47aac19c7b407b7095410e895e836f2285ccf1220336afba744cc4c5f2", - "sha256:38186e481b65877fd8b1f9acc33e922109e983eb7b6e487bd4c71002134ad331" + "sha256:b7787562a4757d7101ca6270a06e5246c1dcd1a4851d4bb2421a6baae4b09c1b", + "sha256:f14913e18b71e6a86e05aeec80b8bd09286dff8a6e34c3cc71d67fa3d726aec7" ], - "version": "==1.6.3" + "version": "==2.0.0.dev1" + }, + "atomicwrites": { + "hashes": [ + "sha256:240831ea22da9ab882b551b31d4225591e5e447a68c5e188db5b89ca1d487585", + "sha256:a24da68318b08ac9c9c45029f4a10371ab5b20e4226738e150e6e7c571630ae6" + ], + "version": "==1.1.5" + }, + "attrs": { + "hashes": [ + "sha256:4b90b09eeeb9b88c35bc642cbac057e45a5fd85367b985bd2809c62b7b939265", + "sha256:e0d0eb91441a3b53dab4d9b743eafc1ac44476296a2053b6ca3af0b139faf87b" + ], + "version": "==18.1.0" }, "isort": { "hashes": [ @@ -632,11 +699,11 @@ }, "more-itertools": { "hashes": [ - "sha256:0dd8f72eeab0d2c3bd489025bb2f6a1b8342f9b198f6fc37b52d15cfa4531fea", - "sha256:11a625025954c20145b37ff6309cd54e39ca94f72f6bb9576d1195db6fa2442e", - "sha256:c9ce7eccdcb901a2c75d326ea134e0886abfbea5f93e91cc95de9507c0816c44" + "sha256:2b6b9893337bfd9166bee6a62c2b0c9fe7735dcf85948b387ec8cba30e85d8e8", + "sha256:6703844a52d3588f951883005efcf555e49566a48afd4db4e965d69b883980d3", + "sha256:a18d870ef2ffca2b8463c0070ad17b5978056f403fb64e3f15fe62a52db21cc0" ], - "version": "==4.1.0" + "version": "==4.2.0" }, "pluggy": { "hashes": [ @@ -655,19 +722,18 @@ }, "pylint": { "hashes": [ - "sha256:0b7e6b5d9f1d4e0b554b5d948f14ed7969e8cdf9a0120853e6e5af60813b18ab", - "sha256:34738a82ab33cbd3bb6cd4cef823dbcabdd2b6b48a4e3a3054a2bbbf0c712be9" + "sha256:0990347c0f605927fadb2a9366a0b3d40bd19eb44e4312f0a1ef729a389b2f40", + "sha256:19b902f93f2dc3fa45565e54b88702b28379be40107f509a8516dde152460d1f" ], "index": "pypi", - "version": "==1.8.4" + "version": "==2.0.0.dev1" }, "pytest": { "hashes": [ - "sha256:6266f87ab64692112e5477eba395cfedda53b1933ccd29478e671e73b420c19c", - "sha256:fae491d1874f199537fd5872b5e1f0e74a009b979df9d53d1553fd03da1703e1" + "sha256:39555d023af3200d004d09e51b4dd9fdd828baa863cded3fd6ba2f29f757ae2d", + "sha256:c76e93f3145a44812955e8d46cdd302d8a45fbfc7bf22be24fe231f9d8d8853a" ], - "index": "pypi", - "version": "==3.5.0" + "version": "==3.6.0" }, "six": { "hashes": [ @@ -676,6 +742,30 @@ ], "version": "==1.11.0" }, + "typed-ast": { + "hashes": [ + "sha256:0948004fa228ae071054f5208840a1e88747a357ec1101c17217bfe99b299d58", + "sha256:25d8feefe27eb0303b73545416b13d108c6067b846b543738a25ff304824ed9a", + "sha256:29464a177d56e4e055b5f7b629935af7f49c196be47528cc94e0a7bf83fbc2b9", + "sha256:2e214b72168ea0275efd6c884b114ab42e316de3ffa125b267e732ed2abda892", + "sha256:3e0d5e48e3a23e9a4d1a9f698e32a542a4a288c871d33ed8df1b092a40f3a0f9", + "sha256:519425deca5c2b2bdac49f77b2c5625781abbaf9a809d727d3a5596b30bb4ded", + "sha256:57fe287f0cdd9ceaf69e7b71a2e94a24b5d268b35df251a88fef5cc241bf73aa", + "sha256:668d0cec391d9aed1c6a388b0d5b97cd22e6073eaa5fbaa6d2946603b4871efe", + "sha256:68ba70684990f59497680ff90d18e756a47bf4863c604098f10de9716b2c0bdd", + "sha256:6de012d2b166fe7a4cdf505eee3aaa12192f7ba365beeefaca4ec10e31241a85", + "sha256:79b91ebe5a28d349b6d0d323023350133e927b4de5b651a8aa2db69c761420c6", + "sha256:8550177fa5d4c1f09b5e5f524411c44633c80ec69b24e0e98906dd761941ca46", + "sha256:a8034021801bc0440f2e027c354b4eafd95891b573e12ff0418dec385c76785c", + "sha256:bc978ac17468fe868ee589c795d06777f75496b1ed576d308002c8a5756fb9ea", + "sha256:c05b41bc1deade9f90ddc5d988fe506208019ebba9f2578c622516fd201f5863", + "sha256:c9b060bd1e5a26ab6e8267fd46fc9e02b54eb15fffb16d112d4c7b1c12987559", + "sha256:edb04bdd45bfd76c8292c4d9654568efaedf76fe78eb246dde69bdb13b2dad87", + "sha256:f19f2a4f547505fe9072e15f6f4ae714af51b5a681a97f187971f50c283193b6" + ], + "markers": "python_version < '3.7'", + "version": "==1.1.0" + }, "wrapt": { "hashes": [ "sha256:d4d560d479f2c21e1b5443bbd15fe7ec4b37fe7e53d335d3b9b0a7b1226fe3c6" @@ -684,11 +774,11 @@ }, "yapf": { "hashes": [ - "sha256:7d8ae3567f3fb2d288f127d35e4decb3348c96cd091001e02e818465da618f90", - "sha256:dd23b52edbb4c0461d0383050f7886175b0df9ab8fd0b67edd41f94e25770993" + "sha256:6567745f0b6656f9c33a73c56a393071c699e6284a70d793798ab6e3769d25ec", + "sha256:a98a6eacca64d2b920558f4a2f78150db9474de821227e60deaa29f186121c63" ], "index": "pypi", - "version": "==0.21.0" + "version": "==0.22.0" } } } diff --git a/tox.ini b/tox.ini new file mode 100644 index 00000000..77a04f30 --- /dev/null +++ b/tox.ini @@ -0,0 +1,10 @@ +[tox] +envlist = py34,py35,py36 + +[testenv] +deps=pipenv +whitelist_externals = mkdir +commands= + pipenv install --dev --ignore-pipfile + mkdir -p {toxworkdir}/log/{envname} + pipenv run py.test --junitxml={toxworkdir}/output/pytest/junit-{envname}.xml {posargs} From 11a2bb7430506cc747b8998816307adac0749941 Mon Sep 17 00:00:00 2001 From: Josh Asplund Date: Mon, 4 Jun 2018 15:21:13 -0500 Subject: [PATCH 2/5] Fixes failing test and python version --- .circleci/config.yml | 37 ++++++++++++++++++++++------- .coveragerc | 3 --- tests/analysis/test_delegatecall.py | 9 ++++--- tox.ini | 23 +++++++++++++++--- 4 files changed, 52 insertions(+), 20 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index f8425ba9..6a9c809b 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -13,15 +13,24 @@ jobs: # Uncomment, for local testing with circleci command, as it ignores # path param in checkout command, and this symlink compenstates for that. - # - run: ln -s /root/project /home/mythril + # - run: ln -s /root/project /home/mythril + + - restore-cache: + keys: + - tox-env-{{ checksum "/home/mythril/tox.ini" }}-{{ checksum "/home/mythril/setup.py" }} - run: name: Installing mythril tools - command: cd /home && ./install-mythril-tools.sh laser-ethereum + command: ./install-mythril-tools.sh laser-ethereum + working_directory: /home - run: - name: Install dependencies, in case any are missing in Docker image - command: pip3 install -r /home/mythril/requirements.txt + name: Install tox envs + command: tox -vv --notest + working_directory: /home/mythril + environment: + LC_ALL: C.UTF-8 + LANG: C.UTF-8 - run: background: true @@ -30,7 +39,8 @@ jobs: - run: name: Unit-testing - command: cd /home/mythril && tox + command: tox + working_directory: /home/mythril environment: LC_ALL: C.UTF-8 LANG: C.UTF-8 @@ -41,9 +51,15 @@ jobs: - store_artifacts: path: /home/mythril/.tox/output + - save_cache: + key: tox-env-{{ checksum "/home/mythril/tox.ini" }}-{{ checksum "/home/mythril/setup.py" }} + paths: + - .tox/py* + - run: name: Ensuring that setup script is functional - command: cd /home/mythril && python3 setup.py install + command: python3 setup.py install + working_directory: /home/mythril - run: name: Integration tests @@ -56,13 +72,16 @@ jobs: path: /home/mythril - run: name: Verify Git tag vs. version - command: cd /home/mythril && python3 setup.py verify + command: python3 setup.py verify + working_directory: /home/mythril - run: name: Build - command: cd /home/mythril && python3 setup.py sdist + command: python3 setup.py sdist + working_directory: /home/mythril - run: name: Deploy - command: cd /home/mythril && twine upload dist/* + command: twine upload dist/* + working_directory: /home/mythril workflows: version: 2 diff --git a/.coveragerc b/.coveragerc index 20e1caf4..dbc23d33 100644 --- a/.coveragerc +++ b/.coveragerc @@ -8,6 +8,3 @@ omit = /usr/* *_test.py setup.py - -[html] -directory = coverage_html_report diff --git a/tests/analysis/test_delegatecall.py b/tests/analysis/test_delegatecall.py index 2f5c1a61..8849fb8d 100644 --- a/tests/analysis/test_delegatecall.py +++ b/tests/analysis/test_delegatecall.py @@ -3,8 +3,7 @@ from mythril.analysis.ops import Call, Variable, VarType from mythril.analysis.symbolic import SymExecWrapper from laser.ethereum.svm import GlobalState, Node, Environment, Account import pytest -import mock -from mock import patch +from unittest.mock import MagicMock, patch import pytest_mock @@ -185,7 +184,7 @@ def test_delegate_call(sym_mock, concrete_mock, curr_instruction): to = Variable("storage_1", VarType.SYMBOLIC) call = Call(node, state, None, "DELEGATECALL", to, None) - statespace = mock.MagicMock() + statespace = MagicMock() statespace.calls = [call] # act @@ -211,7 +210,7 @@ def test_delegate_call_not_delegate(sym_mock, concrete_mock): to = Variable("storage_1", VarType.SYMBOLIC) call = Call(node, None, None, "NOT_DELEGATECALL", to, None) - statespace = mock.MagicMock() + statespace = MagicMock() statespace.calls = [call] # act @@ -238,7 +237,7 @@ def test_delegate_call_not_fallback(sym_mock, concrete_mock): to = Variable("storage_1", VarType.SYMBOLIC) call = Call(node, None, None, "DELEGATECALL", to, None) - statespace = mock.MagicMock() + statespace = MagicMock() statespace.calls = [call] # act diff --git a/tox.ini b/tox.ini index 77a04f30..edb6f042 100644 --- a/tox.ini +++ b/tox.ini @@ -1,10 +1,27 @@ [tox] -envlist = py34,py35,py36 +envlist = py35,py36 [testenv] deps=pipenv whitelist_externals = mkdir commands= pipenv install --dev --ignore-pipfile - mkdir -p {toxworkdir}/log/{envname} - pipenv run py.test --junitxml={toxworkdir}/output/pytest/junit-{envname}.xml {posargs} + mkdir -p {toxinidir}/tests/testdata/outputs_current/ + py.test \ + --junitxml={toxworkdir}/output/junit-{envname}.xml \ + {posargs} + +[testenv:coverage] +setenv = + COVERAGE_FILE = .coveragerc +deps = pytest-cov +whitelist_externals = mkdir +commands= + pipenv install --dev --ignore-pipfile + mkdir -p {toxinidir}/tests/testdata/outputs_current/ + py.test \ + --cov=mythril \ + --cov-report=xml:{toxworkdir}/output/cov-{envname}.xml \ + --cov-report=html:{toxworkdir}/output/cov-{envname}.html \ + --junitxml={toxworkdir}/output/junit-{envname}.xml \ + {posargs} From f5a46ef7bcf6ba1a831f2508e7cb8b2c48129392 Mon Sep 17 00:00:00 2001 From: Josh Asplund Date: Mon, 4 Jun 2018 18:42:34 -0500 Subject: [PATCH 3/5] Fixes issues with python 3.5 dict ordering --- .circleci/config.yml | 11 +-- Pipfile | 1 + mythril/analysis/report.py | 16 +++-- .../templates/report_as_markdown.jinja2 | 2 +- .../analysis/templates/report_as_text.jinja2 | 2 +- tests/report_test.py | 46 +++++++++++- .../outputs_expected/calls.sol.o.markdown | 70 +++++++++---------- .../outputs_expected/calls.sol.o.text | 58 +++++++-------- .../outputs_expected/overflow.sol.o.markdown | 18 ++--- .../outputs_expected/overflow.sol.o.text | 18 ++--- .../outputs_expected/underflow.sol.o.markdown | 18 ++--- .../outputs_expected/underflow.sol.o.text | 18 ++--- tox.ini | 23 +++--- 13 files changed, 177 insertions(+), 124 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 6a9c809b..87320f71 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -32,6 +32,12 @@ jobs: LC_ALL: C.UTF-8 LANG: C.UTF-8 + - save_cache: + key: tox-env-{{ checksum "/home/mythril/tox.ini" }}-{{ checksum "/home/mythril/setup.py" }} + paths: + - .tox/py* + - /root/.cache/pip/wheels/ + - run: background: true name: Launch of background geth instance @@ -51,11 +57,6 @@ jobs: - store_artifacts: path: /home/mythril/.tox/output - - save_cache: - key: tox-env-{{ checksum "/home/mythril/tox.ini" }}-{{ checksum "/home/mythril/setup.py" }} - paths: - - .tox/py* - - run: name: Ensuring that setup script is functional command: python3 setup.py install diff --git a/Pipfile b/Pipfile index 459f1564..753481aa 100644 --- a/Pipfile +++ b/Pipfile @@ -11,6 +11,7 @@ pylint = "*" yapf = "*" pytest = "*" pytest-mock = "*" +pytest-cov = "*" [requires] diff --git a/mythril/analysis/report.py b/mythril/analysis/report.py index d82a2530..1e61092a 100644 --- a/mythril/analysis/report.py +++ b/mythril/analysis/report.py @@ -1,5 +1,6 @@ import hashlib import json +import operator from jinja2 import PackageLoader, Environment class Issue: @@ -45,25 +46,28 @@ class Report: self.verbose = verbose pass + def sorted_issues(self): + issue_list = [issue.as_dict() for key, issue in self.issues.items()] + return sorted(issue_list, key=operator.itemgetter('address', 'title')) + def append_issue(self, issue): m = hashlib.md5() m.update((issue.contract + str(issue.address) + issue.title).encode('utf-8')) self.issues[m.digest()] = issue def as_text(self): - filename = self._file_name() + name = self._file_name() template = Report.environment.get_template('report_as_text.jinja2') - return template.render(filename=filename, issues=self.issues, verbose=self.verbose) + return template.render(filename=name, issues=self.sorted_issues(), verbose=self.verbose) def as_json(self): - issues = [issue.as_dict() for key, issue in self.issues.items()] - result = {'success': True, 'error': None, 'issues': issues} - return json.dumps(result) + result = {'success': True, 'error': None, 'issues': self.sorted_issues()} + return json.dumps(result, sort_keys=True) def as_markdown(self): filename = self._file_name() template = Report.environment.get_template('report_as_markdown.jinja2') - return template.render(filename=filename, issues=self.issues, verbose=self.verbose) + return template.render(filename=filename, issues=self.sorted_issues(), verbose=self.verbose) def _file_name(self): if len(self.issues.values()) > 0: diff --git a/mythril/analysis/templates/report_as_markdown.jinja2 b/mythril/analysis/templates/report_as_markdown.jinja2 index 9ceb80a7..3f83245f 100644 --- a/mythril/analysis/templates/report_as_markdown.jinja2 +++ b/mythril/analysis/templates/report_as_markdown.jinja2 @@ -1,6 +1,6 @@ # Analysis results for {{ filename }} {% if issues %} -{% for key, issue in issues.items() %} +{% for issue in issues %} ## {{ issue.title }} diff --git a/mythril/analysis/templates/report_as_text.jinja2 b/mythril/analysis/templates/report_as_text.jinja2 index 1fb18e1a..7e7e1482 100644 --- a/mythril/analysis/templates/report_as_text.jinja2 +++ b/mythril/analysis/templates/report_as_text.jinja2 @@ -1,5 +1,5 @@ {% if issues %} -{% for key, issue in issues.items() %} +{% for issue in issues %} ==== {{ issue.title }} ==== Type: {{ issue.type }} Contract: {{ issue.contract | default("Unknown") }} diff --git a/tests/report_test.py b/tests/report_test.py index dae6cc4e..88d4c777 100644 --- a/tests/report_test.py +++ b/tests/report_test.py @@ -19,7 +19,7 @@ def _fix_debug_data(json_str): read_json = json.loads(json_str) for issue in read_json["issues"]: issue["debug"] = "" - return json.dumps(read_json, indent=4) + return json.dumps(read_json, sort_keys=True) def _generate_report(input_file): @@ -56,6 +56,29 @@ def _assert_empty(changed_files, postfix): assert message == "", message +def _assert_empty_json(changed_files): + """ Asserts there are no changed files and otherwise builds error message""" + postfix = ".json" + expected = [] + actual = [] + + def ordered(obj): + if isinstance(obj, dict): + return sorted((k, ordered(v)) for k, v in obj.items()) + elif isinstance(obj, list): + return sorted(ordered(x) for x in obj) + else: + return obj + + for input_file in changed_files: + output_expected = json.loads((TESTDATA_OUTPUTS_EXPECTED / (input_file.name + postfix)).read_text()) + output_current = json.loads((TESTDATA_OUTPUTS_CURRENT / (input_file.name + postfix)).read_text()) + + if not ordered(output_expected.items()) == ordered(output_current.items()): + expected.append(output_expected) + actual.append(output_current) + + assert expected == actual def _get_changed_files(postfix, report_builder, reports): """ @@ -74,8 +97,27 @@ def _get_changed_files(postfix, report_builder, reports): yield input_file +def _get_changed_files_json(report_builder, reports): + postfix = ".json" + def ordered(obj): + if isinstance(obj, dict): + return sorted((k, ordered(v)) for k, v in obj.items()) + elif isinstance(obj, list): + return sorted(ordered(x) for x in obj) + else: + return obj + + for report, input_file in reports: + output_expected = TESTDATA_OUTPUTS_EXPECTED / (input_file.name + postfix) + output_current = TESTDATA_OUTPUTS_CURRENT / (input_file.name + postfix) + output_current.write_text(report_builder(report)) + + if not ordered(json.loads(output_expected.read_text())) == ordered(json.loads(output_current.read_text())): + yield input_file + + def test_json_report(reports): - _assert_empty(_get_changed_files('.json', lambda report: _fix_path(_fix_debug_data(report.as_json())).strip(), reports), '.json') + _assert_empty_json(_get_changed_files_json(lambda report: _fix_path(_fix_debug_data(report.as_json())).strip(), reports)) def test_markdown_report(reports): diff --git a/tests/testdata/outputs_expected/calls.sol.o.markdown b/tests/testdata/outputs_expected/calls.sol.o.markdown index 7c75e616..02e69173 100644 --- a/tests/testdata/outputs_expected/calls.sol.o.markdown +++ b/tests/testdata/outputs_expected/calls.sol.o.markdown @@ -11,49 +11,27 @@ This contract executes a message call to to another contract. Make sure that the called contract is trusted and does not execute user-supplied code. -## Message call to external contract - -- Type: Warning -- Contract: Unknown -- Function name: `_function_0xd24b08cc` -- PC address: 779 - -### Description - -This contract executes a message call to an address found at storage slot 1. This storage slot can be written to by calling the function `_function_0x2776b163`. Generally, it is not recommended to call user-supplied addresses using Solidity's call() construct. Note that attackers might leverage reentrancy attacks to exploit race conditions or manipulate this contract's state. - -## Message call to external contract +## Unchecked CALL return value - Type: Informational - Contract: Unknown -- Function name: `_function_0xe11f493e` -- PC address: 858 - -### Description - -This contract executes a message call to to another contract. Make sure that the called contract is trusted and does not execute user-supplied code. - -## State change after external call - -- Type: Warning -- Contract: Unknown -- Function name: `_function_0xe11f493e` -- PC address: 869 +- Function name: `_function_0x5a6814ec` +- PC address: 661 ### Description -The contract account state is changed after an external call. Consider that the called contract could re-enter the function before this state change takes place. This can lead to business logic vulnerabilities. +The return value of an external call is not checked. Note that execution continue even if the called contract throws. ## Message call to external contract - Type: Warning - Contract: Unknown -- Function name: `_function_0xe1d10f79` -- PC address: 912 +- Function name: `_function_0xd24b08cc` +- PC address: 779 ### Description -This contract executes a message call to an address provided as a function argument. Generally, it is not recommended to call user-supplied addresses using Solidity's call() construct. Note that attackers might leverage reentrancy attacks to exploit race conditions or manipulate this contract's state. +This contract executes a message call to an address found at storage slot 1. This storage slot can be written to by calling the function `_function_0x2776b163`. Generally, it is not recommended to call user-supplied addresses using Solidity's call() construct. Note that attackers might leverage reentrancy attacks to exploit race conditions or manipulate this contract's state. ## Transaction order dependence @@ -70,23 +48,23 @@ A possible transaction order independence vulnerability exists in function _func - Type: Informational - Contract: Unknown -- Function name: `_function_0x5a6814ec` -- PC address: 661 +- Function name: `_function_0xd24b08cc` +- PC address: 779 ### Description The return value of an external call is not checked. Note that execution continue even if the called contract throws. -## Unchecked CALL return value +## Message call to external contract - Type: Informational - Contract: Unknown -- Function name: `_function_0xd24b08cc` -- PC address: 779 +- Function name: `_function_0xe11f493e` +- PC address: 858 ### Description -The return value of an external call is not checked. Note that execution continue even if the called contract throws. +This contract executes a message call to to another contract. Make sure that the called contract is trusted and does not execute user-supplied code. ## Unchecked CALL return value @@ -99,6 +77,28 @@ The return value of an external call is not checked. Note that execution continu The return value of an external call is not checked. Note that execution continue even if the called contract throws. +## State change after external call + +- Type: Warning +- Contract: Unknown +- Function name: `_function_0xe11f493e` +- PC address: 869 + +### Description + +The contract account state is changed after an external call. Consider that the called contract could re-enter the function before this state change takes place. This can lead to business logic vulnerabilities. + +## Message call to external contract + +- Type: Warning +- Contract: Unknown +- Function name: `_function_0xe1d10f79` +- PC address: 912 + +### Description + +This contract executes a message call to an address provided as a function argument. Generally, it is not recommended to call user-supplied addresses using Solidity's call() construct. Note that attackers might leverage reentrancy attacks to exploit race conditions or manipulate this contract's state. + ## Unchecked CALL return value - Type: Informational diff --git a/tests/testdata/outputs_expected/calls.sol.o.text b/tests/testdata/outputs_expected/calls.sol.o.text index c327fc14..efdfd1e4 100644 --- a/tests/testdata/outputs_expected/calls.sol.o.text +++ b/tests/testdata/outputs_expected/calls.sol.o.text @@ -6,36 +6,20 @@ PC address: 661 This contract executes a message call to to another contract. Make sure that the called contract is trusted and does not execute user-supplied code. -------------------- -==== Message call to external contract ==== -Type: Warning -Contract: Unknown -Function name: _function_0xd24b08cc -PC address: 779 -This contract executes a message call to an address found at storage slot 1. This storage slot can be written to by calling the function `_function_0x2776b163`. Generally, it is not recommended to call user-supplied addresses using Solidity's call() construct. Note that attackers might leverage reentrancy attacks to exploit race conditions or manipulate this contract's state. --------------------- - -==== Message call to external contract ==== +==== Unchecked CALL return value ==== Type: Informational Contract: Unknown -Function name: _function_0xe11f493e -PC address: 858 -This contract executes a message call to to another contract. Make sure that the called contract is trusted and does not execute user-supplied code. --------------------- - -==== State change after external call ==== -Type: Warning -Contract: Unknown -Function name: _function_0xe11f493e -PC address: 869 -The contract account state is changed after an external call. Consider that the called contract could re-enter the function before this state change takes place. This can lead to business logic vulnerabilities. +Function name: _function_0x5a6814ec +PC address: 661 +The return value of an external call is not checked. Note that execution continue even if the called contract throws. -------------------- ==== Message call to external contract ==== Type: Warning Contract: Unknown -Function name: _function_0xe1d10f79 -PC address: 912 -This contract executes a message call to an address provided as a function argument. Generally, it is not recommended to call user-supplied addresses using Solidity's call() construct. Note that attackers might leverage reentrancy attacks to exploit race conditions or manipulate this contract's state. +Function name: _function_0xd24b08cc +PC address: 779 +This contract executes a message call to an address found at storage slot 1. This storage slot can be written to by calling the function `_function_0x2776b163`. Generally, it is not recommended to call user-supplied addresses using Solidity's call() construct. Note that attackers might leverage reentrancy attacks to exploit race conditions or manipulate this contract's state. -------------------- ==== Transaction order dependence ==== @@ -49,17 +33,17 @@ A possible transaction order independence vulnerability exists in function _func ==== Unchecked CALL return value ==== Type: Informational Contract: Unknown -Function name: _function_0x5a6814ec -PC address: 661 +Function name: _function_0xd24b08cc +PC address: 779 The return value of an external call is not checked. Note that execution continue even if the called contract throws. -------------------- -==== Unchecked CALL return value ==== +==== Message call to external contract ==== Type: Informational Contract: Unknown -Function name: _function_0xd24b08cc -PC address: 779 -The return value of an external call is not checked. Note that execution continue even if the called contract throws. +Function name: _function_0xe11f493e +PC address: 858 +This contract executes a message call to to another contract. Make sure that the called contract is trusted and does not execute user-supplied code. -------------------- ==== Unchecked CALL return value ==== @@ -70,6 +54,22 @@ PC address: 858 The return value of an external call is not checked. Note that execution continue even if the called contract throws. -------------------- +==== State change after external call ==== +Type: Warning +Contract: Unknown +Function name: _function_0xe11f493e +PC address: 869 +The contract account state is changed after an external call. Consider that the called contract could re-enter the function before this state change takes place. This can lead to business logic vulnerabilities. +-------------------- + +==== Message call to external contract ==== +Type: Warning +Contract: Unknown +Function name: _function_0xe1d10f79 +PC address: 912 +This contract executes a message call to an address provided as a function argument. Generally, it is not recommended to call user-supplied addresses using Solidity's call() construct. Note that attackers might leverage reentrancy attacks to exploit race conditions or manipulate this contract's state. +-------------------- + ==== Unchecked CALL return value ==== Type: Informational Contract: Unknown diff --git a/tests/testdata/outputs_expected/overflow.sol.o.markdown b/tests/testdata/outputs_expected/overflow.sol.o.markdown index d2c8f9e6..07d375b8 100644 --- a/tests/testdata/outputs_expected/overflow.sol.o.markdown +++ b/tests/testdata/outputs_expected/overflow.sol.o.markdown @@ -5,33 +5,33 @@ - Type: Warning - Contract: Unknown - Function name: `sendeth(address,uint256)` -- PC address: 649 +- PC address: 567 ### Description A possible integer underflow exists in the function `sendeth(address,uint256)`. The subtraction may result in a value < 0. -## Integer Overflow +## Integer Underflow - Type: Warning - Contract: Unknown - Function name: `sendeth(address,uint256)` -- PC address: 725 +- PC address: 649 ### Description -A possible integer overflow exists in the function `sendeth(address,uint256)`. -The addition or multiplication may result in a value higher than the maximum representable integer. +A possible integer underflow exists in the function `sendeth(address,uint256)`. +The subtraction may result in a value < 0. -## Integer Underflow +## Integer Overflow - Type: Warning - Contract: Unknown - Function name: `sendeth(address,uint256)` -- PC address: 567 +- PC address: 725 ### Description -A possible integer underflow exists in the function `sendeth(address,uint256)`. -The subtraction may result in a value < 0. +A possible integer overflow exists in the function `sendeth(address,uint256)`. +The addition or multiplication may result in a value higher than the maximum representable integer. diff --git a/tests/testdata/outputs_expected/overflow.sol.o.text b/tests/testdata/outputs_expected/overflow.sol.o.text index a3ec68c4..f15d633f 100644 --- a/tests/testdata/outputs_expected/overflow.sol.o.text +++ b/tests/testdata/outputs_expected/overflow.sol.o.text @@ -2,26 +2,26 @@ Type: Warning Contract: Unknown Function name: sendeth(address,uint256) -PC address: 649 +PC address: 567 A possible integer underflow exists in the function `sendeth(address,uint256)`. The subtraction may result in a value < 0. -------------------- -==== Integer Overflow ==== +==== Integer Underflow ==== Type: Warning Contract: Unknown Function name: sendeth(address,uint256) -PC address: 725 -A possible integer overflow exists in the function `sendeth(address,uint256)`. -The addition or multiplication may result in a value higher than the maximum representable integer. +PC address: 649 +A possible integer underflow exists in the function `sendeth(address,uint256)`. +The subtraction may result in a value < 0. -------------------- -==== Integer Underflow ==== +==== Integer Overflow ==== Type: Warning Contract: Unknown Function name: sendeth(address,uint256) -PC address: 567 -A possible integer underflow exists in the function `sendeth(address,uint256)`. -The subtraction may result in a value < 0. +PC address: 725 +A possible integer overflow exists in the function `sendeth(address,uint256)`. +The addition or multiplication may result in a value higher than the maximum representable integer. -------------------- diff --git a/tests/testdata/outputs_expected/underflow.sol.o.markdown b/tests/testdata/outputs_expected/underflow.sol.o.markdown index d2c8f9e6..07d375b8 100644 --- a/tests/testdata/outputs_expected/underflow.sol.o.markdown +++ b/tests/testdata/outputs_expected/underflow.sol.o.markdown @@ -5,33 +5,33 @@ - Type: Warning - Contract: Unknown - Function name: `sendeth(address,uint256)` -- PC address: 649 +- PC address: 567 ### Description A possible integer underflow exists in the function `sendeth(address,uint256)`. The subtraction may result in a value < 0. -## Integer Overflow +## Integer Underflow - Type: Warning - Contract: Unknown - Function name: `sendeth(address,uint256)` -- PC address: 725 +- PC address: 649 ### Description -A possible integer overflow exists in the function `sendeth(address,uint256)`. -The addition or multiplication may result in a value higher than the maximum representable integer. +A possible integer underflow exists in the function `sendeth(address,uint256)`. +The subtraction may result in a value < 0. -## Integer Underflow +## Integer Overflow - Type: Warning - Contract: Unknown - Function name: `sendeth(address,uint256)` -- PC address: 567 +- PC address: 725 ### Description -A possible integer underflow exists in the function `sendeth(address,uint256)`. -The subtraction may result in a value < 0. +A possible integer overflow exists in the function `sendeth(address,uint256)`. +The addition or multiplication may result in a value higher than the maximum representable integer. diff --git a/tests/testdata/outputs_expected/underflow.sol.o.text b/tests/testdata/outputs_expected/underflow.sol.o.text index a3ec68c4..f15d633f 100644 --- a/tests/testdata/outputs_expected/underflow.sol.o.text +++ b/tests/testdata/outputs_expected/underflow.sol.o.text @@ -2,26 +2,26 @@ Type: Warning Contract: Unknown Function name: sendeth(address,uint256) -PC address: 649 +PC address: 567 A possible integer underflow exists in the function `sendeth(address,uint256)`. The subtraction may result in a value < 0. -------------------- -==== Integer Overflow ==== +==== Integer Underflow ==== Type: Warning Contract: Unknown Function name: sendeth(address,uint256) -PC address: 725 -A possible integer overflow exists in the function `sendeth(address,uint256)`. -The addition or multiplication may result in a value higher than the maximum representable integer. +PC address: 649 +A possible integer underflow exists in the function `sendeth(address,uint256)`. +The subtraction may result in a value < 0. -------------------- -==== Integer Underflow ==== +==== Integer Overflow ==== Type: Warning Contract: Unknown Function name: sendeth(address,uint256) -PC address: 567 -A possible integer underflow exists in the function `sendeth(address,uint256)`. -The subtraction may result in a value < 0. +PC address: 725 +A possible integer overflow exists in the function `sendeth(address,uint256)`. +The addition or multiplication may result in a value higher than the maximum representable integer. -------------------- diff --git a/tox.ini b/tox.ini index edb6f042..a00a43a4 100644 --- a/tox.ini +++ b/tox.ini @@ -1,27 +1,32 @@ [tox] -envlist = py35,py36 +envlist = py36 [testenv] -deps=pipenv +deps = + pytest + pytest-mock whitelist_externals = mkdir -commands= - pipenv install --dev --ignore-pipfile +commands = mkdir -p {toxinidir}/tests/testdata/outputs_current/ - py.test \ + py.test -v \ --junitxml={toxworkdir}/output/junit-{envname}.xml \ + --junitprefix={envname} \ {posargs} [testenv:coverage] setenv = COVERAGE_FILE = .coveragerc -deps = pytest-cov +deps = + pytest + pytest-mock + pytest-cov whitelist_externals = mkdir -commands= - pipenv install --dev --ignore-pipfile +commands = mkdir -p {toxinidir}/tests/testdata/outputs_current/ - py.test \ + py.test -v \ --cov=mythril \ --cov-report=xml:{toxworkdir}/output/cov-{envname}.xml \ --cov-report=html:{toxworkdir}/output/cov-{envname}.html \ --junitxml={toxworkdir}/output/junit-{envname}.xml \ + --junitprefix={envname} \ {posargs} From 1790f6433612771937ebd10feb06b7358451d6fa Mon Sep 17 00:00:00 2001 From: Josh Asplund Date: Tue, 5 Jun 2018 14:08:13 -0500 Subject: [PATCH 4/5] Adds coverage to test suite --- .circleci/config.yml | 4 ++-- tox.ini | 15 +++++++-------- 2 files changed, 9 insertions(+), 10 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 87320f71..e7bed2c4 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -17,7 +17,7 @@ jobs: - restore-cache: keys: - - tox-env-{{ checksum "/home/mythril/tox.ini" }}-{{ checksum "/home/mythril/setup.py" }} + - tox-env-{{ checksum "/home/mythril/setup.py" }} - run: name: Installing mythril tools @@ -33,7 +33,7 @@ jobs: LANG: C.UTF-8 - save_cache: - key: tox-env-{{ checksum "/home/mythril/tox.ini" }}-{{ checksum "/home/mythril/setup.py" }} + key: tox-env-{{ checksum "/home/mythril/setup.py" }} paths: - .tox/py* - /root/.cache/pip/wheels/ diff --git a/tox.ini b/tox.ini index a00a43a4..d30f2d50 100644 --- a/tox.ini +++ b/tox.ini @@ -9,13 +9,13 @@ whitelist_externals = mkdir commands = mkdir -p {toxinidir}/tests/testdata/outputs_current/ py.test -v \ - --junitxml={toxworkdir}/output/junit-{envname}.xml \ - --junitprefix={envname} \ + --junitxml={toxworkdir}/output/{envname}/junit.xml \ {posargs} -[testenv:coverage] +[testenv:py36] +basepython = python3.6 setenv = - COVERAGE_FILE = .coveragerc + COVERAGE_FILE = .coverage.{envname} deps = pytest pytest-mock @@ -25,8 +25,7 @@ commands = mkdir -p {toxinidir}/tests/testdata/outputs_current/ py.test -v \ --cov=mythril \ - --cov-report=xml:{toxworkdir}/output/cov-{envname}.xml \ - --cov-report=html:{toxworkdir}/output/cov-{envname}.html \ - --junitxml={toxworkdir}/output/junit-{envname}.xml \ - --junitprefix={envname} \ + --cov-report=xml:{toxworkdir}/output/{envname}/coverage.xml \ + --cov-report=html:{toxworkdir}/output/{envname}/covhtml \ + --junitxml={toxworkdir}/output/{envname}/junit.xml \ {posargs} From 756bd1ebe72b5aee5e9efeb30f8cd6469995c2d6 Mon Sep 17 00:00:00 2001 From: Josh Asplund Date: Wed, 6 Jun 2018 13:07:26 -0500 Subject: [PATCH 5/5] Simplifies Circle config and coverage --- .circleci/config.yml | 3 +- .coveragerc | 10 - .gitignore | 1 - Pipfile.lock | 784 ------------------------------------------- coverage_report.sh | 7 +- tox.ini | 8 + 6 files changed, 14 insertions(+), 799 deletions(-) delete mode 100644 .coveragerc delete mode 100644 Pipfile.lock diff --git a/.circleci/config.yml b/.circleci/config.yml index e7bed2c4..91f9166e 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -64,7 +64,8 @@ jobs: - run: name: Integration tests - command: if [ -z "$CIRCLE_PR_NUMBER" ]; then cd /home && ./run-integration-tests.sh; fi + command: if [ -z "$CIRCLE_PR_NUMBER" ]; then ./run-integration-tests.sh; fi + working_directory: /home deploy: <<: *defaults diff --git a/.coveragerc b/.coveragerc deleted file mode 100644 index dbc23d33..00000000 --- a/.coveragerc +++ /dev/null @@ -1,10 +0,0 @@ -[run] -source = - . - -[report] -omit = - *__init__.py - /usr/* - *_test.py - setup.py diff --git a/.gitignore b/.gitignore index 1c81bd7c..38981e78 100644 --- a/.gitignore +++ b/.gitignore @@ -170,7 +170,6 @@ $RECYCLE.BIN/ *.asm *.rst *.lock -!Pipfile.lock *.svg laser* lol* diff --git a/Pipfile.lock b/Pipfile.lock deleted file mode 100644 index 72a7422d..00000000 --- a/Pipfile.lock +++ /dev/null @@ -1,784 +0,0 @@ -{ - "_meta": { - "hash": { - "sha256": "54df73f8f1c17c3992638c8199c50acdf7b424476332de73f0e2b13cf086e2e0" - }, - "pipfile-spec": 6, - "requires": {}, - "sources": [ - { - "name": "pypi", - "url": "https://pypi.python.org/simple", - "verify_ssl": true - } - ] - }, - "default": { - "asn1crypto": { - "hashes": [ - "sha256:2f1adbb7546ed199e3c90ef23ec95c5cf3585bac7d11fb7eb562a3fe89c64e87", - "sha256:9d5c20441baf0cb60a4ac34cc447c6c189024b6b4c6cd7877034f4965c464e49" - ], - "version": "==0.24.0" - }, - "atomicwrites": { - "hashes": [ - "sha256:240831ea22da9ab882b551b31d4225591e5e447a68c5e188db5b89ca1d487585", - "sha256:a24da68318b08ac9c9c45029f4a10371ab5b20e4226738e150e6e7c571630ae6" - ], - "version": "==1.1.5" - }, - "attrdict": { - "hashes": [ - "sha256:86aeb6d3809e0344409f8148d7cac9eabce5f0b577c160b5e90d10df3f8d2ad3" - ], - "version": "==2.0.0" - }, - "attrs": { - "hashes": [ - "sha256:4b90b09eeeb9b88c35bc642cbac057e45a5fd85367b985bd2809c62b7b939265", - "sha256:e0d0eb91441a3b53dab4d9b743eafc1ac44476296a2053b6ca3af0b139faf87b" - ], - "version": "==18.1.0" - }, - "btrees": { - "hashes": [ - "sha256:0b100e41ad3a0d16b8f07794af14acaf92b87ff5f4f1d942dc50f3f8105b2e67", - "sha256:147d3fd20c18200223c6c56316f352668858046afbd834dae464b7f73bedd53a", - "sha256:1b00572984986159db187a9d6cec3bcf48362d4162e72f53a3df362c53254c54", - "sha256:241cc088bc81c3977b7deb9b2f2239b82da814676affe6248d6df51744bc94fe", - "sha256:37e1529d3bd3257fa6b724383fef1a3420b16e2e3ce7d97b32cd7a8d5d3020af", - "sha256:399090e43c9ebf525a5cdced8fac18da3243cd78382333eae431ef3b2a6ae219", - "sha256:46b02cb69b26a5238db771ea1955b503df73ecf254bb8063af4c61999fc75b5c", - "sha256:4986f7ea25013e0370d88a4699490f83da92745705001b3d619de7d9600edc66", - "sha256:4996f282254bc30ab3855df4b757a675d043edf069368ac8e9ac1fadcaebb89b", - "sha256:4c77eed4ae3e182de559296893ae00b8da3201d51c51751787b53b34ac3b1a79", - "sha256:5e1831187360b78cc05d906e17944bef21583a1541506a26af3b6f25baaab208", - "sha256:64d655824d654d54021d65795e7c9d6f5d21a2427199c7dc0a25d259801f90f1", - "sha256:71235ac01a2f7989bce49f9bb9c0b43e5f19a3dbc2df51ad646950ee541b99a8", - "sha256:7f9dc2e73c46df0ece533bf432c1d54816eb94d3c7cd14e05c53a78addf61898", - "sha256:81039fb3060434036776da02b38b4b0872589377a873f432dad20f0c44f47f3c", - "sha256:888c016774630b7be2339888df1d0e7c91e1e0139e1b9ec80309feb1fc6fd9ec", - "sha256:895e5d173dd77989d8b9b9649e01a2509c6553ca3820c15f058e129fcbdab88c", - "sha256:8fcf0a87057c2558e5456aba6094ba3cf8a3641484608dbe86e7573d23e98b91", - "sha256:a80c5f14eac095502b5ba6adfdbea7a891dc5d761efeef75d11c2dbed7a9e5f0", - "sha256:acfdd66a3db6753cec1a06345fbef27b4cc592e269dfc162fa1f881230d1addc", - "sha256:b47db60a25cea6af29869e0a923705df71079137a99c9061008768c399ec4cd4", - "sha256:c8bf40f9f3078d373e71042198fefdd0588775df5f5e5a97525f2c32d0653c43", - "sha256:df8a059fc7c43ae34c47806be00021432988efdc8b24e8422fa6a785c9c78150" - ], - "version": "==4.5.0" - }, - "certifi": { - "hashes": [ - "sha256:13e698f54293db9f89122b0581843a782ad0934a4fe0172d2a980ba77fc61bb7", - "sha256:9fa520c1bacfb634fa7af20a76bcbd3d5fb390481724c597da32c719a7dca4b0" - ], - "version": "==2018.4.16" - }, - "cffi": { - "hashes": [ - "sha256:151b7eefd035c56b2b2e1eb9963c90c6302dc15fbd8c1c0a83a163ff2c7d7743", - "sha256:1553d1e99f035ace1c0544050622b7bc963374a00c467edafac50ad7bd276aef", - "sha256:1b0493c091a1898f1136e3f4f991a784437fac3673780ff9de3bcf46c80b6b50", - "sha256:2ba8a45822b7aee805ab49abfe7eec16b90587f7f26df20c71dd89e45a97076f", - "sha256:3c85641778460581c42924384f5e68076d724ceac0f267d66c757f7535069c93", - "sha256:3eb6434197633b7748cea30bf0ba9f66727cdce45117a712b29a443943733257", - "sha256:4c91af6e967c2015729d3e69c2e51d92f9898c330d6a851bf8f121236f3defd3", - "sha256:770f3782b31f50b68627e22f91cb182c48c47c02eb405fd689472aa7b7aa16dc", - "sha256:79f9b6f7c46ae1f8ded75f68cf8ad50e5729ed4d590c74840471fc2823457d04", - "sha256:7a33145e04d44ce95bcd71e522b478d282ad0eafaf34fe1ec5bbd73e662f22b6", - "sha256:857959354ae3a6fa3da6651b966d13b0a8bed6bbc87a0de7b38a549db1d2a359", - "sha256:87f37fe5130574ff76c17cab61e7d2538a16f843bb7bca8ebbc4b12de3078596", - "sha256:95d5251e4b5ca00061f9d9f3d6fe537247e145a8524ae9fd30a2f8fbce993b5b", - "sha256:9d1d3e63a4afdc29bd76ce6aa9d58c771cd1599fbba8cf5057e7860b203710dd", - "sha256:a36c5c154f9d42ec176e6e620cb0dd275744aa1d804786a71ac37dc3661a5e95", - "sha256:ae5e35a2c189d397b91034642cb0eab0e346f776ec2eb44a49a459e6615d6e2e", - "sha256:b0f7d4a3df8f06cf49f9f121bead236e328074de6449866515cea4907bbc63d6", - "sha256:b75110fb114fa366b29a027d0c9be3709579602ae111ff61674d28c93606acca", - "sha256:ba5e697569f84b13640c9e193170e89c13c6244c24400fc57e88724ef610cd31", - "sha256:be2a9b390f77fd7676d80bc3cdc4f8edb940d8c198ed2d8c0be1319018c778e1", - "sha256:d5d8555d9bfc3f02385c1c37e9f998e2011f0db4f90e250e5bc0c0a85a813085", - "sha256:e55e22ac0a30023426564b1059b035973ec82186ddddbac867078435801c7801", - "sha256:e90f17980e6ab0f3c2f3730e56d1fe9bcba1891eeea58966e89d352492cc74f4", - "sha256:ecbb7b01409e9b782df5ded849c178a0aa7c906cf8c5a67368047daab282b184", - "sha256:ed01918d545a38998bfa5902c7c00e0fee90e957ce036a4000a88e3fe2264917", - "sha256:edabd457cd23a02965166026fd9bfd196f4324fe6032e866d0f3bd0301cd486f", - "sha256:fdf1c1dc5bafc32bc5d08b054f94d659422b05aba244d6be4ddc1c72d9aa70fb" - ], - "version": "==1.11.5" - }, - "chardet": { - "hashes": [ - "sha256:84ab92ed1c4d4f16916e05906b6b75a6c0fb5db821cc65e70cbd64a3e2a5eaae", - "sha256:fc323ffcaeaed0e0a02bf4d117757b98aed530d9ed4531e3e15460124c106691" - ], - "version": "==3.0.4" - }, - "coincurve": { - "hashes": [ - "sha256:14f775b2a2034661ba125655529c883ba09936d16edd2edd28714d9be6ed7ca8", - "sha256:23bb379ab641423aea822effc3c63f06893f126cfd877e310382549048b6c4a6", - "sha256:29252b639e4c86d258cd01f747a8a00bc3e0533606e04cd1716af4b27cdcfe35", - "sha256:59bf263ce47e25865ea3491fa4d2d075ca3feb77d5ba961e95124d20b97916f8", - "sha256:605e73623f3b4d7a041af8032d55902fbb6b36151db427bad1655493a9bafcb3", - "sha256:683efd4f0ee89fa15ce7d6c4bb0cb48c86178f66a5d8538698ffdad8a079df3a", - "sha256:76b8c2738c9535223248c8da2b71de791b50ef18b6b8f1cd11b16242af9096b2", - "sha256:7afa48c11124b1d14baf63ef543e3438af0d8ba82b580f7a3b0c82b1fae2c697", - "sha256:7d66d081f46ce0e2c63d55cc791e7c1e6b0115eaee3c965edc0fb4f93d541537", - "sha256:7eaaa1d73084ed3436d64096dd8a22fd76a58f3cdbf5e3e3b949e73e694e17b6", - "sha256:9f565ca651e4304387460d8230cd8cc23ccea97c4a03f260b6b6238728516122", - "sha256:ad41b88ceffb953f4abc8c2b09123aeb4ba2f6949301ba1a8908832415f38255", - "sha256:ca8008b6c32726f15a50c3e9bac81c22d370b466377b21a8104e263610e90d94", - "sha256:ed671ecef3eb69aa46f1805d136b793a627fce94fc90d20f86ac5a357e00c08f" - ], - "version": "==7.1.0" - }, - "coverage": { - "hashes": [ - "sha256:03481e81d558d30d230bc12999e3edffe392d244349a90f4ef9b88425fac74ba", - "sha256:0b136648de27201056c1869a6c0d4e23f464750fd9a9ba9750b8336a244429ed", - "sha256:104ab3934abaf5be871a583541e8829d6c19ce7bde2923b2751e0d3ca44db60a", - "sha256:15b111b6a0f46ee1a485414a52a7ad1d703bdf984e9ed3c288a4414d3871dcbd", - "sha256:198626739a79b09fa0a2f06e083ffd12eb55449b5f8bfdbeed1df4910b2ca640", - "sha256:1c383d2ef13ade2acc636556fd544dba6e14fa30755f26812f54300e401f98f2", - "sha256:28b2191e7283f4f3568962e373b47ef7f0392993bb6660d079c62bd50fe9d162", - "sha256:2eb564bbf7816a9d68dd3369a510be3327f1c618d2357fa6b1216994c2e3d508", - "sha256:337ded681dd2ef9ca04ef5d93cfc87e52e09db2594c296b4a0a3662cb1b41249", - "sha256:3a2184c6d797a125dca8367878d3b9a178b6fdd05fdc2d35d758c3006a1cd694", - "sha256:3c79a6f7b95751cdebcd9037e4d06f8d5a9b60e4ed0cd231342aa8ad7124882a", - "sha256:3d72c20bd105022d29b14a7d628462ebdc61de2f303322c0212a054352f3b287", - "sha256:3eb42bf89a6be7deb64116dd1cc4b08171734d721e7a7e57ad64cc4ef29ed2f1", - "sha256:4635a184d0bbe537aa185a34193898eee409332a8ccb27eea36f262566585000", - "sha256:56e448f051a201c5ebbaa86a5efd0ca90d327204d8b059ab25ad0f35fbfd79f1", - "sha256:5a13ea7911ff5e1796b6d5e4fbbf6952381a611209b736d48e675c2756f3f74e", - "sha256:69bf008a06b76619d3c3f3b1983f5145c75a305a0fea513aca094cae5c40a8f5", - "sha256:6bc583dc18d5979dc0f6cec26a8603129de0304d5ae1f17e57a12834e7235062", - "sha256:701cd6093d63e6b8ad7009d8a92425428bc4d6e7ab8d75efbb665c806c1d79ba", - "sha256:7608a3dd5d73cb06c531b8925e0ef8d3de31fed2544a7de6c63960a1e73ea4bc", - "sha256:76ecd006d1d8f739430ec50cc872889af1f9c1b6b8f48e29941814b09b0fd3cc", - "sha256:7aa36d2b844a3e4a4b356708d79fd2c260281a7390d678a10b91ca595ddc9e99", - "sha256:7d3f553904b0c5c016d1dad058a7554c7ac4c91a789fca496e7d8347ad040653", - "sha256:7e1fe19bd6dce69d9fd159d8e4a80a8f52101380d5d3a4d374b6d3eae0e5de9c", - "sha256:8c3cb8c35ec4d9506979b4cf90ee9918bc2e49f84189d9bf5c36c0c1119c6558", - "sha256:9d6dd10d49e01571bf6e147d3b505141ffc093a06756c60b053a859cb2128b1f", - "sha256:9e112fcbe0148a6fa4f0a02e8d58e94470fc6cb82a5481618fea901699bf34c4", - "sha256:ac4fef68da01116a5c117eba4dd46f2e06847a497de5ed1d64bb99a5fda1ef91", - "sha256:b8815995e050764c8610dbc82641807d196927c3dbed207f0a079833ffcf588d", - "sha256:be6cfcd8053d13f5f5eeb284aa8a814220c3da1b0078fa859011c7fffd86dab9", - "sha256:c1bb572fab8208c400adaf06a8133ac0712179a334c09224fb11393e920abcdd", - "sha256:de4418dadaa1c01d497e539210cb6baa015965526ff5afc078c57ca69160108d", - "sha256:e05cb4d9aad6233d67e0541caa7e511fa4047ed7750ec2510d466e806e0255d6", - "sha256:e4d96c07229f58cb686120f168276e434660e4358cc9cf3b0464210b04913e77", - "sha256:f3f501f345f24383c0000395b26b726e46758b71393267aeae0bd36f8b3ade80", - "sha256:f8a923a85cb099422ad5a2e345fe877bbc89a8a8b23235824a93488150e45f6e" - ], - "version": "==4.5.1" - }, - "cytoolz": { - "hashes": [ - "sha256:84cc06fa40aa310f2df79dd440fc5f84c3e20f01f9f7783fc9c38d0a11ba00e5" - ], - "version": "==0.9.0.1" - }, - "dictionaries": { - "hashes": [ - "sha256:1ec6d4b2e2c5762a7423f66a3b423bc976439137e1537df5a164ea040abca2cb", - "sha256:26e0c57694d5e01b648c058939d69fbdc6d0caf04cd5b70cb7b4a69e577c1c31" - ], - "version": "==0.0.1" - }, - "e1839a8": { - "editable": true, - "path": "." - }, - "eth-abi": { - "hashes": [ - "sha256:717f33b654fdaed61c3276d26bfa6ca2006ce3254c98d6c8ed0ac645acd5b34b", - "sha256:a0a9bd9c6985f7d696c195911f097ec70adc2199553f61ac6236c7066eea5ba9" - ], - "version": "==1.1.1" - }, - "eth-account": { - "hashes": [ - "sha256:165aa14c18526247c044221565fa6ef27332928abe5930aa949b207d6d6ac248", - "sha256:a94823dbc5f8b66e0466c388c7b1b61dde06d64982b75d4b956512915f56f3f0" - ], - "version": "==0.2.3" - }, - "eth-hash": { - "hashes": [ - "sha256:30536f6057128c9130598103fb574a6a3d75d482bda0b13c5488f2f68d9a1423", - "sha256:42e6604e879b998002c915c1061ab317927329d7f47d3cbb80b83132dc7b58a4" - ], - "version": "==0.1.4" - }, - "eth-keyfile": { - "hashes": [ - "sha256:70d734af17efdf929a90bb95375f43522be4ed80c3b9e0a8bca575fb11cd1159", - "sha256:939540efb503380bc30d926833e6a12b22c6750de80feef3720d79e5a79de47d" - ], - "version": "==0.5.1" - }, - "eth-keys": { - "hashes": [ - "sha256:5ab2612f457452dc0a318655051cdd05c20f4db2f445003a46c98d324101b0e4", - "sha256:b48fc92a527bd905525855ebe45e79ba17be6654c4bedb947119648c145c74c0" - ], - "version": "==0.2.0b3" - }, - "eth-rlp": { - "hashes": [ - "sha256:05d8456981d85e16a9afa57f2f2c3356af5d1c49499cc8512cfcdc034b90dde5", - "sha256:a94744c207ea731a7266bd0894179dc6e51a6a8965316000c8e823b5d7e07694" - ], - "version": "==0.1.2" - }, - "eth-tester": { - "hashes": [ - "sha256:a3cb5076de16dfea1e08abe55a33ff4e0528fd1be2661e60823cfed24d466ad0", - "sha256:c88ae348436c331ebf90ae066fbbd468ed699474b5ce59731b78d3034e0066f6" - ], - "version": "==0.1.0b26" - }, - "eth-utils": { - "hashes": [ - "sha256:0eb71bdafda7e7e4c80ba98c06b3f89472e8ba0183a149be678f13cbb3b2e9b4", - "sha256:add4cc71b64e40b15c1e7b037905daf59da58e046004bde7a2915f86a7fc8e57" - ], - "version": "==1.0.3" - }, - "ethereum": { - "hashes": [ - "sha256:69a22c2f793970d184777bb92589e67d0f622d56eda7c3c1bfc1f0edad522c1c" - ], - "version": "==2.3.1" - }, - "future": { - "hashes": [ - "sha256:e39ced1ab767b5936646cedba8bcce582398233d6a627067d4c6a454c90cfedb" - ], - "version": "==0.16.0" - }, - "hexbytes": { - "hashes": [ - "sha256:27cc227ae95fc20d44325ac0329a0293d656a05230da079650705030c7d7a819", - "sha256:67e5608cb4a14d0a4ced058e595bb1f70c207ef2b5219fdc82af10e54bcf38de" - ], - "version": "==0.1.0" - }, - "idna": { - "hashes": [ - "sha256:2c6a5de3089009e3da7c5dde64a141dbc8551d5b7f6cf4ed7c2568d0cc520a8f", - "sha256:8c7309c718f94b3a625cb648ace320157ad16ff131ae0af362c9f21b80ef6ec4" - ], - "version": "==2.6" - }, - "jinja2": { - "hashes": [ - "sha256:74c935a1b8bb9a3947c50a54766a969d4846290e1e788ea44c1392163723c3bd", - "sha256:f84be1bb0040caca4cea721fcbbbbd61f9be9464ca236387158b0feea01914a4" - ], - "version": "==2.10" - }, - "laser-ethereum": { - "hashes": [ - "sha256:c92e877039af22338b5632cfdb17f27036e79eed3e15570c897593f033a24d6c" - ], - "version": "==0.17.12" - }, - "markupsafe": { - "hashes": [ - "sha256:a6be69091dac236ea9c6bc7d012beab42010fa914c459791d627dad4910eb665" - ], - "version": "==1.0" - }, - "more-itertools": { - "hashes": [ - "sha256:2b6b9893337bfd9166bee6a62c2b0c9fe7735dcf85948b387ec8cba30e85d8e8", - "sha256:6703844a52d3588f951883005efcf555e49566a48afd4db4e965d69b883980d3", - "sha256:a18d870ef2ffca2b8463c0070ad17b5978056f403fb64e3f15fe62a52db21cc0" - ], - "version": "==4.2.0" - }, - "parsimonious": { - "hashes": [ - "sha256:ae0869d72a6e57703f24313a5f5748e73ebff836e6fe8b3ddf34ea0dc00d086b" - ], - "version": "==0.8.0" - }, - "pbkdf2": { - "hashes": [ - "sha256:ac6397369f128212c43064a2b4878038dab78dab41875364554aaf2a684e6979" - ], - "version": "==1.3" - }, - "persistent": { - "hashes": [ - "sha256:1d01c21746a5583c025800a312815c61ca1010a4b39f2b5e072f5b8edbee27df", - "sha256:26060716176a6fe0e1459f06c7d165950a0caca9793b2a511ad6b054d7d154ff", - "sha256:2890566acc8dd8e08407e119ea926fa41ca71f3fe83918303bc86f895e588f65", - "sha256:2d5e67ee369610f3198b566b3bae22436248bc42d51d3e283662b60defe568f2", - "sha256:3190e88b9717e8368e4f6b82a706cdb475ebbdc499023c9a0f1967de4e08f902", - "sha256:46d62295a2ee2ed3eefccef5d47d21fc616a6c1113ee1f6063c9b8061abb84d0", - "sha256:4766d57e225b5b6c2a120c80de2e383dec05daaf0406ceb8cde0cc94524e6eae", - "sha256:4a6b9c1ee2bb220197be8847f331d714a5a0ad63ce5b86cb29bc7fa77d7e7a41", - "sha256:4eb5be9f1318883ab71110a3c1844a08d5bbdf52428f2c7dec382ae83938d90c", - "sha256:52c751883ab367b4b150a3ec7b85847c18f9d0b64891b7426e851d3b46f1bbe0", - "sha256:56a1f80dd89cfd0e9cf90cf8034653a218ae996f09f9c23ad0050aafb45dde7c", - "sha256:59a9f2b3baab9bfc4780325b01f4136064411f008b07bfdc9a5100c7cd6c1404", - "sha256:7fe9f29b3cdeb528013692870f94d89bf2a6492a78ba07a0cda204f1fd133b7b", - "sha256:864113a235652a01f5c453ace560683688539a50706c6cfac920d610658794dc", - "sha256:8aed3d08a9f4935fbf46d50cc6865cec0075040b53df2d2a76f5f9512c8bb05f", - "sha256:90afcfa3b2d1f91635fcb161091f509fb345237dae6cdc98f8215e829d1c932f", - "sha256:994be774f65669ebea6429017aeea0e98627a2b830745378e160d3320873c226", - "sha256:9dff9299be1e486ab4cb89a6eddb07d0fb6176be230a6b62094acf1e40f0cd19", - "sha256:a55bfeb2977364efee0687f3b7b9d3ec83c2fe65018e26938ed0386717d47bc1", - "sha256:a5f70dffa8d252ac2f0cc7c5b86f4db32bedeee8c413b9e2289921d103217370", - "sha256:b4b8d1e6e9eb68360b244cdaffa916aa60fde2b7881f9268adc7118291f77443", - "sha256:bd05ab36bbffe099819135bbe8dd8b7da9f8eddbd2be50ee0250c504b8522604", - "sha256:cc61af5e11ad4516773f6791ba8cee5c1085c2fd58b1d5d7ef54250fc46dc396", - "sha256:cf264cd55866c7ffbcbe1328f8d8b28fd042a5dd0c03a03f68c0887df3aa1964", - "sha256:d77a0c6139b3fcd32c684e1a23666c5076ea9fcf4c2eecc564b98d5254d930e0", - "sha256:e91af0b256b9f593c28f95ad2422757c170120734aafbfda2402242ee120c18c", - "sha256:ef28d3874e076cad9e1392ca33e1320da21dcfa33d6dfae804324fbb5c656724", - "sha256:f1d3a571128391baacb844725dd7a7d355fdbf556434fc1a1b00b8edfc12bf50" - ], - "version": "==4.2.4.2" - }, - "pluggy": { - "hashes": [ - "sha256:7f8ae7f5bdf75671a718d2daf0a64b7885f74510bcd98b1a0bb420eb9a9d0cff", - "sha256:d345c8fe681115900d6da8d048ba67c25df42973bda370783cd58826442dcd7c", - "sha256:e160a7fcf25762bb60efc7e171d4497ff1d8d2d75a3d0df7a21b76821ecbf5c5" - ], - "version": "==0.6.0" - }, - "plyvel": { - "hashes": [ - "sha256:059d5689ffe078061edfb12fe9251abcac9996aa20cfec9049fdd7391c8ed742", - "sha256:134e78519403a6f71f1e66df945763413c48d0f6dec02e1a61f55adf0f83106d", - "sha256:368eb22344cfe0e5c4ab64b7ec970c02b3c99150cb595bd7e15a66287cd0dd11", - "sha256:a2f2ac289893fb7b43108528e557ce4c079e938883a1db12279e02b3e47eaa4f", - "sha256:adc2573a82d100db3d583da5348e74833cd47d4221cff299285d2c8e09570edf", - "sha256:b7736bf08e83c1a95cce0cb91809f94eb612666158feaba8c4b7ef2d3f955a6e" - ], - "version": "==1.0.4" - }, - "py": { - "hashes": [ - "sha256:29c9fab495d7528e80ba1e343b958684f4ace687327e6f789a94bf3d1915f881", - "sha256:983f77f3331356039fdd792e9220b7b8ee1aa6bd2b25f567a963ff1de5a64f6a" - ], - "version": "==1.5.3" - }, - "py-ecc": { - "hashes": [ - "sha256:c7808a70c08bfc5c07b328f4df4406cfd3e365dd81f63bdd997c3c1eae34334a", - "sha256:f747ea69d40160c0a158c116bc3656eece9457cec446c8bfaffffd62f835de56" - ], - "version": "==1.4.2" - }, - "py-flags": { - "hashes": [ - "sha256:2b2b18caa7f11bdb276029fac823a9102057a0953c58f618b8b7000ef3773836", - "sha256:87b2a3f9a86fc1f739753b11c359145024a65ad7392c3eb364794149acc78120" - ], - "version": "==1.1.2" - }, - "py-solc": { - "hashes": [ - "sha256:d27d1a6cdd4dda6e5f01fac9b3e391fa8f68877ae879dfdd9cea4ca7922cdbe2", - "sha256:f49927fd8a84f4212a4efc6ad8d565b7ea9c9d411c024ea627407124f9adff4a" - ], - "version": "==3.0.0" - }, - "pycparser": { - "hashes": [ - "sha256:99a8ca03e29851d96616ad0404b4aad7d9ee16f25c9f9708a11faf2810f7b226" - ], - "version": "==2.18" - }, - "pycryptodome": { - "hashes": [ - "sha256:043c82cd3dd3120286a1b325ace93000cf52abb13a067c3ecb6220f874fe4c30", - "sha256:0cdd73492859d853f60b8185715312dbca465879661e28d354d1cf5ea11860e7", - "sha256:15013007e393d0cc0e69f4329a47c4c8597b7f3d02c12c03f805405542f70c71", - "sha256:19d81b92bff837cdade735b9023808556bb4868e1ce194dad4d5ec4e2b2851f3", - "sha256:1ceb3e87605c4f0080115a8a00abf45f5df27b0166a37fd669fbff4523273cfc", - "sha256:2354a77051ed4a2959ce2aac508071eb3e42fc348ea39228b2eac335990bf508", - "sha256:27bd2878200690b050dca34f505b5c623532324b3de40267c1484784063134df", - "sha256:322f239e51fda80233762400a8975ab728639b571fa58545b95b9c44042af010", - "sha256:49a71eb990af30ff6276cfe201eb83ed3640ae989c1b5973f7b55a46c94232d1", - "sha256:4b5a2680008da3ac0cef2d3661597e0cbf8a3eb19eed35b859fd67e2de63eb85", - "sha256:6d34fe5134eb5d62368e21e6f203ac1770bc7273e9536c4a280121312c2de53a", - "sha256:733d5eb7e5ceed8b9d0b3c24c81f52c04cb5de6786461388204fceefe4456aa5", - "sha256:7c73d3798fe2946953768b788ce554c0d4b390780f5e73d63bd833241af27bfe", - "sha256:97af76f5200f15e97cac58d77f319dec40b4bada98de697c91a9517e63b41d1a", - "sha256:97cc46ff02b99dafdc2e0385b325cec0f8a15bf8b285d6ed1d7e4a3bc2067ce1", - "sha256:a561b59e0c3548eb649af381b7c38c6fd8392bbd4d0a8214794b2b761f405af4", - "sha256:ab2c633bfc23cf41be9281228517cb6f87879f4f1aeb154ed72bd53ab7cc83e9", - "sha256:adb54316998337f315520bbd8ef4d8bbd940b4ddfaef8ba1db3c137c5e499399", - "sha256:b4a3b710287eb1fc3e2cc1af018063f003530dff00c9ea4c55ae19bc1f3923cc", - "sha256:bcfdb66d6604882c3f96eea922552c2487cc0aec4b883cd217b9d341d2f8fad0", - "sha256:c08c053eb8716bbbd5e13e38f453b9e46a063e68df8659f3c421dcb7519fd381", - "sha256:e51da4ef9d9e2695a04044152f380c2db17adc9fc6fad8e24d863ead9cd548ed", - "sha256:e850e07f54dc3de9a1efdd59d227fcd1cb30cdd307dafdc647c79e8f30cf5032", - "sha256:ebc579c41fe26748dc1bad4f9105f08740ee28826293a28103b3875968695a5e", - "sha256:ed94cb1b4bf24be734f2bf2db3e8ea75f3914d2f8e684291bee54bbe4a5a9151", - "sha256:f5e19802295e63bdf83bb92849285c01f7167840efb1c1e08507a50b10ba7efa", - "sha256:fc569682f012b1f62f8d28d8f9bc71f1de67648cd1bc124ef8ccf8db4edfc28a" - ], - "version": "==3.6.1" - }, - "pyethash": { - "hashes": [ - "sha256:ff66319ce26b9d77df1f610942634dac9742e216f2c27b051c0a2c2dec9c2818" - ], - "version": "==0.1.27" - }, - "pysha3": { - "hashes": [ - "sha256:0060a66be16665d90c432f55a0ba1f6480590cfb7d2ad389e688a399183474f0", - "sha256:11a2ba7a2e1d9669d0052fc8fb30f5661caed5512586ecbeeaf6bf9478ab5c48", - "sha256:386998ee83e313b6911327174e088021f9f2061cbfa1651b97629b761e9ef5c4", - "sha256:41be70b06c8775a9e4d4eeb52f2f6a3f356f17539a54eac61f43a29e42fd453d", - "sha256:4416f16b0f1605c25f627966f76873e432971824778b369bd9ce1bb63d6566d9", - "sha256:571a246308a7b63f15f5aa9651f99cf30f2a6acba18eddf28f1510935968b603", - "sha256:59111c08b8f34495575d12e5f2ce3bafb98bea470bc81e70c8b6df99aef0dd2f", - "sha256:5ec8da7c5c70a53b5fa99094af3ba8d343955b212bc346a0d25f6ff75853999f", - "sha256:684cb01d87ed6ff466c135f1c83e7e4042d0fc668fa20619f581e6add1d38d77", - "sha256:68c3a60a39f9179b263d29e221c1bd6e01353178b14323c39cc70593c30f21c5", - "sha256:6e6a84efb7856f5d760ee55cd2b446972cb7b835676065f6c4f694913ea8f8d9", - "sha256:827b308dc025efe9b6b7bae36c2e09ed0118a81f792d888548188e97b9bf9a3d", - "sha256:93abd775dac570cb9951c4e423bcb2bc6303a9d1dc0dc2b7afa2dd401d195b24", - "sha256:9c778fa8b161dc9348dc5cc361e94d54aa5ff18413788f4641f6600d4893a608", - "sha256:9fdd28884c5d0b4edfed269b12badfa07f1c89dbc5c9c66dd279833894a9896b", - "sha256:c7c2adcc43836223680ebdf91f1d3373543dc32747c182c8ca2e02d1b69ce030", - "sha256:c93a2676e6588abcfaecb73eb14485c81c63b94fca2000a811a7b4fb5937b8e8", - "sha256:cd5c961b603bd2e6c2b5ef9976f3238a561c58569945d4165efb9b9383b050ef", - "sha256:f9046d59b3e72aa84f6dae83a040bd1184ebd7fef4e822d38186a8158c89e3cf", - "sha256:fd7e66999060d079e9c0e8893e78d8017dad4f59721f6fe0be6307cd32127a07", - "sha256:fe988e73f2ce6d947220624f04d467faf05f1bbdbc64b0a201296bb3af92739e" - ], - "version": "==1.0.2" - }, - "pytest": { - "hashes": [ - "sha256:39555d023af3200d004d09e51b4dd9fdd828baa863cded3fd6ba2f29f757ae2d", - "sha256:c76e93f3145a44812955e8d46cdd302d8a45fbfc7bf22be24fe231f9d8d8853a" - ], - "version": "==3.6.0" - }, - "pytest-mock": { - "hashes": [ - "sha256:53801e621223d34724926a5c98bd90e8e417ce35264365d39d6c896388dcc928", - "sha256:d89a8209d722b8307b5e351496830d5cc5e192336003a485443ae9adeb7dd4c0" - ], - "index": "pypi", - "version": "==1.10.0" - }, - "pyyaml": { - "hashes": [ - "sha256:0c507b7f74b3d2dd4d1322ec8a94794927305ab4cebbe89cc47fe5e81541e6e8", - "sha256:16b20e970597e051997d90dc2cddc713a2876c47e3d92d59ee198700c5427736", - "sha256:3262c96a1ca437e7e4763e2843746588a965426550f3797a79fca9c6199c431f", - "sha256:326420cbb492172dec84b0f65c80942de6cedb5233c413dd824483989c000608", - "sha256:4474f8ea030b5127225b8894d626bb66c01cda098d47a2b0d3429b6700af9fd8", - "sha256:592766c6303207a20efc445587778322d7f73b161bd994f227adaa341ba212ab", - "sha256:5ac82e411044fb129bae5cfbeb3ba626acb2af31a8d17d175004b70862a741a7", - "sha256:5f84523c076ad14ff5e6c037fe1c89a7f73a3e04cf0377cb4d017014976433f3", - "sha256:827dc04b8fa7d07c44de11fabbc888e627fa8293b695e0f99cb544fdfa1bf0d1", - "sha256:b4c423ab23291d3945ac61346feeb9a0dc4184999ede5e7c43e1ffb975130ae6", - "sha256:bc6bced57f826ca7cb5125a10b23fd0f2fff3b7c4701d64c439a300ce665fff8", - "sha256:c01b880ec30b5a6e6aa67b09a2fe3fb30473008c85cd6a67359a1b15ed6d83a4", - "sha256:ca233c64c6e40eaa6c66ef97058cdc80e8d0157a443655baa1b2966e812807ca", - "sha256:e863072cdf4c72eebf179342c94e6989c67185842d9997960b3e69290b2fa269" - ], - "version": "==3.12" - }, - "repoze.lru": { - "hashes": [ - "sha256:0429a75e19380e4ed50c0694e26ac8819b4ea7851ee1fc7583c8572db80aff77", - "sha256:f77bf0e1096ea445beadd35f3479c5cff2aa1efe604a133e67150bc8630a62ea" - ], - "version": "==0.7" - }, - "requests": { - "hashes": [ - "sha256:6a1b267aa90cac58ac3a765d067950e7dbbf75b1da07e895d1f594193a40a38b", - "sha256:9c443e7324ba5b85070c4a818ade28bfabedf16ea10206da1132edaa6dda237e" - ], - "version": "==2.18.4" - }, - "rlp": { - "hashes": [ - "sha256:87879a0ba1479b760cee98af165de2eee95258b261faa293199f60742be96f34" - ], - "version": "==0.6.0" - }, - "scrypt": { - "hashes": [ - "sha256:18ccbc63d87c6f89b753194194bb37aeaf1abc517e4b989461d115c1d93ce128", - "sha256:232acdbc3434d2de55def8d5dbf1bc4b9bfc50da7c5741df2a6eebc4e18d3720", - "sha256:475ac80239b3d788ae71a09c3019ca915e149aaa339adcdd1c9eef121293dc88", - "sha256:4ad7188f2e42dbee2ff1cd72e3da40b170ba41847effbf0d726444f62ae60f3a", - "sha256:85919f023148cd9fb01d75ad4e3e061928c298fa6249a0cd6cd469c4b947595e", - "sha256:971db040d3963ebe4b919a203fe10d7d6659951d3644066314330983dc175ed4", - "sha256:a124719c686f2b5957e392465147fb3fd6077e7c643e9538cab1ee631eb01dde", - "sha256:a343c302b3e99dcb7fcbe57aa7919ed761f1568f854291ccebe1b5e6e2c9e509", - "sha256:bc131f74a688fa09993c518ca666a2ebd4268b207e039cbab03a034228140d3e", - "sha256:c23daecee405cb036845917295c76f8d747fc890158df40cb304b4b3c3640079", - "sha256:dc40f0e1a357a49ca62f30f2fc09e92e02c062a656f27949b436b2ba8002d9e1", - "sha256:f8239b2d47fa1d40bc27efd231dc7083695d10c1c2ac51a99380360741e0362d" - ], - "version": "==0.8.6" - }, - "semantic-version": { - "hashes": [ - "sha256:2a4328680073e9b243667b201119772aefc5fc63ae32398d6afafff07c4f54c0", - "sha256:2d06ab7372034bcb8b54f2205370f4aa0643c133b7e6dbd129c5200b83ab394b" - ], - "version": "==2.6.0" - }, - "six": { - "hashes": [ - "sha256:70e8a77beed4562e7f14fe23a786b54f6296e34344c23bc42f07b15018ff98e9", - "sha256:832dc0e10feb1aa2c68dcc57dbb658f1c7e65b9b61af69048abc87a2db00a0eb" - ], - "version": "==1.11.0" - }, - "toolz": { - "hashes": [ - "sha256:929f0a7ea7f61c178bd951bdae93920515d3fbdbafc8e6caf82d752b9b3b31c9" - ], - "version": "==0.9.0" - }, - "transaction": { - "hashes": [ - "sha256:269601a3493cd3eddeb869419ceadfc5e6d2bc931e9970d11fc4649dab189c3c", - "sha256:9de0f93f833713270fbceaf6092194313c1de0afb660e66dea8e089855eb281c", - "sha256:f2242070e437e5d555ea3df809cb517860513254c828f33847df1c5e4b776c7a" - ], - "version": "==2.2.1" - }, - "urllib3": { - "hashes": [ - "sha256:06330f386d6e4b195fbfc736b297f58c5a892e4440e54d294d7004e3a9bbea1b", - "sha256:cc44da8e1145637334317feebd728bd869a35285b93cbb4cca2577da7e62db4f" - ], - "version": "==1.22" - }, - "z3-solver": { - "hashes": [ - "sha256:6b10b317f056890a341304071fb3ab220f0adb2c87439a04eba9e69028a7e3ff", - "sha256:c185d05d236c6c9756e914756c73f797cb618d81b42e694166639cce5bcfdb1f", - "sha256:c802dbe5368743dd30dd2a684c15b83b17c3c95df54b66f97611a5988ae0f696", - "sha256:e41001b7f43ecb9eb9bedf6762bd0e002561590487cc78c0b48f608a85ce02ac" - ], - "version": "==4.5.1.0.post2" - }, - "zc.lockfile": { - "hashes": [ - "sha256:96cb13769e042988ea25d23d44cf09342ea0f887083d0f9736968f3617665853" - ], - "version": "==1.3.0" - }, - "zconfig": { - "hashes": [ - "sha256:6c77f5658101ccd76f01592baa5dac563da36034a55d02d8ef616e690729c05d", - "sha256:de0a802e5dfea3c0b3497ccdbe33a5023c4265f950f33e35dd4cf078d2a81b19" - ], - "version": "==3.2.0" - }, - "zodb": { - "hashes": [ - "sha256:0b306042f4f0d558a477d65c34b0dd6e7604c6e583f55dfda52befa2fa13e076" - ], - "version": "==5.4.0" - }, - "zodbpickle": { - "hashes": [ - "sha256:05b919d70341da9df677f564f40a7c2c97aff3338f5929d9a9ece6077b3d3247", - "sha256:4964bf56b9459979b7228cc1d571c3683c55ad31b67b88133d6c0253df9bf456", - "sha256:5b07352a42547169027b5186ae1b0aba3d9c278adfa3d32b4e4e18c904c906a8", - "sha256:5c16c6209bd583096da144e2960a56d56e0577277f72e4826f77c960fc2ac34f", - "sha256:5fdfa84f05b25511a4e1190ec98728aa487e2eb6db016a951fdbb79bcc7307e0", - "sha256:6b232db8896a87bfe5acfbbeb6255448783502e1fbdd79627f895760808b12cd", - "sha256:6e98bf709b2662f1db5e200f5eed73126a22dc571fcb78052e2ea668b30106b6", - "sha256:86169ca92929e2d888ebbf25e1f8d7abeef08eaffedab5fea496c100831beefb", - "sha256:d64e4a2ce81e150f35674b2bb92ac85abadda3e24bca67764a35d5c168e5e99e" - ], - "version": "==1.0.1" - }, - "zope.interface": { - "hashes": [ - "sha256:21506674d30c009271fe68a242d330c83b1b9d76d62d03d87e1e9528c61beea6", - "sha256:3d184aff0756c44fff7de69eb4cd5b5311b6f452d4de28cb08343b3f21993763", - "sha256:467d364b24cb398f76ad5e90398d71b9325eb4232be9e8a50d6a3b3c7a1c8789", - "sha256:57c38470d9f57e37afb460c399eb254e7193ac7fb8042bd09bdc001981a9c74c", - "sha256:9ada83f4384bbb12dedc152bcdd46a3ac9f5f7720d43ac3ce3e8e8b91d733c10", - "sha256:a1daf9c5120f3cc6f2b5fef8e1d2a3fb7bbbb20ed4bfdc25bc8364bc62dcf54b", - "sha256:e6b77ae84f2b8502d99a7855fa33334a1eb6159de45626905cb3e454c023f339", - "sha256:e881ef610ff48aece2f4ee2af03d2db1a146dc7c705561bd6089b2356f61641f", - "sha256:f41037260deaacb875db250021fe883bf536bf6414a4fd25b25059b02e31b120" - ], - "version": "==4.5.0" - } - }, - "develop": { - "astroid": { - "hashes": [ - "sha256:b7787562a4757d7101ca6270a06e5246c1dcd1a4851d4bb2421a6baae4b09c1b", - "sha256:f14913e18b71e6a86e05aeec80b8bd09286dff8a6e34c3cc71d67fa3d726aec7" - ], - "version": "==2.0.0.dev1" - }, - "atomicwrites": { - "hashes": [ - "sha256:240831ea22da9ab882b551b31d4225591e5e447a68c5e188db5b89ca1d487585", - "sha256:a24da68318b08ac9c9c45029f4a10371ab5b20e4226738e150e6e7c571630ae6" - ], - "version": "==1.1.5" - }, - "attrs": { - "hashes": [ - "sha256:4b90b09eeeb9b88c35bc642cbac057e45a5fd85367b985bd2809c62b7b939265", - "sha256:e0d0eb91441a3b53dab4d9b743eafc1ac44476296a2053b6ca3af0b139faf87b" - ], - "version": "==18.1.0" - }, - "isort": { - "hashes": [ - "sha256:1153601da39a25b14ddc54955dbbacbb6b2d19135386699e2ad58517953b34af", - "sha256:b9c40e9750f3d77e6e4d441d8b0266cf555e7cdabdcff33c4fd06366ca761ef8", - "sha256:ec9ef8f4a9bc6f71eec99e1806bfa2de401650d996c59330782b89a5555c1497" - ], - "version": "==4.3.4" - }, - "lazy-object-proxy": { - "hashes": [ - "sha256:0ce34342b419bd8f018e6666bfef729aec3edf62345a53b537a4dcc115746a33", - "sha256:1b668120716eb7ee21d8a38815e5eb3bb8211117d9a90b0f8e21722c0758cc39", - "sha256:209615b0fe4624d79e50220ce3310ca1a9445fd8e6d3572a896e7f9146bbf019", - "sha256:27bf62cb2b1a2068d443ff7097ee33393f8483b570b475db8ebf7e1cba64f088", - "sha256:27ea6fd1c02dcc78172a82fc37fcc0992a94e4cecf53cb6d73f11749825bd98b", - "sha256:2c1b21b44ac9beb0fc848d3993924147ba45c4ebc24be19825e57aabbe74a99e", - "sha256:2df72ab12046a3496a92476020a1a0abf78b2a7db9ff4dc2036b8dd980203ae6", - "sha256:320ffd3de9699d3892048baee45ebfbbf9388a7d65d832d7e580243ade426d2b", - "sha256:50e3b9a464d5d08cc5227413db0d1c4707b6172e4d4d915c1c70e4de0bbff1f5", - "sha256:5276db7ff62bb7b52f77f1f51ed58850e315154249aceb42e7f4c611f0f847ff", - "sha256:61a6cf00dcb1a7f0c773ed4acc509cb636af2d6337a08f362413c76b2b47a8dd", - "sha256:6ae6c4cb59f199d8827c5a07546b2ab7e85d262acaccaacd49b62f53f7c456f7", - "sha256:7661d401d60d8bf15bb5da39e4dd72f5d764c5aff5a86ef52a042506e3e970ff", - "sha256:7bd527f36a605c914efca5d3d014170b2cb184723e423d26b1fb2fd9108e264d", - "sha256:7cb54db3535c8686ea12e9535eb087d32421184eacc6939ef15ef50f83a5e7e2", - "sha256:7f3a2d740291f7f2c111d86a1c4851b70fb000a6c8883a59660d95ad57b9df35", - "sha256:81304b7d8e9c824d058087dcb89144842c8e0dea6d281c031f59f0acf66963d4", - "sha256:933947e8b4fbe617a51528b09851685138b49d511af0b6c0da2539115d6d4514", - "sha256:94223d7f060301b3a8c09c9b3bc3294b56b2188e7d8179c762a1cda72c979252", - "sha256:ab3ca49afcb47058393b0122428358d2fbe0408cf99f1b58b295cfeb4ed39109", - "sha256:bd6292f565ca46dee4e737ebcc20742e3b5be2b01556dafe169f6c65d088875f", - "sha256:cb924aa3e4a3fb644d0c463cad5bc2572649a6a3f68a7f8e4fbe44aaa6d77e4c", - "sha256:d0fc7a286feac9077ec52a927fc9fe8fe2fabab95426722be4c953c9a8bede92", - "sha256:ddc34786490a6e4ec0a855d401034cbd1242ef186c20d79d2166d6a4bd449577", - "sha256:e34b155e36fa9da7e1b7c738ed7767fc9491a62ec6af70fe9da4a057759edc2d", - "sha256:e5b9e8f6bda48460b7b143c3821b21b452cb3a835e6bbd5dd33aa0c8d3f5137d", - "sha256:e81ebf6c5ee9684be8f2c87563880f93eedd56dd2b6146d8a725b50b7e5adb0f", - "sha256:eb91be369f945f10d3a49f5f9be8b3d0b93a4c2be8f8a5b83b0571b8123e0a7a", - "sha256:f460d1ceb0e4a5dcb2a652db0904224f367c9b3c1470d5a7683c0480e582468b" - ], - "version": "==1.3.1" - }, - "mccabe": { - "hashes": [ - "sha256:ab8a6258860da4b6677da4bd2fe5dc2c659cff31b3ee4f7f5d64e79735b80d42", - "sha256:dd8d182285a0fe56bace7f45b5e7d1a6ebcbf524e8f3bd87eb0f125271b8831f" - ], - "version": "==0.6.1" - }, - "more-itertools": { - "hashes": [ - "sha256:2b6b9893337bfd9166bee6a62c2b0c9fe7735dcf85948b387ec8cba30e85d8e8", - "sha256:6703844a52d3588f951883005efcf555e49566a48afd4db4e965d69b883980d3", - "sha256:a18d870ef2ffca2b8463c0070ad17b5978056f403fb64e3f15fe62a52db21cc0" - ], - "version": "==4.2.0" - }, - "pluggy": { - "hashes": [ - "sha256:7f8ae7f5bdf75671a718d2daf0a64b7885f74510bcd98b1a0bb420eb9a9d0cff", - "sha256:d345c8fe681115900d6da8d048ba67c25df42973bda370783cd58826442dcd7c", - "sha256:e160a7fcf25762bb60efc7e171d4497ff1d8d2d75a3d0df7a21b76821ecbf5c5" - ], - "version": "==0.6.0" - }, - "py": { - "hashes": [ - "sha256:29c9fab495d7528e80ba1e343b958684f4ace687327e6f789a94bf3d1915f881", - "sha256:983f77f3331356039fdd792e9220b7b8ee1aa6bd2b25f567a963ff1de5a64f6a" - ], - "version": "==1.5.3" - }, - "pylint": { - "hashes": [ - "sha256:0990347c0f605927fadb2a9366a0b3d40bd19eb44e4312f0a1ef729a389b2f40", - "sha256:19b902f93f2dc3fa45565e54b88702b28379be40107f509a8516dde152460d1f" - ], - "index": "pypi", - "version": "==2.0.0.dev1" - }, - "pytest": { - "hashes": [ - "sha256:39555d023af3200d004d09e51b4dd9fdd828baa863cded3fd6ba2f29f757ae2d", - "sha256:c76e93f3145a44812955e8d46cdd302d8a45fbfc7bf22be24fe231f9d8d8853a" - ], - "version": "==3.6.0" - }, - "six": { - "hashes": [ - "sha256:70e8a77beed4562e7f14fe23a786b54f6296e34344c23bc42f07b15018ff98e9", - "sha256:832dc0e10feb1aa2c68dcc57dbb658f1c7e65b9b61af69048abc87a2db00a0eb" - ], - "version": "==1.11.0" - }, - "typed-ast": { - "hashes": [ - "sha256:0948004fa228ae071054f5208840a1e88747a357ec1101c17217bfe99b299d58", - "sha256:25d8feefe27eb0303b73545416b13d108c6067b846b543738a25ff304824ed9a", - "sha256:29464a177d56e4e055b5f7b629935af7f49c196be47528cc94e0a7bf83fbc2b9", - "sha256:2e214b72168ea0275efd6c884b114ab42e316de3ffa125b267e732ed2abda892", - "sha256:3e0d5e48e3a23e9a4d1a9f698e32a542a4a288c871d33ed8df1b092a40f3a0f9", - "sha256:519425deca5c2b2bdac49f77b2c5625781abbaf9a809d727d3a5596b30bb4ded", - "sha256:57fe287f0cdd9ceaf69e7b71a2e94a24b5d268b35df251a88fef5cc241bf73aa", - "sha256:668d0cec391d9aed1c6a388b0d5b97cd22e6073eaa5fbaa6d2946603b4871efe", - "sha256:68ba70684990f59497680ff90d18e756a47bf4863c604098f10de9716b2c0bdd", - "sha256:6de012d2b166fe7a4cdf505eee3aaa12192f7ba365beeefaca4ec10e31241a85", - "sha256:79b91ebe5a28d349b6d0d323023350133e927b4de5b651a8aa2db69c761420c6", - "sha256:8550177fa5d4c1f09b5e5f524411c44633c80ec69b24e0e98906dd761941ca46", - "sha256:a8034021801bc0440f2e027c354b4eafd95891b573e12ff0418dec385c76785c", - "sha256:bc978ac17468fe868ee589c795d06777f75496b1ed576d308002c8a5756fb9ea", - "sha256:c05b41bc1deade9f90ddc5d988fe506208019ebba9f2578c622516fd201f5863", - "sha256:c9b060bd1e5a26ab6e8267fd46fc9e02b54eb15fffb16d112d4c7b1c12987559", - "sha256:edb04bdd45bfd76c8292c4d9654568efaedf76fe78eb246dde69bdb13b2dad87", - "sha256:f19f2a4f547505fe9072e15f6f4ae714af51b5a681a97f187971f50c283193b6" - ], - "markers": "python_version < '3.7'", - "version": "==1.1.0" - }, - "wrapt": { - "hashes": [ - "sha256:d4d560d479f2c21e1b5443bbd15fe7ec4b37fe7e53d335d3b9b0a7b1226fe3c6" - ], - "version": "==1.10.11" - }, - "yapf": { - "hashes": [ - "sha256:6567745f0b6656f9c33a73c56a393071c699e6284a70d793798ab6e3769d25ec", - "sha256:a98a6eacca64d2b920558f4a2f78150db9474de821227e60deaa29f186121c63" - ], - "index": "pypi", - "version": "==0.22.0" - } - } -} diff --git a/coverage_report.sh b/coverage_report.sh index 3f97261b..795372ab 100755 --- a/coverage_report.sh +++ b/coverage_report.sh @@ -7,6 +7,7 @@ rm -rf ./tests/testdata/outputs_current/ mkdir -p ./tests/testdata/outputs_current/ rm -rf coverage_html_report -coverage run -m unittest discover -p "*_test.py" -coverage html -open coverage_html_report/index.html +py.test \ + --cov=mythril \ + --cov-config=tox.ini \ + --cov-report=html:coverage_html_report \ diff --git a/tox.ini b/tox.ini index d30f2d50..9d95022d 100644 --- a/tox.ini +++ b/tox.ini @@ -25,7 +25,15 @@ commands = mkdir -p {toxinidir}/tests/testdata/outputs_current/ py.test -v \ --cov=mythril \ + --cov-config=tox.ini \ --cov-report=xml:{toxworkdir}/output/{envname}/coverage.xml \ --cov-report=html:{toxworkdir}/output/{envname}/covhtml \ --junitxml={toxworkdir}/output/{envname}/junit.xml \ {posargs} + +[coverage:report] +omit = + *__init__.py + /usr/* + *_test.py + setup.py