mirror of
https://github.com/cisagov/snafflepy
synced 2026-09-24 18:22:23 +00:00
Merge branch 'main' into dev
This commit is contained in:
@@ -25,6 +25,7 @@ class Rules:
|
||||
|
||||
|
||||
# TODO
|
||||
|
||||
def is_interest(file):
|
||||
# massive_wordlist = prepare_classifiers()
|
||||
# print(massive_wordlist)
|
||||
|
||||
@@ -94,7 +94,7 @@ def begin_snaffle(options):
|
||||
# filelist.append(file)
|
||||
# Ask do they want file sizes?
|
||||
# log.info(f"{target} Found file in {share}: {file.get_longname()}")
|
||||
naive_classify(share, file)
|
||||
naive_classify(share, file, prepped_rules)
|
||||
# log.info(f"{target} Found file in {share}: {file}")
|
||||
except FileListError:
|
||||
log.error(
|
||||
@@ -166,11 +166,11 @@ def list_computers(connection: Connection, domain):
|
||||
return None
|
||||
|
||||
# TODO
|
||||
def naive_classify(share, file):
|
||||
def naive_classify(share, file, rules:Rules):
|
||||
log.info(f"{share}: {file.get_longname()}")
|
||||
|
||||
|
||||
if is_interest(file):
|
||||
if is_interest(file, rules):
|
||||
log.info(f"Found interesting file: {share}/{file}")
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user