Cloud Engineer interview question · Most asked

An application on AWS suddenly gets AccessDenied when reading from S3. How do you troubleshoot it?

Scenario Asked in Cloud Engineer · DevOps Engineer interviews

Members can save this page, take notes and track progress. See membership · Sign in

Summary

Find out exactly which principal made the call and which policy denied it: the error message and CloudTrail show the role and the action. Then check every layer that can deny: the role's IAM policy, the bucket policy, permission boundaries and organisation SCPs, KMS key policies for encrypted objects, VPC endpoint policies and object ownership.

Longer Answer

  1. Who and what: aws sts get-caller-identity from the workload; CloudTrail event with errorCode AccessDenied (newer messages name the policy type that denied it).
  2. Identity policy: does the role allow s3:GetObject on arn:aws:s3:::bucket/* (objects, not just the bucket ARN)?
  3. Bucket policy: explicit denies (for example requiring a VPC endpoint or TLS).
  4. KMS: SSE-KMS objects need kms:Decrypt on the key, and the key policy must allow the role.
  5. Guardrails: SCPs, permission boundaries, VPC endpoint policies.
  6. Ownership: objects uploaded by another account with ACLs disabled or enforced.
  7. What changed: a recent policy deploy, key rotation to a new key, role change, or credentials now coming from a different role (IRSA misconfiguration). The IAM policy simulator and IAM Access Analyzer help confirm the fix.

Key Points

  • Identify the principal and action from CloudTrail.
  • Check identity, bucket, KMS and endpoint policies.
  • SCPs and boundaries can deny silently.
  • Object vs bucket ARNs.
  • Look at what changed.

Explanation

What interviewers look for

Knowing all the layers that can deny an S3 request and a systematic way through them.

More Cloud Engineer questions

← All Cloud Engineer questions

Last reviewed · By the ByteCamel team · How we write content

Was this page helpful?

Report a mistake