? Write to protected keys with .REG files

A

Alec Soroudi

Hi,

I've got a couple of service that I like to use (giveio and dlportio)
that allow me to access parallel ports and stuff directly like with Win 9x.
The thing is that I do not like to install them manually. Istead, what I
have done is to extract the neccessary files (giveio.sys, dlportio.sys,
dlportio.dll), and the required registry entries. What I have done is to
create a batch file that checks if the files are present, and if not, it
copies them to the system directory. It then imports (silently) a .REG file
to enable the services, then displays a reboot notice. The problem is that
some of the registry entries need to be made to protected keys:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\Root\LEGACY_XXXXX]

(one with DLPORTIO the other with GIVEIO in place of the XXXXX)

I can get around the permission problem by setting "Full Control" on the
....\Root\ key for everyone, importing the .REG file, then clearing "Full
Control" for everyone on the key. Of course this is less than elegant. The
installers for the services seem to be able to import the keys.

How can import the entries to ...\Root\ without worrying about the
permissions? I'm currently using regedit.exe /s *.


Thanks
 
A

Alec Soroudi

Oh, and how can I start/stop the services? The installers seem to be
able to do that as well.


--
Alec
(e-mail address removed)



 
A

Alec Soroudi

Oh, and how can I start/stop the services? The installers seem to be
able to do that as well.


--
Alec
(e-mail address removed)



 
S

Smile Extender

I think registry branch
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\Root is generated
automatically at boot time. When you install a service or device driver, you
use specific windows system functions. They add new keys under
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services.

You must also use administrative account when installing services. Normal
user accounts doesn't have permissions to update those registry keys.
 
S

Smile Extender

I think registry branch
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\Root is generated
automatically at boot time. When you install a service or device driver, you
use specific windows system functions. They add new keys under
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services.

You must also use administrative account when installing services. Normal
user accounts doesn't have permissions to update those registry keys.
 

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