Set-AmsComputerAuthorizationRule
SYNOPSIS
Sets the properties of an AMS authorization rule
SYNTAX
None (Default)
Set-AmsComputerAuthorizationRule -Id <String> [-JitGroupName <String>] [-JitMaximumAccessDuration <TimeSpan>]
[-JitDefaultAccessDuration <TimeSpan>] [-JitAllowExtension] [-LapsMaximumAccessDuration <TimeSpan>]
[-LapsDefaultAccessDuration <TimeSpan>] [-LapsAllowExtension] [-Description <String>]
[-RuleExpiryDate <DateTime>] [-Disable] [-Enable] [-Notes <String>]
[-UserRequestReasonRequirement <AuditReasonFieldState>] [-NotificationChannelsSuccess <String[]>]
[-NotificationChannelsFailure <String[]>] [-AutoDcLocator] [-DoNotUseRemoteDcLocator] [-SiteName <String>]
[-DomainControllerName <String>] [<CommonParameters>]Set the rule target to a Microsoft Entra tenant
Set-AmsComputerAuthorizationRule -Id <String> -AadTenantId <String> [-JitGroupName <String>]
[-JitMaximumAccessDuration <TimeSpan>] [-JitDefaultAccessDuration <TimeSpan>] [-JitAllowExtension]
[-LapsMaximumAccessDuration <TimeSpan>] [-LapsDefaultAccessDuration <TimeSpan>] [-LapsAllowExtension]
[-Description <String>] [-RuleExpiryDate <DateTime>] [-Disable] [-Enable] [-Notes <String>]
[-UserRequestReasonRequirement <AuditReasonFieldState>] [-NotificationChannelsSuccess <String[]>]
[-NotificationChannelsFailure <String[]>] [-AutoDcLocator] [-DoNotUseRemoteDcLocator] [-SiteName <String>]
[-DomainControllerName <String>] [<CommonParameters>]Set the rule target to a Microsoft Entra group
Set the rule target to a Microsoft Entra computer
Set the rule target to an AD computer
Set the rule target to an AD group
Set the rule target to an AD container
Set the rule target to an AMS computer
Set the rule target to an AMS group
Modify the rule ACL
Modify the rule authorization script
DESCRIPTION
This cmdlet allows you to modify the properties of an authorization rule, such as updating the target of the rule, adding and removing authorized users, and configuring LAPS and JIT settings.
EXAMPLES
Example 1
Adds the specified principal to the list of allowed JIT users
Example 2
Updates the rule to use the specified authorization script
Example 3
Targets the rule to the `AccountingServers` AD group
PARAMETERS
-AadComputerId
The object ID of a Microsoft Entra computer
-AadGroupId
The object ID of a Microsoft Entra group
-AadTenantId
The tenant ID of a registered Microsoft Entra tenant
-AdComputer
The fully qualified name or SID of an Active Directory computer
-AdContainer
The DN of an Active Directory container object such as an organizational unit
-AdGroup
The fully qualified name or SID of an Active Directory group
-AddPrincipalsAllowedBitLocker
Principals to add to the allow BitLocker access list
-AddPrincipalsAllowedJit
Principals to add to the allow JIT access list
-AddPrincipalsAllowedLaps
Principals to add to the allow LAPS access list
-AddPrincipalsAllowedLapsHistory
Principals to add to the allow LAPS history access list
-AddPrincipalsDeniedBitLocker
Principals to add to the deny BitLocker access list
-AddPrincipalsDeniedJit
Principals to add to the deny JIT access list
-AddPrincipalsDeniedLaps
Principals to add to the deny LAPS access list
-AddPrincipalsDeniedLapsHistory
Principals to add to the deny LAPS history access list
-AmsComputerId
The object ID of an AMS-registered computer
-AmsGroupId
The SID of an AMS group
-AuthorizationScriptPath
The path to the authorization script to import
-Description
A description of the rule
-Disable
Indicates if the rule should be disabled
-Enable
Indicates if the rule should be enabled
-Id
The unique ID of the rule
-JitAllowExtension
Specifies if the user is allowed to extend their JIT access request before it expires
-JitGroupName
The name of the group that users will be added to when granted access to this role
-JitMaximumAccessDuration
The maximum amount of time the user can request access to this computer via JIT
-LapsAllowExtension
Specifies if the user is allowed to extend their LAPS access request before it expires
-LapsMaximumAccessDuration
The maximum amount of time the user can request access to this computer's LAPS password before it is changed
-Notes
A custom field to store notes
-NotificationChannelsFailure
A list of channel IDs or names that should be notified when a user is denied access by this rule
-NotificationChannelsSuccess
A list of channel IDs or names that should be notified when a user is granted access by this rule
-RemovePrincipalsAllowedBitLocker
Principals to remove from the allow BitLocker access list
-RemovePrincipalsAllowedJit
Principals to remove from the allow JIT access list
-RemovePrincipalsAllowedLaps
Principals to remove from the allow LAPS access list
-RemovePrincipalsAllowedLapsHistory
Principals to remove from the allow LAPS history access list
-RemovePrincipalsDeniedBitLocker
Principals to remove from the deny BitLocker access list
-RemovePrincipalsDeniedJit
Principals to remove from the deny JIT access list
-RemovePrincipalsDeniedLaps
Principals to remove from the deny LAPS access list
-RemovePrincipalsDeniedLapsHistory
Principals to remove from the deny LAPS history access list
-RuleExpiryDate
A date and time when this rule will expire, expressed in local time
-UserRequestReasonRequirement
Specifies if the user must provide a reason for the request, if they can optionally provide a reason, or are not prompted at all for a reason
-AutoDcLocator
Specifies that the AMS service should automatically find a domain controller to perform the JIT operation against
-DomainControllerName
The name of a domain controller to use when performing the JIT operation against
-DoNotUseRemoteDcLocator
Specifies that the AMS service should not attempt to use the target computer's DCLocator service to find a domain controller to perform the JIT operation against
-SiteName
The name of the site to use when trying to find a domain controller to perform the JIT operation against
-AddPrincipalsAllowedRapidLapsElevation
Principals to add to the allow RapidLAPS elevation access list
-AddPrincipalsAllowedRapidLapsLogin
Principals to add to the allow RapidLAPS login access list
-AddPrincipalsDeniedRapidLapsElevation
Principals to add to the deny RapidLAPS elevation access list
-AddPrincipalsDeniedRapidLapsLogin
Principals to add to the deny RapidLAPS login access list
-RemovePrincipalsAllowedRapidLapsElevation
Principals to remove from the allow RapidLAPS elevation access list
-RemovePrincipalsAllowedRapidLapsLogin
Principals to remove from the allow RapidLAPS login access list
-RemovePrincipalsDeniedRapidLapsElevation
Principals to remove from the deny RapidLAPS elevation access list
-RemovePrincipalsDeniedRapidLapsLogin
Principals to remove from the deny RapidLAPS login access list
-JitDefaultAccessDuration
The amount of time the user is offered to access this computer via JIT by default. This value cannot be greater than the value defined in MaximumAccessDurationJit
-LapsDefaultAccessDuration
The amount of time the user is offered to access this computer's LAPS password by default. This value cannot be greater than the value defined in MaximumAccessDurationLaps
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.
INPUTS
System.String
OUTPUTS
Lithnet.AccessManager.PowerShell.ComputerAuthorizationRulePSObject
NOTES
Use of this cmdlet requires an Enterprise Edition license.
RELATED LINKS
Last updated
Was this helpful?