Skip to content

Commit

Permalink
fix: Warning user to install signatures (#1420)
Browse files Browse the repository at this point in the history
* fix: Warning user to install signatures

---------

Co-authored-by: Willi Ballenthin <[email protected]>
  • Loading branch information
naikordian and williballenthin authored Apr 5, 2023
1 parent d46cf5b commit 8fe88f6
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions capa/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -1038,6 +1038,13 @@ def handle_common_args(args):
logger.debug("-" * 80)

sigs_path = os.path.join(get_default_root(), "sigs")
if not os.path.exists(sigs_path):
logger.error(
"Using default signature path, but it doesn't exist. "
"Please install the signatures first: "
"https://github.com/mandiant/capa/blob/master/doc/installation.md#method-2-using-capa-as-a-python-library."
)
raise IOError(f"signatures path {sigs_path} does not exist or cannot be accessed")
else:
sigs_path = args.signatures
logger.debug("using signatures path: %s", sigs_path)
Expand Down

0 comments on commit 8fe88f6

Please sign in to comment.