Created
June 14, 2020 21:30
-
-
Save karen-kua/6a2303c1ce6e715eb3e32e98e2ed169c to your computer and use it in GitHub Desktop.
AWS referer s3 bucket policy
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "Version": "2012-10-17", | |
| "Statement": [ | |
| { | |
| "Sid": "Allow get requests originating from example.com and *.example.com", | |
| "Effect": "Allow", | |
| "Principal": "*", | |
| "Action": "s3:GetObject", | |
| "Resource": "arn:aws:s3:::example.com/*", | |
| "Condition": { | |
| "StringLike": { | |
| "aws:Referer": [ | |
| "http://example.com/*", | |
| "http://*.example.com/*" | |
| ] | |
| } | |
| } | |
| } | |
| ] | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment