1、python3調用exe程序編寫cve20190708批量檢測工具
工具下載地址:
https://www.qianxin.com/other/CVE-2019-0708
#!/usr/bin/python3
#-*- coding:utf-8 -*-
#編寫環境 windows 7 x64 Notepad++ + Python3.5.0
import os
import sys
def main():
#需要修改的地址,注意后面有個空格
path="D:\\MS_19_0708_Scan\\cve20190708批量腳本檢測工具\\cve-2019-0708-scan.exe "
filename="ip.txt"
with open('result.txt','w') as fw:
with open(filename,'r') as file:
for line in file:
try:
result = os.popen(path+line+' 3389')
print("檢測 "+line)
fw.writelines(result)
fw.writelines(line)
except Exception as e:
print("Path error")
print(e)
if __name__ == '__main__':
main()
1.1測試用例

1.2使用方法

1.3檢測結果:

