473,626 Members | 3,320 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Remote Registry - Requested registry access is not allowed.

JB
I am trying to access a registry key on computer like so:

key = RegistryKey.Ope nRemoteBaseKey( RegistryHive.Lo calMachine,
computerName).O penSubKey(Subke y);

There are two keys I am trying to read, 1 works, and the other gives
me the "Requested registry access is not allowed."
i've narrowed it down to
HKEY_LOCAL_MACH INE\SOFTWARE\Mi crosoft\Office
It doesnt let me access that path, but the permissions are the same.
I can access it alright on my own machine (passing my machine name
into OpenRemoteBaseK ey) but not anyone's remote machine.

It lets me access HKLM\Software\M icrosoft\Window s NT
but not
HKLM\Software\M icrosoft\Office

Although I get the same error "Requested registry access is not
allowed" if i enter an incorrect path, eg HKLM\Software\f djkhfjkh

Any ideas where i may be going wrong?

Jun 26 '07 #1
3 8313
this could a CAS (code access security) issue....but not sure

"JB" <ja*******@gmai l.comwrote in message
news:11******** *************@w 5g2000hsg.googl egroups.com...
>I am trying to access a registry key on computer like so:

key = RegistryKey.Ope nRemoteBaseKey( RegistryHive.Lo calMachine,
computerName).O penSubKey(Subke y);

There are two keys I am trying to read, 1 works, and the other gives
me the "Requested registry access is not allowed."
i've narrowed it down to
HKEY_LOCAL_MACH INE\SOFTWARE\Mi crosoft\Office
It doesnt let me access that path, but the permissions are the same.
I can access it alright on my own machine (passing my machine name
into OpenRemoteBaseK ey) but not anyone's remote machine.

It lets me access HKLM\Software\M icrosoft\Window s NT
but not
HKLM\Software\M icrosoft\Office

Although I get the same error "Requested registry access is not
allowed" if i enter an incorrect path, eg HKLM\Software\f djkhfjkh

Any ideas where i may be going wrong?

Jun 26 '07 #2
You would need the right permissions for accessing the registry on the
remote PC.
Please verify (Registry Editor>Edit>Per missions)

Hope this helps!
Thanks -

"JB" <ja*******@gmai l.comwrote in message
news:11******** *************@w 5g2000hsg.googl egroups.com...
>I am trying to access a registry key on computer like so:

key = RegistryKey.Ope nRemoteBaseKey( RegistryHive.Lo calMachine,
computerName).O penSubKey(Subke y);

There are two keys I am trying to read, 1 works, and the other gives
me the "Requested registry access is not allowed."
i've narrowed it down to
HKEY_LOCAL_MACH INE\SOFTWARE\Mi crosoft\Office
It doesnt let me access that path, but the permissions are the same.
I can access it alright on my own machine (passing my machine name
into OpenRemoteBaseK ey) but not anyone's remote machine.

It lets me access HKLM\Software\M icrosoft\Window s NT
but not
HKLM\Software\M icrosoft\Office

Although I get the same error "Requested registry access is not
allowed" if i enter an incorrect path, eg HKLM\Software\f djkhfjkh

Any ideas where i may be going wrong?

Jun 26 '07 #3
JB
Cheers, that does seem to be why it is encountering problems.
I can run the app fine as 'Administrator' , but, the permissions are
set so all users should have read access.

I want a few key users to be able to run the app, how would i go about
authenticating on a remote machine and not using my current login as
authentication?

Or related: Is there a way of reading the registry through WMI? I'm
already connecting to each machine through wmi as admin, if i could
read the registry somehow through there it would make it much easier.
I couldn't find a method of doing it though.

On 26 Jun, 11:54, "Shine Xavier" <shine.xav...@g mail.comwrote:
You would need the right permissions for accessing the registry on the
remote PC.
Please verify (Registry Editor>Edit>Per missions)

Hope this helps!
Thanks -
Jun 26 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
15067
by: Brian Campbell | last post by:
Gretings... I have written a Windows Service that accesses a Web Service. Both run fine on my development machine.... After installing both the Windows Service and Web Service on my staging server, I get the following error...
1
1736
by: Yoshitha | last post by:
Hi I am developing web application through which i've to write and read the values from the registry. When i set impersonate property to "false" it is displaying exception " Requested Registry Access is not allowed" so then i changed impersonate to "true" and it is reading values from the registry and writing into the registry. but when i runing the same aplication in same system now am getting the exception "requested registry access...
3
2497
by: bfprog | last post by:
Using IBM iSeries client access OLEDB provider to connect to DB2 on AS/400, but cannot create connection using .NET web app. Using following code: Dim cnTest As New OleDbConnection("Provider=IBMDA400; Data Source=S10324NM; User ID=THEUSER; Password=THESECRET") Works fine in console app, but fails in web app with: System.Security.SecurityException: Requested registry access is not allowed.
4
46446
by: LP | last post by:
Hi, My webservice is currently deployed on WIndows 2000 server and runs pretty fine. I am trying to run my webservice on a Windows 2003 server. My webservice tries to write to a eventlog. The code is as follows: System.Diagnostics.EventLog Log = new System.Diagnostics.EventLog( EventLogName ); Log.Source = EventLogName; Log.WriteEntry( "PCHistory Service Application started up successfully.",
0
1972
by: Shane | last post by:
Does anyone have any advise on how I can fix the error message shown below? Thanks in advance for any ideas, Shane Server Error in '/' Application. -------------------------------------------------------------------------------- Security Exception Description: The application attempted to perform an operation not allowed
1
428
by: Patrick.O.Ige | last post by:
Hi All, After installing Enterprise Librabry and building the libraries when i load an aspx page i get the error :"Requested registry access is not allowed" I'm about to look into it but if anyone here has tackled the error before let me know Patrick Microsoft.Win32.RegistryKey.OpenSubKey(String name, Boolean writable)
5
9768
by: Ankit Aneja | last post by:
This is my problem. I am using Visual 2003, .Net framework 1.1 and the Application Block I configured the DAAB using the Enterprise Library Configuration now this is the error which is coming Security Exception Description: The application attempted to perform an operation not allowed
7
12084
by: Peter Ritchie | last post by:
I'm writing a Web Service and I would like to add performance counter data for monitoring performance of the Web Service's operations over time and load. The problem is, I get the "Requested registry access is not allowed." SecurityException when I try and create the performance counter category via PerformanceCounterCategory.Create(). I understand the login used to run the Web Service does not have access to the registry keys...
3
4584
by: Geoff McElhanon | last post by:
I have been struggling with a security issue that occurs under .NET 2.0, but does not occur under .NET 1.1. Essentially I am trying to open up a performance counter on a remote server and monitor its value. In .NET 1.1 this worked fine, however under .NET 2.0 it fails when I am not an administrator on the remote server. To provide a lean demonstration of the issue, I created the following class: ============================
0
8266
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8199
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8705
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8638
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8365
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7196
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4198
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1811
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1511
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.