mirror of
https://github.com/EvotecIT/GPOZaurr.git
synced 2026-08-10 10:47:09 +00:00
290 lines
5.8 KiB
Markdown
290 lines
5.8 KiB
Markdown
---
|
|
external help file: GPOZaurr-help.xml
|
|
Module Name: GPOZaurr
|
|
online version:
|
|
schema: 2.0.0
|
|
---
|
|
|
|
# Set-GPOZaurrOwner
|
|
|
|
## SYNOPSIS
|
|
Sets GPO Owner to Domain Admins or other choosen account
|
|
|
|
## SYNTAX
|
|
|
|
### Type (Default)
|
|
```
|
|
Set-GPOZaurrOwner -Type <String> [-Forest <String>] [-ExcludeDomains <String[]>] [-IncludeDomains <String[]>]
|
|
[-ExtendedForestInformation <IDictionary>] [-Principal <String>] [-SkipSysvol] [-LimitProcessing <Int32>]
|
|
[-ApprovedOwner <String[]>] [-Action <String>] [-Force] [-WhatIf] [-Confirm] [<CommonParameters>]
|
|
```
|
|
|
|
### Named
|
|
```
|
|
Set-GPOZaurrOwner [-GPOName <String>] [-GPOGuid <String>] [-Forest <String>] [-ExcludeDomains <String[]>]
|
|
[-IncludeDomains <String[]>] [-ExtendedForestInformation <IDictionary>] [-Principal <String>] [-SkipSysvol]
|
|
[-LimitProcessing <Int32>] [-ApprovedOwner <String[]>] [-Action <String>] [-Force] [-WhatIf] [-Confirm]
|
|
[<CommonParameters>]
|
|
```
|
|
|
|
## DESCRIPTION
|
|
Sets GPO Owner to Domain Admins or other choosen account.
|
|
GPO Owner is set in AD and SYSVOL unless specified otherwise.
|
|
If account doesn't require change, no change is done.
|
|
|
|
## EXAMPLES
|
|
|
|
### EXAMPLE 1
|
|
```
|
|
Set-GPOZaurrOwner -Type All -Verbose -WhatIf -LimitProcessing 2
|
|
```
|
|
|
|
## PARAMETERS
|
|
|
|
### -Type
|
|
Unknown - finds unknown Owners and sets them to Administrative (Domain Admins) or chosen principal
|
|
NotMatching - find administrative groups only and if sysvol and gpo doesn't match - replace with chosen principal or Domain Admins if not specified
|
|
Inconsistent - same as not NotMatching
|
|
NotAdministrative - combination of Unknown/NotMatching and NotAdministrative - replace with chosen principal or Domain Admins if not specified
|
|
All - if Owner is known it checks if it's Administrative, if it sn't it fixes that.
|
|
If owner is unknown it fixes it
|
|
|
|
```yaml
|
|
Type: String
|
|
Parameter Sets: Type
|
|
Aliases:
|
|
|
|
Required: True
|
|
Position: Named
|
|
Default value: None
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### -GPOName
|
|
Name of GPO.
|
|
By default all GPOs are targetted
|
|
|
|
```yaml
|
|
Type: String
|
|
Parameter Sets: Named
|
|
Aliases:
|
|
|
|
Required: False
|
|
Position: Named
|
|
Default value: None
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### -GPOGuid
|
|
GUID of GPO.
|
|
By default all GPOs are targetted
|
|
|
|
```yaml
|
|
Type: String
|
|
Parameter Sets: Named
|
|
Aliases: GUID, GPOID
|
|
|
|
Required: False
|
|
Position: Named
|
|
Default value: None
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### -Forest
|
|
Target different Forest, by default current forest is used
|
|
|
|
```yaml
|
|
Type: String
|
|
Parameter Sets: (All)
|
|
Aliases: ForestName
|
|
|
|
Required: False
|
|
Position: Named
|
|
Default value: None
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### -ExcludeDomains
|
|
Exclude domain from search, by default whole forest is scanned
|
|
|
|
```yaml
|
|
Type: String[]
|
|
Parameter Sets: (All)
|
|
Aliases:
|
|
|
|
Required: False
|
|
Position: Named
|
|
Default value: None
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### -IncludeDomains
|
|
Include only specific domains, by default whole forest is scanned
|
|
|
|
```yaml
|
|
Type: String[]
|
|
Parameter Sets: (All)
|
|
Aliases: Domain, Domains
|
|
|
|
Required: False
|
|
Position: Named
|
|
Default value: None
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### -ExtendedForestInformation
|
|
Ability to provide Forest Information from another command to speed up processing
|
|
|
|
```yaml
|
|
Type: IDictionary
|
|
Parameter Sets: (All)
|
|
Aliases:
|
|
|
|
Required: False
|
|
Position: Named
|
|
Default value: None
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### -Principal
|
|
Parameter description
|
|
|
|
```yaml
|
|
Type: String
|
|
Parameter Sets: (All)
|
|
Aliases:
|
|
|
|
Required: False
|
|
Position: Named
|
|
Default value: None
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### -SkipSysvol
|
|
Set GPO Owner only in Active Directory.
|
|
By default GPO Owner is being set in both places
|
|
|
|
```yaml
|
|
Type: SwitchParameter
|
|
Parameter Sets: (All)
|
|
Aliases:
|
|
|
|
Required: False
|
|
Position: Named
|
|
Default value: False
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### -LimitProcessing
|
|
Allows to specify maximum number of items that will be fixed in a single run.
|
|
It doesn't affect amount of GPOs processed
|
|
|
|
```yaml
|
|
Type: Int32
|
|
Parameter Sets: (All)
|
|
Aliases:
|
|
|
|
Required: False
|
|
Position: Named
|
|
Default value: 2147483647
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### -ApprovedOwner
|
|
{{ Fill ApprovedOwner Description }}
|
|
|
|
```yaml
|
|
Type: String[]
|
|
Parameter Sets: (All)
|
|
Aliases: Exclusion, Exclusions
|
|
|
|
Required: False
|
|
Position: Named
|
|
Default value: None
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### -Action
|
|
{{ Fill Action Description }}
|
|
|
|
```yaml
|
|
Type: String
|
|
Parameter Sets: (All)
|
|
Aliases:
|
|
|
|
Required: False
|
|
Position: Named
|
|
Default value: None
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### -Force
|
|
Pushes new owner regardless if it's already set or not
|
|
|
|
```yaml
|
|
Type: SwitchParameter
|
|
Parameter Sets: (All)
|
|
Aliases:
|
|
|
|
Required: False
|
|
Position: Named
|
|
Default value: False
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### -WhatIf
|
|
Shows what would happen if the cmdlet runs.
|
|
The cmdlet is not run.
|
|
|
|
```yaml
|
|
Type: SwitchParameter
|
|
Parameter Sets: (All)
|
|
Aliases: wi
|
|
|
|
Required: False
|
|
Position: Named
|
|
Default value: None
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### -Confirm
|
|
Prompts you for confirmation before running the cmdlet.
|
|
|
|
```yaml
|
|
Type: SwitchParameter
|
|
Parameter Sets: (All)
|
|
Aliases: cf
|
|
|
|
Required: False
|
|
Position: Named
|
|
Default value: None
|
|
Accept pipeline input: False
|
|
Accept wildcard characters: False
|
|
```
|
|
|
|
### CommonParameters
|
|
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
|
|
|
|
## INPUTS
|
|
|
|
## OUTPUTS
|
|
|
|
## NOTES
|
|
General notes
|
|
|
|
## RELATED LINKS
|