Get-CMSecurityRole

SYNOPSIS

Gets security roles.

SYNTAX

SearchByName (Default)

Get-CMSecurityRole [-Name <String>] [-DisableWildcardHandling] [-ForceWildcardHandling] [<CommonParameters>]

SearchByIdMandatory

Get-CMSecurityRole -Id <String> [-DisableWildcardHandling] [-ForceWildcardHandling] [<CommonParameters>]

DESCRIPTION

The Get-CMSecurityRole cmdlet gets one or more security roles in Microsoft System Center Configuration Manager.

EXAMPLES

Example 1: Get all security roles

PS C:\> Get-CMSecurityRole

This command gets all security roles in Configuration Manager.

Example 2: Get a security role by using an ID

PS C:\> Get-CMSecurityRole -Id "SMS000CR"

This command gets the security role that has the ID SMS000CR.

Example 3: Get a security role by using a wildcard

PS C:\> Get-CMSecurityRole -Name App*

This command gets all security roles that have a name that starts with App.

PARAMETERS

-DisableWildcardHandling

DisableWildcardHandling treats wildcard characters as literal character values. Cannot be combined with ForceWildcardHandling.

Type: SwitchParameter
Parameter Sets: (All)
Aliases: 

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-ForceWildcardHandling

ForceWildcardHandling processes wildcard characters and may lead to unexpected behavior (not recommended). Cannot be combined with DisableWildcardHandling.

Type: SwitchParameter
Parameter Sets: (All)
Aliases: 

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Id

Specifies an array of IDs of security roles.

Type: String
Parameter Sets: SearchByIdMandatory
Aliases: RoleId

Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Name

Specifies an array of names of security roles.

Type: String
Parameter Sets: SearchByName
Aliases: RoleName

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

Copy-CMSecurityRole

Export-CMSecurityRole

Import-CMSecurityRole

Remove-CMSecurityRole

Remove-CMSecurityRoleFromAdministrativeUser

Set-CMSecurityRole