Capturing HKCU Settings via HINV

Published Sunday, August 24, 2008 2:46 PM

For those who use the SaveData application (or maybe also use SMS/SCCM Companion from www.SCCMExpert.com (shameless plug Big Smile ), they provide a freeware utility which allows the user to defer a shutdown, so that their machines don't get shutdown via the automated route that the product provides, the attached script will allow you to capture (catch out) those users who are using this functionality and find out what *stupid* defer shutdown times are being set.

With the starting point here from Sherry Kissinger (thanks again), I have managed to get it all working, hopefully this will help others who use it Big Smile , we are at SMS 2003 SP3

 

SaveData-HKCU-Registry-Capture.vbs

VB script which checks the logged on user via WMI, then checks for the users SID in HKEY_USERS and captures the settings and imports to HKLM, in order to get round the issue of user not having permissions to write to HKLM, we didn't query HKCU which is where SaveData writes to in registry. Nice neat trick from one of our packagers.

 

SaveData-Client.mof

Create the WMI Classes to capture the new reg keys created by above.

 

SaveData-SMS_def-MOF.mof

Reporting classes for SMS_def.mof

 

SaveDataSMSReport.sql

SQL to create the SMS Report (sanitized to protect the guilty)

 

image

 

Create the advert to run on a daily basis, package properties use as follows.

image

Filed under: , ,

Comments

No Comments