Skip to content

Commit

Permalink
Updates to files for style automation
Browse files Browse the repository at this point in the history
  • Loading branch information
skalupa committed Apr 22, 2024
1 parent a0589ce commit 6f5a8e7
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
4 changes: 3 additions & 1 deletion src/python/strelka/auxiliary/iocs.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

import tldextract


def extract_iocs_from_string(input_string):
"""
Extracts various types of Indicators of Compromise (IOCs) from a string.
Expand All @@ -17,6 +18,7 @@ def extract_iocs_from_string(input_string):
iocs.update(extract_ip_addresses(input_string))
return list(iocs)


def extract_domains_from_string(input_string):
"""
Extracts domain names from a string containing URLs.
Expand Down Expand Up @@ -68,4 +70,4 @@ def extract_ip_addresses(input_string):
ip_addresses.update(ipv4_addresses)
ip_addresses.update(ipv6_addresses)

return list(ip_addresses)
return list(ip_addresses)
2 changes: 1 addition & 1 deletion src/python/strelka/scanners/scan_xml.py
Original file line number Diff line number Diff line change
Expand Up @@ -145,4 +145,4 @@ def _process_attributes(
if attr_name_lower in xml_options["metadata_tags"]:
self.event["tag_data"].append(
{"tag": attr_name, "content": str(node.attrib)}
)
)
2 changes: 1 addition & 1 deletion src/python/strelka/tests/test_scan_xml.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,4 +154,4 @@ def test_scan_xml_with_file(mocker):
)

TestCase.maxDiff = None
TestCase().assertDictEqual(test_scan_event, scanner_event)
TestCase().assertDictEqual(test_scan_event, scanner_event)

0 comments on commit 6f5a8e7

Please sign in to comment.