Security.Monitoring.MultiStringRegistry.PowerShell (ProbeActionModuleType)

Element properties:

TypeProbeActionModuleType
IsolationAny
AccessibilityInternal
RunAsDefault
OutputTypeSystem.PropertyBagData

Member Modules:

ID Module Type TypeId RunAs 
PSScript ProbeAction Microsoft.Windows.PowerShellPropertyBagTriggerOnlyProbe Default

Source Code:

<ProbeActionModuleType ID="Security.Monitoring.MultiStringRegistry.PowerShell" Accessibility="Internal">
<Configuration>
<IncludeSchemaTypes>
<SchemaType>Windows!Microsoft.Windows.PowerShellSchema</SchemaType>
</IncludeSchemaTypes>
<xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema" minOccurs="1" name="RegKey" type="xsd:string"/>
<xsd:element xmlns:xsd="http://www.w3.org/2001/XMLSchema" minOccurs="1" name="RegAttribute" type="xsd:string"/>
</Configuration>
<ModuleImplementation Isolation="Any">
<Composite>
<MemberModules>
<ProbeAction ID="PSScript" TypeID="Windows!Microsoft.Windows.PowerShellPropertyBagTriggerOnlyProbe">
<ScriptName>MultiStringRegistry.ps1</ScriptName>
<ScriptBody><Script>Param($key,$attribute)
$api = New-Object -comObject 'MOM.ScriptAPI'
$bag = $api.CreatePropertyBag()
$AuthPkgs = @(Get-ItemProperty -Path $key -Name $attribute | select -ExpandProperty $attribute)
$AuthPkg = $AuthPkgs[0] + $AuthPkgs[1] + $AuthPkgs[2] + $AuthPkgs[3]
if($AuthPkg -ne $null) {
$bag.addvalue('AuthPkg',$AuthPkg)
}
$bag</Script></ScriptBody>
<SnapIns/>
<Parameters>
<Parameter>
<Name>key</Name>
<Value>$Config/RegKey$</Value>
</Parameter>
<Parameter>
<Name>attribute</Name>
<Value>$Config/RegAttribute$</Value>
</Parameter>
</Parameters>
<TimeoutSeconds>60</TimeoutSeconds>
</ProbeAction>
</MemberModules>
<Composition>
<Node ID="PSScript"/>
</Composition>
</Composite>
</ModuleImplementation>
<OutputType>System!System.PropertyBagData</OutputType>
<TriggerOnly>true</TriggerOnly>
</ProbeActionModuleType>