An application running on Amazon EC2 pulls messages from Amazon SQS. After recent IAM changes, the instances can no longer receive messages. Which actions should you take to troubleshoot while maintaining least privilege? (Choose two.)
Choose an answer
Tap an option to check your answer.
Correct answer: Confirm that the SQS queue’s resource policy does not explicitly deny the instance role., Verify that the instance role’s inline or attached policies allow the necessary SQS permissions on the target queue..
Why this is the answer
The two correct actions focus on verifying permissions at different levels, adhering to least privilege. First, you should verify that the instance role's attached or inline policies grant the necessary SQS permissions (e.g., sqs:ReceiveMessage) for the target queue. This ensures the role itself has the required access. Second, you must confirm that the SQS queue's resource policy does not explicitly deny the instance role. An explicit deny in a resource policy overrides any allow permissions, making it a critical check. Attaching an MFA device is irrelevant for an EC2 instance role. Verifying the access key is unnecessary; EC2 instances use temporary credentials via IAM roles, not long-lived access keys. Attaching AmazonSQSFullAccess violates the principle of least privilege by granting more permissions than required.
Pass your exam — without the endless answer hunt
Get every verified question and explanation for this exam in one place, and save hours of prep. 1,000+ certifications · 20+ languages · free to start.
Pass your exam faster → No card needed