Last active
February 23, 2019 20:16
-
-
Save sergejmueller/6b7e93069e286c9d04847a5d549e6391 to your computer and use it in GitHub Desktop.
AWS S3 Bucket Policy to protect a bucket web access by IP (Range)
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", | |
"Id": "Policy1550216993456", | |
"Statement": [ | |
{ | |
"Sid": "Stmt1550216977234", | |
"Effect": "Allow", | |
"Principal": "*", | |
"Action": "s3:GetObject", | |
"Resource": "arn:aws:s3:::my-site/*", | |
"Condition": { | |
"IpAddress": { | |
"aws:SourceIp": "80.242.123.0/24" | |
} | |
} | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment