UNPKG

cdk-iam-floyd

Version:

AWS IAM policy statement generator with fluent interface for AWS CDK

53 lines (52 loc) 2.9 kB
import { AccessLevelList } from '../../shared/access-level'; import { PolicyStatement } from '../../shared'; import { aws_iam as iam } from "aws-cdk-lib"; /** * Statement provider for service [sso-oauth](https://docs.aws.amazon.com/service-authorization/latest/reference/list_sso-oidc.html). * * @param sid [SID](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_sid.html) of the statement */ export declare class SsoOauth extends PolicyStatement { servicePrefix: string; /** * Grants permission to create and return OAuth 2.0 access tokens and refresh tokens for authorized client applications. These tokens might contain defined scopes that specify permissions such as `read:profile` or `write:data` * * Access Level: Write * * https://docs.aws.amazon.com/singlesignon/latest/OIDCAPIReference/API_CreateTokenWithIAM.html */ toCreateTokenWithIAM(): this; /** * Grants permission to validate and retrieve information about active OAuth 2.0 access tokens and refresh tokens, including their associated scopes and permissions. This permission is used only by AWS managed applications and is not documented in the IAM Identity Center OIDC API Reference * * Access Level: Write * * https://docs.aws.amazon.com/singlesignon/latest/userguide/iam-auth-access-using-resource-based-policies.html */ toIntrospectTokenWithIAM(): this; /** * Grants permission to revoke OAuth 2.0 access tokens and refresh tokens, invalidating them before their normal expiration. This permission is used only by AWS managed applications and is not documented in the IAM Identity Center OIDC API Reference * * Access Level: Write * * https://docs.aws.amazon.com/singlesignon/latest/userguide/iam-auth-access-using-resource-based-policies.html */ toRevokeTokenWithIAM(): this; protected accessLevelList: AccessLevelList; /** * Adds a resource of type Application to the statement * * https://docs.aws.amazon.com/singlesignon/latest/userguide/get-started-enable-identity-center.html * * @param instanceId - Identifier for the instanceId. * @param applicationId - Identifier for the applicationId. * @param accountId - Account of the resource; defaults to `*`, unless using the CDK, where the default is the current Stack's account. * @param partition - Partition of the AWS account [aws, aws-cn, aws-us-gov]; defaults to `aws`, unless using the CDK, where the default is the current Stack's partition. */ onApplication(instanceId: string, applicationId: string, accountId?: string, partition?: string): this; /** * Statement provider for service [sso-oauth](https://docs.aws.amazon.com/service-authorization/latest/reference/list_sso-oidc.html). * */ constructor(props?: iam.PolicyStatementProps); }