A SysOps Administrator is configuring an AWS Lambda function to stop underutilized EC2 instances. The administrator has already created the required IAM execution role for Lambda with the correct permissions. However, when the administrator attempts to update the Lambda function configuration to use this execution role, the AWS Management Console displays an Access Denied error.
Which permission must be granted to the SysOps Administrator's IAM user policy to resolve this error?
- iam:PassRole on the Lambda execution role resourceAnswer
- Bsts:AssumeRole on the Lambda execution role resource
- Csts:AssumeRole on the Lambda service principal
- Diam:GetRole on the Lambda execution role resource
Answer
iam:PassRole on the Lambda execution role resource
The correct answer is the option specifying 'iam:PassRole on the Lambda execution role resource'. When configuring an AWS service to assume an IAM role, the user performing the configuration action must have the iam:PassRole permission. This security control ensures that users cannot escalate their privileges by passing a highly privileged role to a service that they could then interact with or trigger.
Step-by-Step Solution
Key Concept
Delegating permissions to AWS services using the iam:PassRole policy permission
Estimated Time:1m 0s