from _winreg import *
keyVal = r'SOFTWARE\Microsoft\Windows\CurrentVersion\policies\System'
try:
key = OpenKey(HKEY_CURRENT_USER, keyVal, 0, KEY_ALL_ACCESS)
except:
key = CreateKey(HKEY_CURRENT_USER, keyVal)
SetValueEx(key, "DisableTaskMgr", 0, REG_DWORD, 1)
CloseKey(key)
停用工作管理員
34.3. _winreg – Windows registry access — Python v2.7.3
Python’s _winreg: Editing the Windows Registry « The Mouse Vs. The Python
沒有留言:
張貼留言