What exactly is 
{09F7EDC5-294E-4180-AF6A-FB0E6A0E9513}?
is it a key (where underneath is nothing except {default}, or is it a reg_sz 
registry key?  or a reg_dword?

nowhere in your results (yet) has SPPValue been reported, so for those 
particular clients, they don't have anything to say about that. at all.  All 
they've reported (because of keyname) is that they got the request to report, 
and are asking... but have nothing to say about sppvalue.

 
Sherry Kissinger
Microsoft MVP - ConfigMgr
[email protected]


________________________________
 From: "Aguero, Tom" <[email protected]>
To: "[email protected]" <[email protected]> 
Sent: Wednesday, November 6, 2013 7:11 AM
Subject: RE: [mssms] Regkey reporting on property that involves { } characters
 


 
Sherry,
 
Mofcomp liked that version and it’s pulling results in but I’m not sure how to 
interpret them. Does this mean that the key is present on these machines?
 
ResourceID         GroupID               RevisionID           AgentID           
    TimeStamp                         KeyName0
410                         1                              1                    
          1                     2013-11-05 13:51:03.000         RegKeyToMOF_32
601                         1                              1                    
          1                     2013-11-05 12:48:58.000         RegKeyToMOF_32
883                         1                              1                    
          1                     2013-11-05 12:29:26.000         RegKeyToMOF_32
1288                       1                              1                     
         1                     2013-11-05 11:25:43.000         RegKeyToMOF_32
1288                       2                              1                     
         1                     2013-11-05 11:25:43.000         RegKeyToMOF_64
1310                       1                              1                     
         1                     2013-11-05 17:51:49.000         RegKeyToMOF_32
4253                       1                              1                     
         1                     2013-11-05 11:11:24.000         RegKeyToMOF_32
 
Tom Aguero
Shared Services | Information Technology
900 N Garver Rd, Monroe, OH 45050
Phone: 800.834.8001
[email protected]
 
From:[email protected] [mailto:[email protected]] On 
Behalf Of Sherry Kissinger
Sent: Tuesday, November 5, 2013 10:23 AM
To: [email protected]
Subject: Re: [mssms] Regkey reporting on property that involves { } characters
 
Untested, but it's probably just that you have to change the "label" to be 
something boring... like SPPValue
 
I took the ^ out of the regkey query part too--don't know if that was right or 
wrong.  You'll find out after you drop this in.
 
Hm... you MIGHT want to change it up... so that the view/table that was already 
created for SystemProtection doesn't mess with you.  I'll change that groupname 
and class id too (below); so it's clean.
 
// RegKeyToMOF by Mark Cochrane (thanks to Skissinger, Steverac, Jonas Hettich 
& Kent Agerlund)
// this section tells the inventory agent what to report to the server
// 11/5/2013 8:32:46 AM
 
#pragma namespace ("\\\\.\\root\\cimv2\\SMS")
#pragma deleteclass("SysProtection", NOFAIL)
[SMS_Report(TRUE),SMS_Group_Name("SysProtection"),SMS_Class_ID("SysProtection"),
SMS_Context_1("__ProviderArchitecture=32|uint32"),
SMS_Context_2("__RequiredArchitecture=true|boolean")]
Class SysProtection: SMS_Class_Template
{
[SMS_Report(TRUE),key] string KeyName;
[SMS_Report(TRUE)] String SPPValue;
};
 
#pragma namespace ("\\\\.\\root\\cimv2\\SMS")
#pragma deleteclass("SysProtection_64", NOFAIL)
[SMS_Report(TRUE),SMS_Group_Name("SysProtection"),SMS_Class_ID("SysProtection"),
SMS_Context_1("__ProviderArchitecture=64|uint32"),
SMS_Context_2("__RequiredArchitecture=true|boolean")]
Class SysProtection_64 : SMS_Class_Template
{
[SMS_Report(TRUE),key] string KeyName;
[SMS_Report(TRUE)] String SPPValue;
};
 
// RegKeyToMOF by Mark Cochrane (thanks to Skissinger, Steverac, Jonas Hettich 
& Kent Agerlund)
// this section tells the inventory agent what to collect
// 11/5/2013 8:32:46 AM
 
#pragma namespace ("\\\\.\\root\\cimv2")
#pragma deleteclass("SysProtection", NOFAIL)
[DYNPROPS]
Class SysProtection
{
[key] string KeyName;
String SPPValue;
};
 
[DYNPROPS]
Instance of SysProtection
{
KeyName="RegKeyToMOF_32";
[PropertyContext("Local|HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows 
NT\\CurrentVersion\\SPP\\Clients|{09F7EDC5-294E-4180-AF6A-FB0E6A0E9513}"),Dynamic,Provider("RegPropProv")]
 SPPValue ;
};
 
#pragma namespace ("\\\\.\\root\\cimv2")
#pragma deleteclass("SysProtection_64", NOFAIL)
[DYNPROPS]
Class SysProtection_64
{
[key] string KeyName;
String SPPValue;
};
 
[DYNPROPS]
Instance of SysProtection_64
{
KeyName="RegKeyToMOF_64";
[PropertyContext("Local|HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows 
NT\\CurrentVersion\\SPP\\Clients|{09F7EDC5-294E-4180-AF6A-FB0E6A0E9513}"),Dynamic,Provider("RegPropProv")]
 SPPValue;
};
 
Sherry Kissinger
Microsoft MVP - ConfigMgr
[email protected]
 

________________________________
 
From:"Aguero, Tom" <[email protected]>
To: "[email protected]" <[email protected]> 
Sent: Tuesday, November 5, 2013 7:56 AM
Subject: [mssms] Regkey reporting on property that involves { } characters
 
I’m trying to build a report on Windows 7 machines and their System Protection 
status. I’ve found the registry key that controls if System Protection is on 
and what it’s set it. The problem is that the name of the key is 
{09F7EDC5-294E-4180-AF6A-FB0E6A0E9513} and mofcomp gets cranky about the { }. 
I’ve tried using ^{ to escape the { as this article, 
http://support.microsoft.com/kb/2543399, advises but it hasn’t made any 
difference yet.
 
Here’s what I’m trying with the ^ in addition to what RegKeyToMof gave me:
 
Sms_def
 
// RegKeyToMOF by Mark Cochrane (thanks to Skissinger, Steverac, Jonas Hettich 
& Kent Agerlund)
// this section tells the inventory agent what to report to the server
// 11/5/2013 8:32:46 AM
 
#pragma namespace ("\\\\.\\root\\cimv2\\SMS")
#pragma deleteclass("SystemProtection", NOFAIL)
[SMS_Report(TRUE),SMS_Group_Name("SystemProtection"),SMS_Class_ID("Custom|SystemProtection|1.0"),
SMS_Context_1("__ProviderArchitecture=32|uint32"),
SMS_Context_2("__RequiredArchitecture=true|boolean")]
Class SystemProtection: SMS_Class_Template
{
[SMS_Report(TRUE),key] string KeyName;
[SMS_Report(TRUE)] String ^{09F7EDC5-294E-4180-AF6A-FB0E6A0E9513^}^[^];
};
 
#pragma namespace ("\\\\.\\root\\cimv2\\SMS")
#pragma deleteclass("SystemProtection_64", NOFAIL)
[SMS_Report(TRUE),SMS_Group_Name("SystemProtection"),SMS_Class_ID("Custom|SystemProtection|1.0"),
SMS_Context_1("__ProviderArchitecture=64|uint32"),
SMS_Context_2("__RequiredArchitecture=true|boolean")]
Class SystemProtection_64 : SMS_Class_Template
{
[SMS_Report(TRUE),key] string KeyName;
[SMS_Report(TRUE)] String ^{09F7EDC5-294E-4180-AF6A-FB0E6A0E9513^}^[^];
};
 
// RegKeyToMOF by Mark Cochrane (thanks to Skissinger, Steverac, Jonas Hettich 
& Kent Agerlund)
// this section tells the inventory agent what to collect
// 11/5/2013 8:32:46 AM
 
#pragma namespace ("\\\\.\\root\\cimv2")
#pragma deleteclass("SystemProtection", NOFAIL)
[DYNPROPS]
Class SystemProtection
{
[key] string KeyName;
String ^{09F7EDC5-294E-4180-AF6A-FB0E6A0E9513^}^[^];
};
 
[DYNPROPS]
Instance of SystemProtection
{
KeyName="RegKeyToMOF_32";
[PropertyContext("Local|HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows 
NT\\CurrentVersion\\SPP\\Clients|^{09F7EDC5-294E-4180-AF6A-FB0E6A0E9513^}"),Dynamic,Provider("RegPropProv")]
 ^{09F7EDC5-294E-4180-AF6A-FB0E6A0E9513^};
};
 
#pragma namespace ("\\\\.\\root\\cimv2")
#pragma deleteclass("SystemProtection_64", NOFAIL)
[DYNPROPS]
Class SystemProtection_64
{
[key] string KeyName;
String ^{09F7EDC5-294E-4180-AF6A-FB0E6A0E9513^}^[^];
};
 
[DYNPROPS]
Instance of SystemProtection_64
{
KeyName="RegKeyToMOF_64";
[PropertyContext("Local|HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows 
NT\\CurrentVersion\\SPP\\Clients|^{09F7EDC5-294E-4180-AF6A-FB0E6A0E9513^}"),Dynamic,Provider("RegPropProv")]
 ^{09F7EDC5-294E-4180-AF6A-FB0E6A0E9513^};
};
 
When compiling sms_def I get the error sms_def.mof (5495): error SYNTAX 
0X8004400c: Expected property or method name
 
Configruation.mof appears to compile without error but when I open it back up 
after compiling the additions are gone.
 
Tom Aguero
Shared Services | Information Technology
900 N Garver Rd, Monroe, OH 45050
Phone: 800.834.8001
[email protected]


Reply via email to