The Computer Oracle

Change registry permissions via command line (batch file)

--------------------------------------------------
Hire the world's top talent on demand or became one of them at Toptal: https://topt.al/25cXVn
and get $2,000 discount on your first invoice
--------------------------------------------------

Take control of your privacy with Proton's trusted, Swiss-based, secure services.
Choose what you need and safeguard your digital life:
Mail: https://go.getproton.me/SH1CU
VPN: https://go.getproton.me/SH1DI
Password Manager: https://go.getproton.me/SH1DJ
Drive: https://go.getproton.me/SH1CT


Music by Eric Matyas
https://www.soundimage.org
Track title: Techno Bleepage Open

--

Chapters
00:00 Change Registry Permissions Via Command Line (Batch File)
00:30 Accepted Answer Score 12
00:55 Answer 2 Score 3
01:18 Thank you

--

Full question
https://superuser.com/questions/712392/c...

--

Content licensed under CC BY-SA
https://meta.stackexchange.com/help/lice...

--

Tags
#windows7 #commandline #windowsregistry #acl

#avk47



ACCEPTED ANSWER

Score 12


I found my way around another utility, SetACL. I pushed the file out to some systems, then ran the following commands remotely. They succeeded, and the icon changed on those systems after doing an F5 on the Desktop.

SetACL.exe -on "HKEY_CLASSES_ROOT\CLSID\{20D04FE0-3AEA-1069-A2D8-08002B30309D}" -ot reg -actn setowner -ownr n:Administrators
SetACL.exe -on "HKEY_CLASSES_ROOT\CLSID\{20D04FE0-3AEA-1069-A2D8-08002B30309D}" -ot reg -actn ace -ace "n:Administrators;p:full"
reg import computername.reg



ANSWER 2

Score 3


You can also use Subinacl.exe (Official tool from Microsoft for managing permissions).

To change users permissions for a special registery key and its subkeys you can write sommething like this (copy the Subinacl.exe file in C:\Cindows\system32 to use it directly as a standard command in cmd ):

> subinacl.exe /subkeyreg HKEY_LOCAL_MACHINE\SOFTWARE\POLICIES\MICROSOFT /grant=Everyone=f