-
Notifications
You must be signed in to change notification settings - Fork 0
Get SudoPreferenceRule
dscbot edited this page Sep 20, 2026
·
1 revision
Gets registered sudo preference rules.
Get-SudoPreferenceRule [-All] [<CommonParameters>]
Get-SudoPreferenceRule -Executable <String> [-ParameterFilterRule <Object>]
[<CommonParameters>]
Returns all registered rules or filters rules by executable and, optionally, by the exact parameter-filter object.
Get-SudoPreferenceRule -Executable 'dpkg'
Returns all rules registered for dpkg.
Returns every registered sudo preference rule.
Type: SwitchParameter
Parameter Sets: all
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: FalseSpecifies the executable whose registered rules should be returned.
Type: String
Parameter Sets: byCommand
Aliases: Command
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseSpecifies the exact script block or wildcard filter to match.
Type: Object
Parameter Sets: byCommand
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseThis cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.