Create & Link a GPO
Find principals that can create new GPOs in the domain
powershell Get-DomainObjectAcl -Identity "CN=Policies,CN=System,DC=dev,DC=cyberbotic,DC=io" -ResolveGUIDs | ? { $_.ObjectAceType -eq "Group-Policy-Container" -and $_.ActiveDirectoryRights -contains "CreateChild" } | % { ConvertFrom-SID $_.SecurityIdentifier }
DEV\DevelopersLook for linkable OU's
powershell Get-DomainOU | Get-DomainObjectAcl -ResolveGUIDs | ? { $_.ObjectAceType -eq "GP-Link" -and $_.ActiveDirectoryRights -match "WriteProperty" } | select ObjectDN,ActiveDirectoryRights,ObjectAceType,SecurityIdentifier | fl
ObjectDN : OU=Workstations,DC=dev,DC=cyberbotic,DC=ioCheck if required module present on machine
powershell Get-Module -List -Name GroupPolicy | select -expand ExportedCommands
Backup-GPO Backup-GPO
Block-GPInheritance Block-GPInheritance
Copy-GPO Copy-GPO
Get-GPInheritance Get-GPInheritance
Get-GPO Get-GPOCreate and link a new GPO
Next, apply the GPO to the target OU
Last updated