Files
GPOZaurr/Examples/Example-29-FindGPO1.ps1
Przemyslaw Klys 65f52058d3 Enhance example scripts with additional functionality
- Added online invocation of Invoke-GPOZaurr for GPOBroken and GPOBrokenLink
- Included return statements for clarity in Example-29 and Example-51
2025-02-23 13:44:07 +01:00

30 lines
1.1 KiB
PowerShell

Import-Module "$PSScriptRoot\..\GPoZaurr.psd1" -Force
#$O = Invoke-GPOZaurrContent -GPOName "Test-RestrictedGroups" -Verbose
#$O
Invoke-GPOZaurr -Online -Type GPOBroken, GPOBrokenLink -Verbose -SplitReports
return
#$Output = Invoke-GPOZaurrContent -GPOPath 'C:\Support\GitHub\GpoZaurr\Ignore\GPODefender'
$Output = Invoke-GPOZaurrContent -GPOPath 'C:\Support\GitHub\GpoZaurr\Ignore\GPOExport' -Type WindowsHelloForBusiness
$Output | Format-Table
$Output.WindowsDefenderExploitGuard | Format-Table
$Output.Reports.RegistrySetting | Format-Table
# Report to Excel of translated reports
foreach ($Key in $Output.Keys) {
$Output[$Key] | ConvertTo-Excel -FilePath $Env:USERPROFILE\Desktop\GPOAnalysis.xlsx -ExcelWorkSheetName $Key -AutoFilter -AutoFit -FreezeTopRowFirstColumn
}
# Report to HTML of translated reports
New-HTML {
New-HTMLTableOption -DataStore JavaScript
foreach ($Key in $Output.Keys) {
New-HTMLTab -Name $Key {
New-HTMLTable -DataTable $Output[$Key] -Filtering -Title $Key
}
}
} -FilePath $Env:USERPROFILE\Desktop\GPOAnalysis.html -ShowHTML -Online