Skip to main content

Public Readable Amazon S3 Bucket Policy

·107 words·1 min· ·
Amazon S3 Cloudfront Bucket Policy
Ariejan de Vroom
Author
Ariejan de Vroom
Jack of all Trades, Professional Software Craftsman

Amazon S3 allows you to set per-file permissions to grant read and/or write access. This is nice, but sometimes you just want to share your whole bucket with the world.

Luckily, Amazon features bucket policies, which allow you to define permissions for an entire bucket. ~ This example will give read access to Everyone on all files in your bucket.

{
	"Version":"2008-10-17",
	"Statement":[{
	"Sid":"AllowPublicRead",
		"Effect":"Allow",
		"Principal": {
			"AWS": "*"
			},
		"Action":["s3:GetObject"],
		"Resource":["arn:aws:s3:::bucket/*"
		]
	}
	]
}

Make sure you replace bucket in arn:aws:s3:::bucket/* with your bucket name.

After setting this bucket policy (see ‘Bucket -> Properties -> Add Bucket Policy’), all your files will be publicly readable.

Related

How to order your Kindle from the Netherlands
·635 words·3 mins
General Amazon Kindle Ereader Ebook
The epic e-reading experience: Amazone Kindle
·413 words·2 mins
General Amazon Kindle Kindle2 E-Reader Ereader Ebook Books Paperbacks Reading