UNPKG

cdk-iam-floyd

Version:

AWS IAM policy statement generator with fluent interface for AWS CDK

1,382 lines 150 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.Cloudfront = void 0; const shared_1 = require("../../shared"); /** * Statement provider for service [cloudfront](https://docs.aws.amazon.com/service-authorization/latest/reference/list_amazoncloudfront.html). * * @param sid [SID](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_sid.html) of the statement */ class Cloudfront extends shared_1.PolicyStatement { /** * Grants permission to associate an alias to a CloudFront distribution * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_AssociateAlias.html */ toAssociateAlias() { return this.to('AssociateAlias'); } /** * Grants permission to copy an existing distribution and create a new web distribution * * Access Level: Write * * Dependent actions: * - cloudfront:CopyDistribution * - cloudfront:CreateDistribution * - cloudfront:GetDistribution * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CopyDistribution.html */ toCopyDistribution() { return this.to('CopyDistribution'); } /** * Grants permission to add a new cache policy to CloudFront * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateCachePolicy.html */ toCreateCachePolicy() { return this.to('CreateCachePolicy'); } /** * Grants permission to create a new CloudFront origin access identity * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateCloudFrontOriginAccessIdentity.html */ toCreateCloudFrontOriginAccessIdentity() { return this.to('CreateCloudFrontOriginAccessIdentity'); } /** * Grants permission to add a new continuous-deployment policy to CloudFront * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateContinuousDeploymentPolicy.html */ toCreateContinuousDeploymentPolicy() { return this.to('CreateContinuousDeploymentPolicy'); } /** * Grants permission to create a new web distribution * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateDistribution.html */ toCreateDistribution() { return this.to('CreateDistribution'); } /** * Grants permission to create a new field-level encryption configuration * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateFieldLevelEncryptionConfig.html */ toCreateFieldLevelEncryptionConfig() { return this.to('CreateFieldLevelEncryptionConfig'); } /** * Grants permission to create a field-level encryption profile * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateFieldLevelEncryptionProfile.html */ toCreateFieldLevelEncryptionProfile() { return this.to('CreateFieldLevelEncryptionProfile'); } /** * Grants permission to create a CloudFront function * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateFunction.html */ toCreateFunction() { return this.to('CreateFunction'); } /** * Grants permission to create a new invalidation batch request * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateInvalidation.html */ toCreateInvalidation() { return this.to('CreateInvalidation'); } /** * Grants permission to add a new key group to CloudFront * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateKeyGroup.html */ toCreateKeyGroup() { return this.to('CreateKeyGroup'); } /** * Grants permission to create a CloudFront KeyValueStore * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateKeyValueStore.html */ toCreateKeyValueStore() { return this.to('CreateKeyValueStore'); } /** * Grants permission to enable additional CloudWatch metrics for the specified CloudFront distribution. The additional metrics incur an additional cost * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateMonitoringSubscription.html */ toCreateMonitoringSubscription() { return this.to('CreateMonitoringSubscription'); } /** * Grants permission to create a new origin access control * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateOriginAccessControl.html */ toCreateOriginAccessControl() { return this.to('CreateOriginAccessControl'); } /** * Grants permission to add a new origin request policy to CloudFront * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateOriginRequestPolicy.html */ toCreateOriginRequestPolicy() { return this.to('CreateOriginRequestPolicy'); } /** * Grants permission to add a new public key to CloudFront * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreatePublicKey.html */ toCreatePublicKey() { return this.to('CreatePublicKey'); } /** * Grants permission to create a real-time log configuration * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateRealtimeLogConfig.html */ toCreateRealtimeLogConfig() { return this.to('CreateRealtimeLogConfig'); } /** * Grants permission to add a new response headers policy to CloudFront * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateResponseHeadersPolicy.html */ toCreateResponseHeadersPolicy() { return this.to('CreateResponseHeadersPolicy'); } /** * Grants permission to create a new savings plan * * Access Level: Write * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/cf-api-permissions-ref.html */ toCreateSavingsPlan() { return this.to('CreateSavingsPlan'); } /** * Grants permission to create a new RTMP distribution * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateStreamingDistribution.html */ toCreateStreamingDistribution() { return this.to('CreateStreamingDistribution'); } /** * Grants permission to create a new RTMP distribution with tags * * Access Level: Write * * Possible conditions: * - .ifAwsRequestTag() * - .ifAwsTagKeys() * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_CreateStreamingDistributionWithTags.html */ toCreateStreamingDistributionWithTags() { return this.to('CreateStreamingDistributionWithTags'); } /** * Grants permission to delete a cache policy * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DeleteCachePolicy.html */ toDeleteCachePolicy() { return this.to('DeleteCachePolicy'); } /** * Grants permission to delete a CloudFront origin access identity * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DeleteCloudFrontOriginAccessIdentity.html */ toDeleteCloudFrontOriginAccessIdentity() { return this.to('DeleteCloudFrontOriginAccessIdentity'); } /** * Grants permission to delete a continuous-deployment policy * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DeleteContinuousDeploymentPolicy.html */ toDeleteContinuousDeploymentPolicy() { return this.to('DeleteContinuousDeploymentPolicy'); } /** * Grants permission to delete a web distribution * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DeleteDistribution.html */ toDeleteDistribution() { return this.to('DeleteDistribution'); } /** * Grants permission to delete a field-level encryption configuration * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DeleteFieldLevelEncryptionConfig.html */ toDeleteFieldLevelEncryptionConfig() { return this.to('DeleteFieldLevelEncryptionConfig'); } /** * Grants permission to delete a field-level encryption profile * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DeleteFieldLevelEncryptionProfile.html */ toDeleteFieldLevelEncryptionProfile() { return this.to('DeleteFieldLevelEncryptionProfile'); } /** * Grants permission to delete a CloudFront function * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DeleteFunction.html */ toDeleteFunction() { return this.to('DeleteFunction'); } /** * Grants permission to delete a key group * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DeleteKeyGroup.html */ toDeleteKeyGroup() { return this.to('DeleteKeyGroup'); } /** * Grants permission to delete a CloudFront KeyValueStore * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DeleteKeyValueStore.html */ toDeleteKeyValueStore() { return this.to('DeleteKeyValueStore'); } /** * Grants permission to disable additional CloudWatch metrics for the specified CloudFront distribution * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DeleteMonitoringSubscription.html */ toDeleteMonitoringSubscription() { return this.to('DeleteMonitoringSubscription'); } /** * Grants permission to delete an origin access control * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DeleteOriginAccessControl.html */ toDeleteOriginAccessControl() { return this.to('DeleteOriginAccessControl'); } /** * Grants permission to delete an origin request policy * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DeleteOriginRequestPolicy.html */ toDeleteOriginRequestPolicy() { return this.to('DeleteOriginRequestPolicy'); } /** * Grants permission to delete a public key from CloudFront * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DeletePublicKey.html */ toDeletePublicKey() { return this.to('DeletePublicKey'); } /** * Grants permission to delete a real-time log configuration * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DeleteRealtimeLogConfig.html */ toDeleteRealtimeLogConfig() { return this.to('DeleteRealtimeLogConfig'); } /** * Grants permission to delete a response headers policy * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DeleteResponseHeadersPolicy.html */ toDeleteResponseHeadersPolicy() { return this.to('DeleteResponseHeadersPolicy'); } /** * Grants permission to delete an RTMP distribution * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DeleteStreamingDistribution.html */ toDeleteStreamingDistribution() { return this.to('DeleteStreamingDistribution'); } /** * Grants permission to get a CloudFront function summary * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DescribeFunction.html */ toDescribeFunction() { return this.to('DescribeFunction'); } /** * Grants permission to get a CloudFront KeyValueStore summary * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_DescribeKeyValueStore.html */ toDescribeKeyValueStore() { return this.to('DescribeKeyValueStore'); } /** * Grants permission to get the cache policy * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetCachePolicy.html */ toGetCachePolicy() { return this.to('GetCachePolicy'); } /** * Grants permission to get the cache policy configuration * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetCachePolicyConfig.html */ toGetCachePolicyConfig() { return this.to('GetCachePolicyConfig'); } /** * Grants permission to get the information about a CloudFront origin access identity * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetCloudFrontOriginAccessIdentity.html */ toGetCloudFrontOriginAccessIdentity() { return this.to('GetCloudFrontOriginAccessIdentity'); } /** * Grants permission to get the configuration information about a Cloudfront origin access identity * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetCloudFrontOriginAccessIdentityConfig.html */ toGetCloudFrontOriginAccessIdentityConfig() { return this.to('GetCloudFrontOriginAccessIdentityConfig'); } /** * Grants permission to get the continuous-deployment policy * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetContinuousDeploymentPolicy.html */ toGetContinuousDeploymentPolicy() { return this.to('GetContinuousDeploymentPolicy'); } /** * Grants permission to get the continuous-deployment policy configuration * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetContinuousDeploymentPolicyConfig.html */ toGetContinuousDeploymentPolicyConfig() { return this.to('GetContinuousDeploymentPolicyConfig'); } /** * Grants permission to get the information about a web distribution * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetDistribution.html */ toGetDistribution() { return this.to('GetDistribution'); } /** * Grants permission to get the configuration information about a distribution * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetDistributionConfig.html */ toGetDistributionConfig() { return this.to('GetDistributionConfig'); } /** * Grants permission to get the field-level encryption configuration information * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetFieldLevelEncryption.html */ toGetFieldLevelEncryption() { return this.to('GetFieldLevelEncryption'); } /** * Grants permission to get the field-level encryption configuration information * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetFieldLevelEncryptionConfig.html */ toGetFieldLevelEncryptionConfig() { return this.to('GetFieldLevelEncryptionConfig'); } /** * Grants permission to get the field-level encryption configuration information * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetFieldLevelEncryptionProfile.html */ toGetFieldLevelEncryptionProfile() { return this.to('GetFieldLevelEncryptionProfile'); } /** * Grants permission to get the field-level encryption profile configuration information * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetFieldLevelEncryptionProfileConfig.html */ toGetFieldLevelEncryptionProfileConfig() { return this.to('GetFieldLevelEncryptionProfileConfig'); } /** * Grants permission to get a CloudFront function's code * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetFunction.html */ toGetFunction() { return this.to('GetFunction'); } /** * Grants permission to get the information about an invalidation * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetInvalidation.html */ toGetInvalidation() { return this.to('GetInvalidation'); } /** * Grants permission to get a key group * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetKeyGroup.html */ toGetKeyGroup() { return this.to('GetKeyGroup'); } /** * Grants permission to get a key group configuration * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetKeyGroupConfig.html */ toGetKeyGroupConfig() { return this.to('GetKeyGroupConfig'); } /** * Grants permission to get information about whether additional CloudWatch metrics are enabled for the specified CloudFront distribution * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetMonitoringSubscription.html */ toGetMonitoringSubscription() { return this.to('GetMonitoringSubscription'); } /** * Grants permission to get the origin access control * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetOriginAccessControl.html */ toGetOriginAccessControl() { return this.to('GetOriginAccessControl'); } /** * Grants permission to get the origin access control configuration * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetOriginAccessControlConfig.html */ toGetOriginAccessControlConfig() { return this.to('GetOriginAccessControlConfig'); } /** * Grants permission to get the origin request policy * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetOriginRequestPolicy.html */ toGetOriginRequestPolicy() { return this.to('GetOriginRequestPolicy'); } /** * Grants permission to get the origin request policy configuration * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetOriginRequestPolicyConfig.html */ toGetOriginRequestPolicyConfig() { return this.to('GetOriginRequestPolicyConfig'); } /** * Grants permission to get the public key information * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetPublicKey.html */ toGetPublicKey() { return this.to('GetPublicKey'); } /** * Grants permission to get the public key configuration information * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetPublicKeyConfig.html */ toGetPublicKeyConfig() { return this.to('GetPublicKeyConfig'); } /** * Grants permission to get a real-time log configuration * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetRealtimeLogConfig.html */ toGetRealtimeLogConfig() { return this.to('GetRealtimeLogConfig'); } /** * Grants permission to get the response headers policy * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetResponseHeadersPolicy.html */ toGetResponseHeadersPolicy() { return this.to('GetResponseHeadersPolicy'); } /** * Grants permission to get the response headers policy configuration * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetResponseHeadersPolicyConfig.html */ toGetResponseHeadersPolicyConfig() { return this.to('GetResponseHeadersPolicyConfig'); } /** * Grants permission to get a savings plan * * Access Level: Read * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/cf-api-permissions-ref.html */ toGetSavingsPlan() { return this.to('GetSavingsPlan'); } /** * Grants permission to get the information about an RTMP distribution * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetStreamingDistribution.html */ toGetStreamingDistribution() { return this.to('GetStreamingDistribution'); } /** * Grants permission to get the configuration information about a streaming distribution * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_GetStreamingDistributionConfig.html */ toGetStreamingDistributionConfig() { return this.to('GetStreamingDistributionConfig'); } /** * Grants permission to list all cache policies that have been created in CloudFront for this account * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListCachePolicies.html */ toListCachePolicies() { return this.to('ListCachePolicies'); } /** * Grants permission to list your CloudFront origin access identities * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListCloudFrontOriginAccessIdentities.html */ toListCloudFrontOriginAccessIdentities() { return this.to('ListCloudFrontOriginAccessIdentities'); } /** * Grants permission to list all aliases that conflict with the given alias in CloudFront * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListConflictingAliases.html */ toListConflictingAliases() { return this.to('ListConflictingAliases'); } /** * Grants permission to list all continuous-deployment policies in the account * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListContinuousDeploymentPolicies.html */ toListContinuousDeploymentPolicies() { return this.to('ListContinuousDeploymentPolicies'); } /** * Grants permission to list the distributions associated with your AWS account * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListDistributions.html */ toListDistributions() { return this.to('ListDistributions'); } /** * Grants permission to list distribution IDs for distributions that have a cache behavior that's associated with the specified cache policy * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListDistributionsByCachePolicyId.html */ toListDistributionsByCachePolicyId() { return this.to('ListDistributionsByCachePolicyId'); } /** * Grants permission to list distribution IDs for distributions that have a cache behavior that's associated with the specified key group * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListDistributionsByKeyGroup.html */ toListDistributionsByKeyGroup() { return this.to('ListDistributionsByKeyGroup'); } /** * Grants permission to list the distributions associated a Lambda function * * Access Level: List * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/cf-api-permissions-ref.html */ toListDistributionsByLambdaFunction() { return this.to('ListDistributionsByLambdaFunction'); } /** * Grants permission to list distribution IDs for distributions that have a cache behavior that's associated with the specified origin request policy * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListDistributionsByOriginRequestPolicyId.html */ toListDistributionsByOriginRequestPolicyId() { return this.to('ListDistributionsByOriginRequestPolicyId'); } /** * Grants permission to get a list of distributions that have a cache behavior that’s associated with the specified real-time log configuration * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListDistributionsByRealtimeLogConfig.html */ toListDistributionsByRealtimeLogConfig() { return this.to('ListDistributionsByRealtimeLogConfig'); } /** * Grants permission to list distribution IDs for distributions that have a cache behavior that's associated with the specified response headers policy * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListDistributionsByResponseHeadersPolicyId.html */ toListDistributionsByResponseHeadersPolicyId() { return this.to('ListDistributionsByResponseHeadersPolicyId'); } /** * Grants permission to list the distributions associated with your AWS account with given AWS WAF web ACL * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListDistributionsByWebACLId.html */ toListDistributionsByWebACLId() { return this.to('ListDistributionsByWebACLId'); } /** * Grants permission to list all field-level encryption configurations that have been created in CloudFront for this account * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListFieldLevelEncryptionConfigs.html */ toListFieldLevelEncryptionConfigs() { return this.to('ListFieldLevelEncryptionConfigs'); } /** * Grants permission to list all field-level encryption profiles that have been created in CloudFront for this account * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListFieldLevelEncryptionProfiles.html */ toListFieldLevelEncryptionProfiles() { return this.to('ListFieldLevelEncryptionProfiles'); } /** * Grants permission to get a list of CloudFront functions * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListFunctions.html */ toListFunctions() { return this.to('ListFunctions'); } /** * Grants permission to list your invalidation batches * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListInvalidations.html */ toListInvalidations() { return this.to('ListInvalidations'); } /** * Grants permission to list all key groups that have been created in CloudFront for this account * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListKeyGroups.html */ toListKeyGroups() { return this.to('ListKeyGroups'); } /** * Grants permission to get a list of CloudFront KeyValueStores * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListKeyValueStores.html */ toListKeyValueStores() { return this.to('ListKeyValueStores'); } /** * Grants permission to list all origin access controls in the account * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListOriginAccessControls.html */ toListOriginAccessControls() { return this.to('ListOriginAccessControls'); } /** * Grants permission to list all origin request policies that have been created in CloudFront for this account * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListOriginRequestPolicies.html */ toListOriginRequestPolicies() { return this.to('ListOriginRequestPolicies'); } /** * Grants permission to list all public keys that have been added to CloudFront for this account * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListPublicKeys.html */ toListPublicKeys() { return this.to('ListPublicKeys'); } /** * Grants permission to list CloudFront rate cards for the account * * Access Level: List * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/cf-api-permissions-ref.html */ toListRateCards() { return this.to('ListRateCards'); } /** * Grants permission to get a list of real-time log configurations * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListRealtimeLogConfigs.html */ toListRealtimeLogConfigs() { return this.to('ListRealtimeLogConfigs'); } /** * Grants permission to list all response headers policies that have been created in CloudFront for this account * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListResponseHeadersPolicies.html */ toListResponseHeadersPolicies() { return this.to('ListResponseHeadersPolicies'); } /** * Grants permission to list savings plans in the account * * Access Level: List * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/cf-api-permissions-ref.html */ toListSavingsPlans() { return this.to('ListSavingsPlans'); } /** * Grants permission to list your RTMP distributions * * Access Level: List * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListStreamingDistributions.html */ toListStreamingDistributions() { return this.to('ListStreamingDistributions'); } /** * Grants permission to list tags for a CloudFront resource * * Access Level: Read * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_ListTagsForResource.html */ toListTagsForResource() { return this.to('ListTagsForResource'); } /** * Grants permission to list CloudFront usage * * Access Level: List * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/cf-api-permissions-ref.html */ toListUsages() { return this.to('ListUsages'); } /** * Grants permission to publish a CloudFront function * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_PublishFunction.html */ toPublishFunction() { return this.to('PublishFunction'); } /** * Grants permission to add tags to a CloudFront resource * * Access Level: Tagging * * Possible conditions: * - .ifAwsRequestTag() * - .ifAwsTagKeys() * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_TagResource.html */ toTagResource() { return this.to('TagResource'); } /** * Grants permission to test a CloudFront function * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_TestFunction.html */ toTestFunction() { return this.to('TestFunction'); } /** * Grants permission to remove tags from a CloudFront resource * * Access Level: Tagging * * Possible conditions: * - .ifAwsTagKeys() * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UntagResource.html */ toUntagResource() { return this.to('UntagResource'); } /** * Grants permission to update a cache policy * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateCachePolicy.html */ toUpdateCachePolicy() { return this.to('UpdateCachePolicy'); } /** * Grants permission to set the configuration for a CloudFront origin access identity * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateCloudFrontOriginAccessIdentity.html */ toUpdateCloudFrontOriginAccessIdentity() { return this.to('UpdateCloudFrontOriginAccessIdentity'); } /** * Grants permission to update a continuous-deployment policy * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateContinuousDeploymentPolicy.html */ toUpdateContinuousDeploymentPolicy() { return this.to('UpdateContinuousDeploymentPolicy'); } /** * Grants permission to update the configuration for a web distribution * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateDistribution.html */ toUpdateDistribution() { return this.to('UpdateDistribution'); } /** * Grants permission to update a field-level encryption configuration * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateFieldLevelEncryptionConfig.html */ toUpdateFieldLevelEncryptionConfig() { return this.to('UpdateFieldLevelEncryptionConfig'); } /** * Grants permission to update a field-level encryption profile * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateFieldLevelEncryptionProfile.html */ toUpdateFieldLevelEncryptionProfile() { return this.to('UpdateFieldLevelEncryptionProfile'); } /** * Grants permission to update a CloudFront function * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateFunction.html */ toUpdateFunction() { return this.to('UpdateFunction'); } /** * Grants permission to update a key group * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateKeyGroup.html */ toUpdateKeyGroup() { return this.to('UpdateKeyGroup'); } /** * Grants permission to update a CloudFront KeyValueStore * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateKeyValueStore.html */ toUpdateKeyValueStore() { return this.to('UpdateKeyValueStore'); } /** * Grants permission to update an origin access control * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateOriginAccessControl.html */ toUpdateOriginAccessControl() { return this.to('UpdateOriginAccessControl'); } /** * Grants permission to update an origin request policy * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateOriginRequestPolicy.html */ toUpdateOriginRequestPolicy() { return this.to('UpdateOriginRequestPolicy'); } /** * Grants permission to update public key information * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdatePublicKey.html */ toUpdatePublicKey() { return this.to('UpdatePublicKey'); } /** * Grants permission to update a real-time log configuration * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateRealtimeLogConfig.html */ toUpdateRealtimeLogConfig() { return this.to('UpdateRealtimeLogConfig'); } /** * Grants permission to update a response headers policy * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateResponseHeadersPolicy.html */ toUpdateResponseHeadersPolicy() { return this.to('UpdateResponseHeadersPolicy'); } /** * Grants permission to update a savings plan * * Access Level: Write * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/cf-api-permissions-ref.html */ toUpdateSavingsPlan() { return this.to('UpdateSavingsPlan'); } /** * Grants permission to update the configuration for an RTMP distribution * * Access Level: Write * * https://docs.aws.amazon.com/cloudfront/latest/APIReference/API_UpdateStreamingDistribution.html */ toUpdateStreamingDistribution() { return this.to('UpdateStreamingDistribution'); } /** * Adds a resource of type distribution to the statement * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/distribution-working-with.html * * @param distributionId - Identifier for the distributionId. * @param account - 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. * * Possible conditions: * - .ifAwsResourceTag() */ onDistribution(distributionId, account, partition) { return this.on(`arn:${partition ?? this.defaultPartition}:cloudfront::${account ?? this.defaultAccount}:distribution/${distributionId}`); } /** * Adds a resource of type streaming-distribution to the statement * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/distribution-working-with.html * * @param distributionId - Identifier for the distributionId. * @param account - 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. * * Possible conditions: * - .ifAwsResourceTag() */ onStreamingDistribution(distributionId, account, partition) { return this.on(`arn:${partition ?? this.defaultPartition}:cloudfront::${account ?? this.defaultAccount}:streaming-distribution/${distributionId}`); } /** * Adds a resource of type origin-access-identity to the statement * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/private-content-restricting-access-to-s3.html#private-content-restricting-access-to-s3-overview * * @param id - Identifier for the id. * @param account - 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. */ onOriginAccessIdentity(id, account, partition) { return this.on(`arn:${partition ?? this.defaultPartition}:cloudfront::${account ?? this.defaultAccount}:origin-access-identity/${id}`); } /** * Adds a resource of type field-level-encryption-config to the statement * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/field-level-encryption.html * * @param id - Identifier for the id. * @param account - 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. */ onFieldLevelEncryptionConfig(id, account, partition) { return this.on(`arn:${partition ?? this.defaultPartition}:cloudfront::${account ?? this.defaultAccount}:field-level-encryption-config/${id}`); } /** * Adds a resource of type field-level-encryption-profile to the statement * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/field-level-encryption.html * * @param id - Identifier for the id. * @param account - 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. */ onFieldLevelEncryptionProfile(id, account, partition) { return this.on(`arn:${partition ?? this.defaultPartition}:cloudfront::${account ?? this.defaultAccount}:field-level-encryption-profile/${id}`); } /** * Adds a resource of type cache-policy to the statement * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/working-with-policies.html * * @param id - Identifier for the id. * @param account - 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. */ onCachePolicy(id, account, partition) { return this.on(`arn:${partition ?? this.defaultPartition}:cloudfront::${account ?? this.defaultAccount}:cache-policy/${id}`); } /** * Adds a resource of type origin-request-policy to the statement * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/working-with-policies.html * * @param id - Identifier for the id. * @param account - 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. */ onOriginRequestPolicy(id, account, partition) { return this.on(`arn:${partition ?? this.defaultPartition}:cloudfront::${account ?? this.defaultAccount}:origin-request-policy/${id}`); } /** * Adds a resource of type realtime-log-config to the statement * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/real-time-logs.html * * @param name - Identifier for the name. * @param account - 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. */ onRealtimeLogConfig(name, account, partition) { return this.on(`arn:${partition ?? this.defaultPartition}:cloudfront::${account ?? this.defaultAccount}:realtime-log-config/${name}`); } /** * Adds a resource of type function to the statement * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/cloudfront-functions.html * * @param name - Identifier for the name. * @param account - 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. */ onFunction(name, account, partition) { return this.on(`arn:${partition ?? this.defaultPartition}:cloudfront::${account ?? this.defaultAccount}:function/${name}`); } /** * Adds a resource of type key-value-store to the statement * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/kvs-with-functions.html * * @param name - Identifier for the name. * @param account - 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. */ onKeyValueStore(name, account, partition) { return this.on(`arn:${partition ?? this.defaultPartition}:cloudfront::${account ?? this.defaultAccount}:key-value-store/${name}`); } /** * Adds a resource of type response-headers-policy to the statement * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/working-with-policies.html * * @param id - Identifier for the id. * @param account - 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. */ onResponseHeadersPolicy(id, account, partition) { return this.on(`arn:${partition ?? this.defaultPartition}:cloudfront::${account ?? this.defaultAccount}:response-headers-policy/${id}`); } /** * Adds a resource of type origin-access-control to the statement * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/working-with-policies.html * * @param id - Identifier for the id. * @param account - 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. */ onOriginAccessControl(id, account, partition) { return this.on(`arn:${partition ?? this.defaultPartition}:cloudfront::${account ?? this.defaultAccount}:origin-access-control/${id}`); } /** * Adds a resource of type continuous-deployment-policy to the statement * * https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/working-with-policies.html * * @param id - Identifier for the id. * @param account - 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. */ onContinuousDeploymentPolicy(id, account, partition) { return this.on(`arn:${partition ?? this.defaultPartition}:cloudfront::${account ?? this.defaultAccount}:continuous-deployment-policy/${id}`); } /** * Filters access by the presence of tag key-value pairs in the request * * https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_condition-keys.html#condition-keys-requesttag * * Applies to actions: * - .toCreateStreamingDistributionWithTags() * - .toTagResource() * * @param tagKey The tag key to check * @param value The value(s) to check * @param operator Works with [string operators](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_condition_operators.html#Conditions_String). **Default:** `StringLike` */ ifAwsRequestTag(tagKey, value, operator) { return this.if(`aws:RequestTag/${tagKey}`, value, operator ?? 'StringLike'); } /** * Filters access by tag key-value pairs attached to the resource * * https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_condition-keys.html#condition-keys-resourcetag * * Applies to resource types: * - distribution * - streaming-distribution * * @param tagKey The tag key to check * @param value The value(s) to check * @param operator Works with [string operators](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_condition_operators.html#Conditions_String). **Default:** `StringLike` */ ifAwsResourceTag(tagKey, value, operator) { return this.if(`aws:ResourceTag/${tagKey}`, value, operator ?? 'StringLike'); } /** * Filt