Skip to content

Instantly share code, notes, and snippets.

@lusis
Created January 5, 2011 10:32
Show Gist options
  • Star 5 You must be signed in to star a gist
  • Fork 5 You must be signed in to fork a gist
  • Save lusis/766146 to your computer and use it in GitHub Desktop.
Save lusis/766146 to your computer and use it in GitHub Desktop.
A sample AWS IAM json policy file with read-only access to certain S3 buckets
{
"Statement":[{
"Effect":"Allow",
"Action":["s3:ListBucket","s3:GetObject","s3:GetObjectVersion"],
"Resource":["arn:aws:s3:::my_bucket/*","arn:aws:s3:::my_bucket"]
}
],
"Statement":[{
"Effect":"Allow",
"Action":["s3:ListBucket","s3:GetObject","s3:GetObjectVersion"],
"Resource":["arn:aws:s3:::my_other_bucket/*","arn:aws:s3:::my_other_bucket"]
}
],
"Statement":[{
"Effect":"Allow",
"Action":["s3:ListAllMyBuckets"],
"Resource":"*",
"Condition": {}
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment