Files
GPOZaurr/Examples/Example-36-FindBlockedInheritance.ps1
T
Przemysław Kłys 927ae5cd15 fix: 🐛 correct typo in 'Blocked Inhertiance' to 'Blocked Inheritance'
* Updated comments in `Example-36-FindBlockedInheritance.ps1` for clarity.
* Fixed spelling error in `Invoke.GPOZaurrBlockedInheritance.ps1`.
2025-12-04 08:33:11 +01:00

15 lines
657 B
PowerShell

Import-Module "$PSScriptRoot\..\GPoZaurr.psd1" -Force
# Get basic output DN, CanonicalName, BlockInheritance (True/False)
#$Objects = Get-GPOZaurrInheritance
#$Objects | Format-Table
# Get same output DN, CanonicalName, BlockInheritance (True/False) + Users/Computers + UsersCount/ComputerCount for those with Blocked Inheritance
# This is so you can have a list what machines are affected
$ExcludedOU = @(
# Works on OU/
'ad.evotec.xyz/ITR02/Test'
)
$Objects = Get-GPOZaurrInheritance -IncludeBlockedObjects -IncludeExcludedObjects -OnlyBlockedInheritance -Exclusions $ExcludedOU -IncludeGroupPoliciesForBlockedObjects
$Objects | Format-Table