removed dependency on tool-dict.pkl (#93)

* removed tool_dict dependency

* updated tests

* updated go version

* added defaults for failing iteration during tool installation

* Update pythonapp.yml

* updated docs
This commit is contained in:
epi
2020-08-27 20:27:43 -05:00
committed by epi
parent d7dbd1e7b3
commit 973893ee42
25 changed files with 55 additions and 109 deletions

View File

@@ -1,6 +1,4 @@
import sys
import pickle
import typing
import inspect
import pkgutil
import importlib
@@ -10,13 +8,12 @@ from cmd2.ansi import style
from collections import defaultdict
from ..recon.config import defaults
from ..tools import tools
def meets_requirements(requirements, exception):
""" Determine if tools required to perform task are installed. """
tools = get_tool_state()
print(tools.items())
for tool in requirements:
if not tools.get(tool).get("installed"):
if exception:
@@ -29,14 +26,6 @@ def meets_requirements(requirements, exception):
return True
def get_tool_state() -> typing.Union[dict, None]:
""" Load current tool state from disk. """
tools = Path(defaults.get("tools-dir")) / ".tool-dict.pkl"
if tools.exists():
return pickle.loads(tools.read_bytes())
def get_scans():
""" Iterates over the recon package and its modules to find all of the classes that end in [Ss]can.