vbs脚本他能实现鼠标控制的原因是使用了offices中的excel的注册表,然而这样不是所有的控制程序都能实现在目标电脑上控制的,这取决于对方电脑的office版本与注册表。有的时候还会出现未知bug。
我这里提供一套直接的工具,双击就能解决这个问题。CSDN无法直接上传.exe文件(要钱)所以我额外给一个GitHub地址以方便下载:jzzj-KKBK/-macro (github.com)
请注意,必须得有office使用的工具才能有用
下面是Python代码
import base64
import os
base64_data=
reg = """Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Microsoft\Office\16.0\Excel\Security]
"AccessVBOM"=dword:00000001
[HKEY_CURRENT_USER\Software\Microsoft\Office\16.0\Excel\Security\FileBlock]
"FileTypeBlockList"=""
"OoxmlConverterBlockList"=""
[HKEY_CURRENT_USER\Software\Microsoft\Office\16.0\Excel\Security\Trusted Documents]
"LastPurgeTime"=dword:01b47a6f
[HKEY_CURRENT_USER\Software\Microsoft\Office\16.0\Excel\Security\Trusted Locations]
[HKEY_CURRENT_USER\Software\Microsoft\Office\16.0\Excel\Security\Trusted Locations\Location0]
"Path"="C:\\Program Files (x86)\\Microsoft Office\\root\\Office16\\XLSTART\\"
"Description"="3"
"AllowSubFolders"=dword:00000001
[HKEY_CURRENT_USER\Software\Microsoft\Office\16.0\Excel\Security\Trusted Locations\Location1]
"Path"=hex(2):25,00,41,00,50,00,50,00,44,00,41,00,54,00,41,00,25,00,5c,00,4d,\
00,69,00,63,00,72,00,6f,00,73,00,6f,00,66,00,74,00,5c,00,45,00,78,00,63,00,\
65,00,6c,00,5c,00,58,00,4c,00,53,00,54,00,41,00,52,00,54,00,00,00
"Description"="4"
[HKEY_CURRENT_USER\Software\Microsoft\Office\16.0\Excel\Security\Trusted Locations\Location2]
"Path"=hex(2):25,00,41,00,50,00,50,00,44,00,41,00,54,00,41,00,25,00,5c,00,4d,\
00,69,00,63,00,72,00,6f,00,73,00,6f,00,66,00,74,00,5c,00,54,00,65,00,6d,00,\
70,00,6c,00,61,00,74,00,65,00,73,00,00,00
"Description"="5"
[HKEY_CURRENT_USER\Software\Microsoft\Office\16.0\Excel\Security\Trusted Locations\Location3]
"Path"="C:\\Program Files (x86)\\Microsoft Office\\root\\Templates\\"
"Description"="6"
"AllowSubFolders"=dword:00000001
[HKEY_CURRENT_USER\Software\Microsoft\Office\16.0\Excel\Security\Trusted Locations\Location4]
"Path"="C:\\Program Files (x86)\\Microsoft Office\\root\\Office16\\STARTUP\\"
"Description"="7"
"AllowSubFolders"=dword:00000001
[HKEY_CURRENT_USER\Software\Microsoft\Office\16.0\Excel\Security\Trusted Locations\Location5]
"Path"="C:\\Program Files (x86)\\Microsoft Office\\root\\Office16\\Library\\"
"Description"="12"
"AllowSubFolders"=dword:00000001
"""
current_directory = os.getcwd()
cmd = """cd C:\\Program Files\\Common Files\\microsoft shared\\
MD Dao
cd """+current_directory
cmd = cmd+"""
start 3.reg
move dao361.dll "C:\\Program Files\\Common Files\\microsoft shared\\Dao\\dao361.dll"
pause
"""
# 编码字符串为字节序列
encoded_cmd = cmd.encode('utf-8')
encoded_reg = reg.encode('utf-8')
# 以二进制写模式打开文件,并写入编码后的字节序列
with open('3.reg', 'wb') as file:
file.write(encoded_reg)
with open('请以管理员身份启动.cmd', 'wb') as file:
file.write(encoded_cmd)
def decode_base64(base64_data):
with open('dao360.dll', 'wb') as file:
img = base64.b64decode(base64_data)
file.write(img)
if __name__ == '__main__':
img_path = 'dao360.dll'
decode_base64(base64_data)
base64_data=
后面应该跟着360dao.dll,但是这个文件base64编码太长不让发,算了,自己去GitHub上下载吧,我在这里也能提供一份文件