From 0888e5ad69c4eee8b1a88b5e24e7ebcc6cba253d Mon Sep 17 00:00:00 2001 From: Willi Ballenthin Date: Fri, 20 Jan 2023 15:22:43 +0100 Subject: [PATCH] main: more doc --- capa/main.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/capa/main.py b/capa/main.py index d6817f8b..e682407f 100644 --- a/capa/main.py +++ b/capa/main.py @@ -597,6 +597,13 @@ def collect_rule_file_paths(rule_paths: List[str]) -> List[str]: def get_rules(rule_paths: List[str], disable_progress=False) -> RuleSet: + """ + args: + rule_paths: list of paths to rules files or directories containing rules files + """ + + # rule_paths may contain directory paths, + # so search for file paths recursively. rule_file_paths = collect_rule_file_paths(rule_paths) # this list is parallel to `rule_file_paths`: