?
Solved

setting registry permissions via script

Posted on 2004-04-15
10
Medium Priority
?
1,216 Views
Last Modified: 2013-12-04
I want to set registry permissions with a batch job, any ways to do this on windows xp and 2003 server systems ?
0
Comment
Question by:inferno_gr
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
10 Comments
 
LVL 12

Expert Comment

by:trywaredk
ID: 10836759
@echo off
%systemroot%\regedit.exe -s \\YourServerName\YourShareName\YourRegfile.reg
EXIT

Many Regards
Jorgen Malmgren
IT-Supervisor
Denmark

:o) Your brain is like a parachute. It works best when it's open
0
 
LVL 12

Expert Comment

by:trywaredk
ID: 10836772
Examples of regfiles can be found at http://www.winguides.com/registry/
0
 
LVL 12

Expert Comment

by:trywaredk
ID: 10836783
HOW TO: Add, Modify, or Delete Registry Subkeys and Values by Using a Registration Entries (.reg) File
http://support.microsoft.com/default.aspx?scid=kb;EN-US;310516
0
Automating Your MSP Business

The road to profitability.
Delivering superior services is key to ensuring customer satisfaction and the consequent long-term relationships that enable MSPs to lock in predictable, recurring revenue. What's the best way to deliver superior service? One word: automation.

 
LVL 85

Accepted Solution

by:
oBdA earned 1000 total points
ID: 10837545
You can do that with subinacl.exe from the Resource Kit.
For example
subinacl.exe /keyreg HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\Root /grant=SomeGroup
subinacl.exe /keyreg HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\Root /revoke=SomeGroup

Windows Server 2003 Resource Kit Tools
http://www.microsoft.com/downloads/details.aspx?familyid=9d467a69-57ff-4ae7-96ee-b18c4790cffd&displaylang=en

The help has sometimes trouble installing. If you open the help shortcut after installing the tools, and just the regular help pops up, completely unrelated to the RK tools, do the following:
Unzip the rktools.exe, which will leave you with rktools.msi, rktools_p.cab, rktools_s.cab. Use the "rktools_p" if you installed on XP professional, the "rktools_s" if Server 2003, extract rktools.xml and rktools.chm of the corresponding file, then copy them to %Systemroot%\Help.
0
 
LVL 38

Assisted Solution

by:Rich Rumble
Rich Rumble earned 1000 total points
ID: 10838362
0
 
LVL 2

Author Comment

by:inferno_gr
ID: 10846592
ok, regini from windows 2003 resourse kit, checked and actually regini is already in a fresh win2003 installation without resourse kit, but what about winxp ?
regini of winxp is not performing the same job.
0
 
LVL 85

Expert Comment

by:oBdA
ID: 10854261
Just to clarify that: You don't need to install the Resource Kit on every target computer. All you need is the subinacl.exe file, which can be started from a network share as well; you just need to install the Resource Kit on one machine to get access to the file in the first place. You can use it against remote machine as well by adding \\MachineName in front of the key.
0
 
LVL 85

Expert Comment

by:oBdA
ID: 11454958
Sorry, but I'm afraid that trywaredk's answer is incorrect, so in order to avoid confusion, the http:#10836759 should not be considered a valid solution.
The question was how to set permissions on registry keys using a script. This can definitely NOT be done with .reg files used with the regedit import/export functions. regini.exe and subinacl.exe can do this.
0

Featured Post

Get real performance insights from real users

Key features:
- Total Pages Views and Load times
- Top Pages Viewed and Load Times
- Real Time Site Page Build Performance
- Users’ Browser and Platform Performance
- Geographic User Breakdown
- And more

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

As I write this article, I am finishing cleanup from the Qakbot virus variant found in the wild on April 18, 2011.  It was a messy beast that had varying levels of infection, speculated as being dependent on how long it resided on the infected syste…
Users of Windows 10 Professional can disable automatic reboots using the policy editor. This tool is not included in the Windows home edition. But don't worry! Follow the instructions below to install (a Win7) policy editor on your Windows 10 Home e…
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…
Suggested Courses
Course of the Month12 days, 17 hours left to enroll

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question