DOP-C02 Resilient Cloud Solutions Practice Question
Exhibit
Refer to the exhibit.
```
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "AllowVPCAccess",
"Effect": "Allow",
"Action": [
"ec2:CreateNetworkInterface",
"ec2:DescribeNetworkInterfaces",
"ec2:DeleteNetworkInterface"
],
"Resource": "*"
},
{
"Sid": "AllowWriteToTable",
"Effect": "Allow",
"Action": [
"dynamodb:PutItem",
"dynamodb:UpdateItem"
],
"Resource": "arn:aws:dynamodb:us-east-1:123456789012:table/MyTable"
}
]
}
```Refer to the exhibit. A Lambda function uses the IAM role with the above policy. The function is configured to access a DynamoDB table MyTable and an RDS instance in a VPC. When invoked, the function fails with an error indicating it cannot describe VPC subnets. What is the MOST likely cause?
⚠ Common exam trap
DOP-C02 often tests the misconception that VPC-attached Lambda only needs ENI creation permissions, when in fact DescribeSubnets, DescribeSecurityGroups, and DescribeNetworkInterfaces are also mandatory and their absence produces the exact error described.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
The Lambda function is missing permissions to describe VPC subnets and security groups.
The Lambda execution role policy shown in the exhibit grants DynamoDB and RDS-related actions but omits the ec2:DescribeSubnets, ec2:DescribeSecurityGroups, and ec2:DescribeNetworkInterfaces permissions required when a function is attached to a VPC. When Lambda is configured with VPC access, the service must call these EC2 APIs to validate and place the ENIs, so the invocation fails with a subnet-description error. Adding the missing ec2:Describe* permissions to the role resolves the failure.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
The Lambda function is missing permissions to describe VPC subnets and security groups.
Why this is correct
The Lambda execution role must explicitly allow ec2:DescribeSubnets and ec2:DescribeSecurityGroups so that the Lambda service can inspect your VPC and locate the subnets and security groups you specified. These read-only actions are prerequisites for Lambda to create an elastic network interface (ENI); without them, the invocation fails during the VPC provisioning step, even if the role allows creating ENIs. This is why the error specifically mentions missing subnet or security group describe permissions.
- ✗
The Lambda function does not have permission to write to DynamoDB.
Why it's wrong here
This is incorrect because the IAM policy shown in the exhibit explicitly grants PutItem and UpdateItem on the MyTable resource. If DynamoDB write permissions were missing, the failure would occur as a DynamoDB AccessDeniedException when the function attempts to write, not as a VPC subnet/security group error. Since the function fails before reaching the DynamoDB call, the cause lies in the networking permissions, not DynamoDB access.
- ✗
The Lambda function cannot create network interfaces in the VPC.
Why it's wrong here
The policy does grant ec2:CreateNetworkInterface, so Lambda can indeed create the network interface once it has all necessary information. The problem is that the Lambda service must first describe the VPC subnets and security groups to choose which ones to use—actions that are not allowed in the policy. Missing ec2:DescribeSubnets and ec2:DescribeSecurityGroups blocks the ENI creation process, even though the create permission itself is present.
- ✗
The DynamoDB table's resource policy denies access from Lambda.
Why it's wrong here
A DynamoDB resource policy would only deny access if it explicitly listed the Lambda function's principal, and such a denial would produce a DynamoDB-specific error. Here, the error message is about VPC subnets, indicating that Lambda's network interface provisioning failed before the function's code could execute. Since the function never reaches the DynamoDB operation, a table-level resource policy denial cannot be the root cause of this failure.
Visual reference
Quick reference
Cloud Service Model Comparison
| Model | You Manage | Provider Manages | Examples |
|---|---|---|---|
| IaaS | OS, runtime, apps, data | Hardware, hypervisor, networking | EC2, Azure VMs, GCP Compute Engine |
| PaaS | Apps and data | OS, runtime, middleware, hardware | Elastic Beanstalk, Azure App Service |
| SaaS | Data and settings only | Everything else | Microsoft 365, Salesforce, Workday |
| FaaS / Serverless | Function code only | Infra, scaling, runtime | Lambda, Azure Functions, Cloud Run |
| CaaS | Containers and apps | Kubernetes, OS, hardware | EKS, AKS, GKE |
About these practice questions
One of 1,298 original DOP-C02 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →
JA
Written and reviewed by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
Last reviewed September 2026 · checked against the official Amazon Web Services exam blueprint
This DOP-C02 practice question is part of Courseiva's free Amazon Web Services certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the DOP-C02 exam.