A user can be provided access to specific folder in Amazon AWS S3 bucket instead of granting full access. Here are the steps to generate IAM policy and limit access to S3 bucket folder.
Step 1:Copy ARN
Step 2: Generate Policy and copy the JSON
- Open website https://awspolicygen.s3.amazonaws.com/policygen.html. Generate Policy and copy the JSON
Step 3: Create IAM Policy
- Open IAM > Policies > Create Policy
- Choose JSON and paste the policy created in Step 2
- Specify Name to complete creation of IAM policy
Step 4: Create an IAM user and attach IAM policy
- Create an IAM user and check ‘Access Type’ and ‘AWS Management Console access’
- Assign the policy that was recently created and you are done!
Once the IAM user logs in to AWS Console, you need to provide the exact path to S3 bucket folder location in order to access.