After a reorganization, auditors flag an IAM role allowing s3:Get* on finance buckets to all developers, plus an S3 bucket policy granting internet read. The company must find all externally accessible resources and remove unused permissions without breaking jobs. Which remediation approach should the engineer take to correct unintended permissions?
Select an answer to reveal the explanation.
Short Explanation
You can't fix what you can't see. Analysis flags what's public and unused so you trim precisely.
Full Explanation
The correct remediation works because Access Analyzer gives two complementary signals: external access findings identify resources shared outside the zone of trust such as the internet-readable bucket policy, while unused access findings highlight broad grants like s3:Get* for all developers, allowing scoping of identity and resource policies to only required actions and principals to remove exposure without breaking jobs. The external-findings-only with bucket-policy restriction approach fails because it fixes public exposure but leaves the excessive developer role untouched, violating least-privilege removal of unused permissions. The last-accessed and CloudTrail analysis approach fails because it right-sizes the role to used actions but leaves the internet bucket policy in place, failing to eliminate external access. The fix-only-reported-findings approach fails because correcting only the named role and bucket violates the duty to find all externally accessible resources, since reorganization drift leaves other shares undiscovered without a full scan. For exams, external access and unused access are distinct Analyzer types, so a prompt requiring both demands a solution naming both. As a practical check, simulate scoped policies and review recent CloudTrail S3 calls for dependent jobs, then rerun Analyzer to confirm zero findings.