bucket_policy
Gets an individual bucket_policy
resource
Overview
Name | bucket_policy |
Type | Resource |
Description | bucket_policy |
Id | awscc.s3.bucket_policy |
Fields
Name | Datatype | Description |
---|---|---|
bucket | string | The name of the Amazon S3 bucket to which the policy applies. |
policy_document | object | A policy document containing permissions to add to the specified bucket. In IAM, you must provide policy documents in JSON format. However, in CloudFormation you can provide the policy in JSON or YAML format because CloudFormation converts YAML to JSON before submitting it to IAM. For more information, see the AWS::IAM::Policy [PolicyDocument](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-iam-policy.html#cfn-iam-policy-policydocument) resource description in this guide and [Access Policy Language Overview](https://docs.aws.amazon.com/AmazonS3/latest/dev/access-policy-language-overview.html) in the *Amazon S3 User Guide*. |
region | string | AWS region. |
Methods
Currently only SELECT
is supported for this resource resource.
Example
SELECT
region,
bucket,
policy_document
FROM awscc.s3.bucket_policy
WHERE data__Identifier = '<Bucket>';
Permissions
To operate on the bucket_policy
resource, the following permissions are required:
Read
s3:GetBucketPolicy
Update
s3:GetBucketPolicy,
s3:PutBucketPolicy
Delete
s3:GetBucketPolicy,
s3:DeleteBucketPolicy