Class PermissionsBoundary
Modify the Permissions Boundaries of Users and Roles in a construct tree.
Inheritance
Namespace: Amazon.CDK.AWS.IAM
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class PermissionsBoundary : DeputyBase
Syntax (vb)
Public Class PermissionsBoundary
Inherits DeputyBase
Remarks
var policy = ManagedPolicy.FromAwsManagedPolicyName("ReadOnlyAccess");
PermissionsBoundary.Of(this).Apply(policy);
ExampleMetadata: infused
Examples
Project project;
PermissionsBoundary.Of(project).Apply(new UntrustedCodeBoundaryPolicy(this, "Boundary"));
Synopsis
Constructors
PermissionsBoundary(ByRefValue) | Used by jsii to construct an instance of this class from a Javascript-owned object reference |
PermissionsBoundary(DeputyBase.DeputyProps) | Used by jsii to construct an instance of this class from DeputyProps |
Methods
Apply(IManagedPolicy) | Apply the given policy as Permissions Boundary to all Roles and Users in the scope. |
Clear() | Remove previously applied Permissions Boundaries. |
Of(IConstruct) | Access the Permissions Boundaries of a construct tree. |
Constructors
PermissionsBoundary(ByRefValue)
Used by jsii to construct an instance of this class from a Javascript-owned object reference
protected PermissionsBoundary(ByRefValue reference)
Parameters
- reference Amazon.JSII.Runtime.Deputy.ByRefValue
The Javascript-owned object reference
PermissionsBoundary(DeputyBase.DeputyProps)
Used by jsii to construct an instance of this class from DeputyProps
protected PermissionsBoundary(DeputyBase.DeputyProps props)
Parameters
- props Amazon.JSII.Runtime.Deputy.DeputyBase.DeputyProps
The deputy props
Methods
Apply(IManagedPolicy)
Apply the given policy as Permissions Boundary to all Roles and Users in the scope.
public virtual void Apply(IManagedPolicy boundaryPolicy)
Parameters
- boundaryPolicy IManagedPolicy
Remarks
Will override any Permissions Boundaries configured previously; in case a Permission Boundary is applied in multiple scopes, the Boundary applied closest to the Role wins.
Clear()
Remove previously applied Permissions Boundaries.
public virtual void Clear()
Of(IConstruct)
Access the Permissions Boundaries of a construct tree.
public static PermissionsBoundary Of(IConstruct scope)
Parameters
- scope Constructs.IConstruct
Returns