diff --git a/xanalyzer/file.py b/xanalyzer/file.py index c22c7c7..efa6b4d 100644 --- a/xanalyzer/file.py +++ b/xanalyzer/file.py @@ -225,7 +225,7 @@ def get_special_strs(self): the_file = open(self.file_path, "rb") file_content = the_file.read() the_file.close() - tmp_base64_strs = re.findall(rb"[A-Za-z0-9+/]{2,}={0,2}", file_content) + tmp_base64_strs = re.findall(rb"[A-Za-z0-9+/]{6,}={1,2}", file_content) possible_base64_strs = [] for tmp_base64_str in tmp_base64_strs: # 过滤hex字符串 @@ -240,7 +240,10 @@ def get_special_wide_strs(self): the_file = open(self.file_path, "rb") file_content = the_file.read() the_file.close() - tmp_base64_strs = re.findall(rb"(?:[A-Za-z0-9+/]\x00){2,}(?:=\x00){0,2}", file_content) + tmp_base64_strs = re.findall( + rb"(?:[A-Za-z0-9+/]\x00){6,}(?:=\x00){1,2}", + file_content, + ) possible_base64_strs = [] for tmp_base64_str in tmp_base64_strs: # 过滤hex字符串