Изменить

Поделиться через


Set-EntraCustomSecurityAttributeDefinitionAllowedValue

Updates an existing custom security attribute definition predefined value.

Syntax

Set-EntraCustomSecurityAttributeDefinitionAllowedValue
   [-IsActive <Boolean>]
   -CustomSecurityAttributeDefinitionId <String>
   -Id <String>
   [<CommonParameters>]

Description

The Set-EntraCustomSecurityAttributeDefinitionAllowedValue cmdlet update a Microsoft Entra ID custom security attribute definition predefined value object identified by ID. Specify CustomSecurityAttributeDefinitionId and Id parameter to update a Microsoft Entra ID custom security attribute definition predefined value.

The signed-in user must be assigned one of the following directory roles:

  • Attribute Definition Administrator

Examples

Example 1: Update a custom security attribute definition predefined value

Connect-Entra -Scopes 'CustomSecAttributeDefinition.ReadWrite.All'
$attributeDefinition = Get-EntraCustomSecurityAttributeDefinition | Where-Object { $_.Name -eq 'Engineering' }
Set-EntraCustomSecurityAttributeDefinitionAllowedValue -CustomSecurityAttributeDefinitionId $attributeDefinition.Id -Id 'Alpine' -IsActive $true

This example update a custom security attribute definition predefined value.

  • -CustomSecurityAttributeDefinitionId parameter specifies the custom security attribute definition ID.
  • -Id parameter specifies the ID of Microsoft Entra ID Object.
  • -IsActive parameter specifies the predefined value is active or deactivated.

Parameters

-CustomSecurityAttributeDefinitionId

The unique identifier of customSecurityAttributeDefinition.

Type:System.String
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-Id

Indicates whether the predefined value is active or deactivated. If set to false, this predefined value cannot be assigned to any additional supported directory objects. This field is optional.

Type:System.String
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-IsActive

Indicates whether the predefined value is active or deactivated. If set to false, this predefined value can't be assigned to any other supported directory objects.

Type:System.Boolean
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

Inputs

System.String

Outputs

System.Object