From ae23bb4974addb738fdb16dd04040488f2ea3424 Mon Sep 17 00:00:00 2001 From: jiezixumihp Date: Fri, 31 Jul 2026 15:45:38 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=AF=B9windows=E5=B9=B3?= =?UTF-8?q?=E5=8F=B0=E6=94=AF=E6=8C=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: jiezixumihp --- sdk/build/script/signtool_sec.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sdk/build/script/signtool_sec.py b/sdk/build/script/signtool_sec.py index 0b4729a..cb5cd6c 100644 --- a/sdk/build/script/signtool_sec.py +++ b/sdk/build/script/signtool_sec.py @@ -79,7 +79,8 @@ def check_cfg_whitelist_format(intput_str): def whitelist_check(intput_str): - if not re.match(r"^[A-Za-z0-9\/\-_.${}]+$", intput_str): + if not re.match(r"^[A-Za-z0-9\/\\_.$:{}-]+$", intput_str): + logging.error(f"Path Invalid: '{intput_str}', Allowed Characters: Letters(A-Z a-z), Special Symbols(/ - _ . {{ }} \ $ :)") return 1 return 0 @@ -436,7 +437,7 @@ def parser_api_level(mk_compile_cfg, cmake_compile_cfg, mk_config_cfg, cmake_con logging.error("Build config file doesn't exist, ignore it") return default_api_level - with open(compile_cfg_file) as file_op: + with open(compile_cfg_file, encoding="utf-8") as file_op: for line in file_op: if line.startswith("#") or "-DAPI_LEVEL" not in line: continue