Island: Fix logic error in ConfigService

The ConfigService would only translate the old fingerprinter names to the
new names if HTTPFinger was enabled. This change rectifies the issue.
This commit is contained in:
Mike Salvatore 2022-02-08 12:58:04 -05:00
parent c15290415d
commit a02b13cdc2
1 changed files with 4 additions and 5 deletions

View File

@ -545,12 +545,11 @@ class ConfigService:
{"name": f, "options": {}} for f in sorted(config[flat_fingerprinter_classes_field])
]
if "HTTPFinger" in config[flat_fingerprinter_classes_field]:
for fp in formatted_fingerprinters:
if fp["name"] == "HTTPFinger":
fp["options"] = {"http_ports": sorted(config[flat_http_ports_field])}
for fp in formatted_fingerprinters:
if fp["name"] == "HTTPFinger":
fp["options"] = {"http_ports": sorted(config[flat_http_ports_field])}
fp["name"] = ConfigService._translate_fingerprinter_name(fp["name"])
fp["name"] = ConfigService._translate_fingerprinter_name(fp["name"])
config.pop(flat_fingerprinter_classes_field)
return formatted_fingerprinters