TestimoX

API Reference

Command

Get-ADXLgpo

Namespace ADPlayground.PowerShell
Outputs
ADPlayground.Gpo.GpoLocal.LgpoDiffReport ADPlayground.Gpo.GpoLocal.LgpoSnapshotReport

Gets Local GPO snapshot (Machine/User or per-user by SID) and optional diff against .pol/.reg/LGPO text/PolicyRules.

Examples

Authored help example

Example 1: Snapshot Machine LGPO (summary)


Get-ADXLgpo -Scope Machine -View Summary
        

Example 2: Render current LGPO as lgpo.exe text


Get-ADXLgpo -Scope Machine -View LgpoText
        

Example 3: Compare against PolicyRules baseline


Get-ADXLgpo -Scope Machine -AgainstPolicyRules C:\in\Baseline.PolicyRules -View Diff -Minimal
        

Common Parameters

This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.

For more information, see about_CommonParameters.

Syntax

Get-ADXLgpo [-AgainstPol <string>] [-Minimal] [-Scope <Computer|User>] [-UserSid <string>] [-View <Raw|Entries|Summary|Diff|LgpoText>] [<CommonParameters>]
#
Parameter set: By AgainstPol

Parameters

AgainstPol string optionalposition: namedpipeline: false
Compare current LGPO against a reference .pol file.
Minimal SwitchParameter optionalposition: namedpipeline: false
Emit compact rows for -View Diff (added/removed/changed only).
Scope RegistryPolicyScope optionalposition: namedpipeline: falsevalues: 2
LGPO scope to inspect (Machine or User). Possible values: Computer, User
Possible values: Computer, User
UserSid string optionalposition: namedpipeline: false
Optional per-user SID for MLGPO (when Scope=User).
View AdxLgpoView optionalposition: namedpipeline: falsevalues: 5
Optional view selector. Possible values: None, Raw, Entries, Summary, Diff, LgpoText
Possible values: Raw, Entries, Summary, Diff, LgpoText

Outputs

ADPlayground.Gpo.GpoLocal.LgpoDiffReport, ADPlayground.Gpo.GpoLocal.LgpoSnapshotReport

Get-ADXLgpo [-AgainstReg <string>] [-Minimal] [-Scope <Computer|User>] [-UserSid <string>] [-View <Raw|Entries|Summary|Diff|LgpoText>] [<CommonParameters>]
#
Parameter set: By AgainstReg

Parameters

AgainstReg string optionalposition: namedpipeline: false
Compare current LGPO against a .reg export (converted).
Minimal SwitchParameter optionalposition: namedpipeline: false
Emit compact rows for -View Diff (added/removed/changed only).
Scope RegistryPolicyScope optionalposition: namedpipeline: falsevalues: 2
LGPO scope to inspect (Machine or User). Possible values: Computer, User
Possible values: Computer, User
UserSid string optionalposition: namedpipeline: false
Optional per-user SID for MLGPO (when Scope=User).
View AdxLgpoView optionalposition: namedpipeline: falsevalues: 5
Optional view selector. Possible values: None, Raw, Entries, Summary, Diff, LgpoText
Possible values: Raw, Entries, Summary, Diff, LgpoText

Outputs

ADPlayground.Gpo.GpoLocal.LgpoDiffReport, ADPlayground.Gpo.GpoLocal.LgpoSnapshotReport

Get-ADXLgpo [-AgainstLgpoText <string>] [-Minimal] [-Scope <Computer|User>] [-UserSid <string>] [-View <Raw|Entries|Summary|Diff|LgpoText>] [<CommonParameters>]
#
Parameter set: By AgainstLgpoText

Parameters

AgainstLgpoText string optionalposition: namedpipeline: false
Compare current LGPO against LGPO text format (lgpo.exe /t output).
Minimal SwitchParameter optionalposition: namedpipeline: false
Emit compact rows for -View Diff (added/removed/changed only).
Scope RegistryPolicyScope optionalposition: namedpipeline: falsevalues: 2
LGPO scope to inspect (Machine or User). Possible values: Computer, User
Possible values: Computer, User
UserSid string optionalposition: namedpipeline: false
Optional per-user SID for MLGPO (when Scope=User).
View AdxLgpoView optionalposition: namedpipeline: falsevalues: 5
Optional view selector. Possible values: None, Raw, Entries, Summary, Diff, LgpoText
Possible values: Raw, Entries, Summary, Diff, LgpoText

Outputs

ADPlayground.Gpo.GpoLocal.LgpoDiffReport, ADPlayground.Gpo.GpoLocal.LgpoSnapshotReport

Get-ADXLgpo [-AgainstPolicyRules <string>] [-Minimal] [-Scope <Computer|User>] [-UserSid <string>] [-View <Raw|Entries|Summary|Diff|LgpoText>] [<CommonParameters>]
#
Parameter set: By AgainstPolicyRules

Parameters

AgainstPolicyRules string optionalposition: namedpipeline: false
Compare current LGPO against Microsoft Policy Analyzer .PolicyRules XML.
Minimal SwitchParameter optionalposition: namedpipeline: false
Emit compact rows for -View Diff (added/removed/changed only).
Scope RegistryPolicyScope optionalposition: namedpipeline: falsevalues: 2
LGPO scope to inspect (Machine or User). Possible values: Computer, User
Possible values: Computer, User
UserSid string optionalposition: namedpipeline: false
Optional per-user SID for MLGPO (when Scope=User).
View AdxLgpoView optionalposition: namedpipeline: falsevalues: 5
Optional view selector. Possible values: None, Raw, Entries, Summary, Diff, LgpoText
Possible values: Raw, Entries, Summary, Diff, LgpoText

Outputs

ADPlayground.Gpo.GpoLocal.LgpoDiffReport, ADPlayground.Gpo.GpoLocal.LgpoSnapshotReport