add registry key from script

B

Bisha

I need to add a registry key to all users. I created
a .reg file and add regedit /s regfile.reg.

Everything works but for regular users or even power users
I get an error to access registry.Looks like a permission
problem . "How can I add the registry key as a regular or
power user ??"

The Key I need to add is :
[HKEY_CURRENT_USER\Software\Policies\Microsoft\Security]
"CheckAdminSettings"=dword:00000001

Thanks
 
A

Adam

Hi

Could you run the script under Administrator by using the RunAs command?

Just a thought
 
M

Mark V

In said:
I need to add a registry key to all users. I created
a .reg file and add regedit /s regfile.reg.

Everything works but for regular users or even power users
I get an error to access registry.Looks like a permission
problem . "How can I add the registry key as a regular or
power user ??"

The Key I need to add is :
[HKEY_CURRENT_USER\Software\Policies\Microsoft\Security]
"CheckAdminSettings"=dword:00000001

I don't have that exact key, but using regedt32.exe you can observe
that the POLICIES key is restriced (Administrators:F, SYSTEM:F
UserAccount:R) This is intentional.

Adam offers one way to have the change made from an acceptable
security context. RUNAS alone however, generally exposes the
passphrase to prying eyes.

Generally I suggest using a Policy to change, well, Policies.

http://support.microsoft.com/default.aspx?scid=kb;en-us;885682
"How to deploy customized Outlook 2003 security settings to client
computers by using the "Outlook virus security settings" Group Policy
setting"

You might list available methods there _other_ than user-context
registry merge.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top