AWS Certified Solutions Architect – Professional (SAP-C02) — Question 127

An external audit of a company’s serverless application reveals IAM policies that grant too many permissions. These policies are attached to the company's AWS Lambda execution roles. Hundreds of the company's Lambda functions have broad access permissions such as full access to Amazon S3 buckets and Amazon DynamoDB tables. The company wants each function to have only the minimum permissions that the function needs to complete its task.

A solutions architect must determine which permissions each Lambda function needs.

What should the solutions architect do to meet this requirement with the LEAST amount of effort?

Answer options

Correct answer: B

Explanation

Option B is the most efficient way to identify the necessary permissions, as AWS Identity and Access Management Access Analyzer can automatically generate policies based on CloudTrail logs, saving significant effort. Option A requires manual profiling and policy creation, which is more labor-intensive. Option C involves scripting and manual report generation, which adds complexity. Option D, while thorough, requires additional steps of exporting logs and processing them with Amazon EMR, making it less efficient than option B.