Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Security > Can't read remote registry key.

Reply
Thread Tools

Can't read remote registry key.

 
 
sergey.losyev@gmail.com
Guest
Posts: n/a
 
      05-01-2006
Hi, it's a small intranet webapp.

OpenRemoteBaseKey works fine, but on read-only OpenSubKey function I
get an error:
<Requested registry access is not allowed.>

On remote machine I set all Code Groups to Everything, Set all .NET
security to Full Trust and in Registry added "Everyone" with Full
Control to the key and I still can't get past the error! Please advise!

This is my function in webservice:

public bool Read_Key()
{

// Opening the registry key
RegistryKey rk =
RegistryKey.OpenRemoteBaseKey(Microsoft.Win32.Regi stryHive.LocalMachine,"RDATABASE");

// Open a subKey as read-only
RegistryKey sk1 = rk.OpenSubKey(SOFTWARE\\TEST\Sample1);

// If the RegistrySubKey doesn't exist -> (null)
if ( sk1 == null )
return false;
try
{....



Sergey

 
Reply With Quote
 
 
 
 
sergey.losyev@gmail.com
Guest
Posts: n/a
 
      05-01-2006
I added <identity impersonate="true" userName="Admin" password="pass"
/> and it worked!

But why didn't all my loose permissions (posted above) work for
whatever default account asp.net uses to access remote registry?

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Read remote registry Slimo ASP .Net 4 11-02-2007 02:46 PM
How to read a registry key from Windows registry ? Leny Java 3 02-01-2005 07:54 AM
Interpretation of registry log of tweakui produced registry alteration vincemoon@rcn.com ASP .Net 0 01-10-2005 02:53 AM
Remote Assistance fails to connect, remote remote host name could not be resolved Peter Sale Wireless Networking 1 12-11-2004 09:09 PM
Reading registry key throws "Requested registry access is not allowed." HK ASP .Net 1 04-01-2004 04:44 PM



Advertisments