mirror of https://github.com/mvt-project/mvt.git
Renaming check function for consistency
This commit is contained in:
parent
11bc916854
commit
146f2ae57d
|
@ -89,7 +89,7 @@ class Files(AndroidExtraction):
|
|||
return
|
||||
|
||||
for result in self.results:
|
||||
if self.indicators.check_filename(result["path"]):
|
||||
if self.indicators.check_file_name(result["path"]):
|
||||
self.log.warning("Found a known suspicous filename at path: \"%s\"", result["path"])
|
||||
self.detected.append(result)
|
||||
|
||||
|
|
|
@ -271,7 +271,7 @@ class Indicators:
|
|||
|
||||
return False
|
||||
|
||||
def check_filename(self, file_path) -> bool:
|
||||
def check_file_name(self, file_path) -> bool:
|
||||
"""Check the provided file path against the list of file indicators.
|
||||
|
||||
:param file_path: File path or file name to check against file
|
||||
|
@ -307,6 +307,7 @@ class Indicators:
|
|||
# Strip any trailing slash from indicator paths to match directories.
|
||||
if file_path.startswith(ioc_file.rstrip("/")):
|
||||
return True
|
||||
|
||||
return False
|
||||
|
||||
def check_profile(self, profile_uuid) -> bool:
|
||||
|
|
|
@ -83,7 +83,7 @@ class Manifest(IOSExtraction):
|
|||
self.detected.append(result)
|
||||
continue
|
||||
|
||||
if self.indicators.check_filename(result["relative_path"]):
|
||||
if self.indicators.check_file_name(result["relative_path"]):
|
||||
self.log.warning("Found a known malicious file at path: %s", result["relative_path"])
|
||||
self.detected.append(result)
|
||||
continue
|
||||
|
|
Loading…
Reference in New Issue