
bat如何更改注冊表所有者renini只能設置權限secedit /co
nfigure /db test.sdb /cfg test.inf /log test.log也不行SetACL 也不行
- //1------secedit-----------
- @echo off
- rem 設置HKEY_LOCAL_MACHINESOFTWAREtest的所有者為:Everyone
- >>test.inf echo.[Version]
- >>test.inf echo.Signature = $Chicago$
- >>test.inf echo.
- >>test.inf echo.[Registry Keys]
- >>test.inf echo.MACHINESOFTWAREMicrosoftWindows NTCurrentVersionScheduleTaskCacheTree, 0, O:WD
- secedit /configure /db test.sdb /cfg test.inf /log test.log
- del test.*
- pause
- //2------SetACL-----------
- whoami /user >%temp%test.txt
- for /f delims= %%i in (%temp%test.txt) do set last=%%i
- for /f delims=S tokens=2 %%i in ('echo %last%') do set SID=S%%i
- SetACL.exe -on HKEY_LOCAL_MACHINESOFTWAREMicrosoftWindows NTCurrentVersionScheduleTaskCacheTree -ot reg -actn setowner -ownr n:%SID%;s:y
- SetACL.exe -on HKEY_LOCAL_MACHINESOFTWAREMicrosoftWindows NTCurrentVersionScheduleTaskCacheTree -ot reg -actn ace -ace n:administrators;p:full
nclick="copycode($('code0'));">復制代碼
其他辦法不知道了, 也沒能搜到具體就是把這個操作用bat實現
注冊表-右鍵單擊某個key-權限-高級-所有者然后我也搜索了, 然后折騰了一下午,沒能搞定