Interface IAssumeRolePrincipal

All Superinterfaces:
IGrantable, IPrincipal,
All Known Subinterfaces:
All Known Implementing Classes:
AccountPrincipal, AccountRootPrincipal, AnyPrincipal, ArnPrincipal, CanonicalUserPrincipal, CompositePrincipal, FederatedPrincipal, IAssumeRolePrincipal.Jsii$Proxy, OpenIdConnectPrincipal, OrganizationPrincipal, PrincipalBase, PrincipalWithConditions, SamlConsolePrincipal, SamlPrincipal, ServicePrincipal, SessionTagsPrincipal, StarPrincipal, ViaServicePrincipal, WebIdentityPrincipal

@Generated(value="jsii-pacmak/1.101.0 (build b95fe5d)", date="2024-07-12T19:34:02.961Z") @Stability(Stable) public interface IAssumeRolePrincipal extends, IPrincipal
A type of principal that has more control over its own representation in AssumeRolePolicyDocuments.

More complex types of identity providers need more control over Role's policy documents than simply { Effect: 'Allow', Action: 'AssumeRole', Principal: <Whatever> }.

If that control is necessary, they can implement IAssumeRolePrincipal to get full access to a Role's AssumeRolePolicyDocument.

  • Method Details

    • addToAssumeRolePolicy

      @Stability(Stable) void addToAssumeRolePolicy(@NotNull PolicyDocument document)
      Add the principal to the AssumeRolePolicyDocument.

      Add the statements to the AssumeRolePolicyDocument necessary to give this principal permissions to assume the given role.

      document - This parameter is required.