Hoping you can help!
I created a new AWS test account.
I created a new bucket in S3 not selecting any of the recommended public or private settings. Says, "Objects can be public".
I then created an IAM user for programmatic access, downloaded access and secret keys.
I then created the following policy to grant access to said bucket as per this AWS article: https://aws.amazon.com/blogs/security/writing-iam-policies-how-to-grant-access-to-an-amazon-s3-bucket/
Here is the policy (bucketName redacted):
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"s3:ListBucket"
],
"Resource": [
"arn:aws:s3:::test-bucket"
]
},
{
"Effect": "Allow",
"Action": [
"s3:PutObject",
"s3:GetObject",
"s3:DeleteObject"
],
"Resource": [
"arn:aws:s3:::test-bucket/*"
]
}
]
}
I then attached this policy to this user.
When using the SDK or Policy Simulator, confirming that I am using the proper keys, I keep getting Access Denied errors.
The policy simulator says, "Implicitly denied (no matching statements).