Skip to content

Commit

Permalink
fix CSP extractor
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions committed Nov 5, 2024
1 parent da8d174 commit a2a0123
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions bbot/modules/internal/excavate.py
Original file line number Diff line number Diff line change
Expand Up @@ -527,9 +527,8 @@ class CSPExtractor(ExcavateRule):
async def process(self, yara_results, event, yara_rule_settings, discovery_context):
for identifier in yara_results.keys():
for csp_str in yara_results[identifier]:
domains = await self.helpers.re.findall(bbot_regexes.dns_name_regex, csp_str)
unique_domains = set(domains)
for domain in unique_domains:
domains = await self.excavate.scan.extract_in_scope_hostnames(csp_str)
for domain in domains:
await self.report(domain, event, yara_rule_settings, discovery_context, event_type="DNS_NAME")

class EmailExtractor(ExcavateRule):
Expand Down

0 comments on commit a2a0123

Please sign in to comment.