Solved

Reading ACL of RegKeys - multiple computers

Posted on 2010-09-15
3
421 Views
Last Modified: 2012-05-10
Hi there,

I have to analyse the ACL configuration of two RegKeys on round about 1.000 Windows Servers. I tried to find a proper class in WMI to query the ACL but nothing have found yet... Query Regkeys is quiet easy, but do not know how to get the ACL of it - anybody does?

Cheers
0
Comment
Question by:ptea
[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
  • 2
3 Comments
 
LVL 8

Expert Comment

by:thetmanvn
ID: 33680723
0
 

Author Comment

by:ptea
ID: 33681053
thx for that, but if I am right .NET/get-ACL only works on the local machine and not remote(?). Shoudl run this query over 1.000 machines. Do you know if there is way to do this with WMI - can't find a proper Class....
0
 
LVL 8

Accepted Solution

by:
thetmanvn earned 500 total points
ID: 33681390
You can work with remote registry in .NET/PS. See here:

http://bsonposh.com/archives/207

This article does not mention $Srv parameter, but in this article, it describe in example:

http://bsonposh.com/archives/258 (Remote retrieve Installed software)


Hope this help

# Get-InstalledSoftware
Param($srv=$env:ComputerName)
$regKey = [Microsoft.Win32.RegistryKey]::OpenRemoteBaseKey([Microsoft.Win32.RegistryHive]::LocalMachine,$Srv)
$key = $regKey.OpenSubkey("Software\Microsoft\Windows\CurrentVersion\Uninstall",$false)
Write-Host
Write-Host "Getting Software in Uninstall Key" -Fore Green
Write-Host ("-"*60) -Fore Gray
$key.GetSubKeyNames()
Write-Host
Write-Host "Getting Software From Win32_Product" -Fore Green
Write-Host ("-"*60) -Fore Gray
get-wmiobject Win32_Product -comp $srv | foreach{$_.Name}
Write-Host

Open in new window

0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

"Migrate" an SMTP relay receive connector to a new server using info from an old server.
Recently we ran in to an issue while running some SQL jobs where we were trying to process the cubes.  We got an error saying failure stating 'NT SERVICE\SQLSERVERAGENT does not have access to Analysis Services. So this is a way to automate that wit…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…

742 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