Interface IAssumeRolePrincipal

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

@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)", date="2023-06-19T16:29:57.313Z") @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 princpial 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.