0% found this document useful (0 votes)
42 views8 pages

AWS S3 Bucket Policy Script

This document contains an IAM policy that allows full access to an S3 bucket called "myBucket" and all objects within it by specifying the "s3:*" action on the specified ARN. It also shows code to upload a file to S3 using the AWS SDK for JavaScript in Node.js.

Uploaded by

Kani
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
42 views8 pages

AWS S3 Bucket Policy Script

This document contains an IAM policy that allows full access to an S3 bucket called "myBucket" and all objects within it by specifying the "s3:*" action on the specified ARN. It also shows code to upload a file to S3 using the AWS SDK for JavaScript in Node.js.

Uploaded by

Kani
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

{

“Version”: “2012-10-17”,
“Statement”: [{
“Effect”: “Allow”,
“Action”: [“s3:*”],

[“arn:aws:s3:::myBucket/*”]
}]
}

{
var s3 = new AWS.S3({apiVersion: ‘2006-03-01’}); “Version”: “2012-10-17”,
var params = {Bucket: ‘myBucket’, Key: imageFileName}; “Statement”: [{
var require(‘fs’).createWriteStream( ); “Effect”: “Allow”,
“Action”: [ ],

[“arn:aws:s3:::myBucket/*”]
{ }]
“Version”: “2012-10-17”, }
“Statement”: [{
“Effect”: “Allow”,
“Action”: [“s3:*”],

[“arn:aws:s3:::*”]
}]
}
01 01
10 10
SQL SQL

You might also like