- A
AWS::Lambda::Permission
Correct. This resource explicitly grants the S3 service principal permission to invoke the Lambda function.
- B
AWS::S3::BucketPolicy
Why wrong: A bucket policy controls access to the S3 bucket itself, not the permissions for S3 to invoke Lambda.
- C
AWS::Lambda::EventSourceMapping
Why wrong: Event source mappings are used for streaming or poll-based sources like SQS, DynamoDB Streams, or Kinesis, not for S3 event notifications.
- D
AWS::IAM::Role
Why wrong: An IAM role defines what actions the Lambda function can perform, not who can invoke it.
DVA-C02 Deployment Practice Question
This DVA-C02 practice question tests your understanding of deployment. Match the stated requirement to the specific cloud service, access model, or configuration option — many options are valid in isolation but not for this scenario. A key principle to apply: aWS::Lambda::Permission grants other AWS services permission to invoke a Lambda function.. Once you have made your selection, read the full explanation to reinforce the concept and understand why each distractor is designed to mislead on exam day.
A developer is deploying a serverless application using AWS SAM. The application includes an AWS Lambda function that is triggered by an S3 bucket event when an object is created. The developer wants to ensure that the Lambda function has the correct permissions to be invoked by S3. Which resource should the developer define in the SAM template?
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
AWS::Lambda::Permission
AWS::Lambda::Permission is the correct resource because it explicitly grants the S3 service principal permission to invoke the Lambda function when an object is created. In AWS SAM, this resource is automatically generated when you define an S3 event source on a Lambda function, but if you need to declare it manually or override permissions, you use AWS::Lambda::Permission with a SourceArn pointing to the S3 bucket and a SourceAccount to prevent confused deputy attacks.
Key principle: AWS::Lambda::Permission grants other AWS services permission to invoke a Lambda function.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
AWS::Lambda::Permission
Why this is correct
Correct. This resource explicitly grants the S3 service principal permission to invoke the Lambda function.
Related concept
AWS::Lambda::Permission grants other AWS services permission to invoke a Lambda function.
- ✗
AWS::S3::BucketPolicy
Why it's wrong here
A bucket policy controls access to the S3 bucket itself, not the permissions for S3 to invoke Lambda.
- ✗
AWS::Lambda::EventSourceMapping
Why it's wrong here
Event source mappings are used for streaming or poll-based sources like SQS, DynamoDB Streams, or Kinesis, not for S3 event notifications.
- ✗
AWS::IAM::Role
Why it's wrong here
An IAM role defines what actions the Lambda function can perform, not who can invoke it.
Common exam traps
Common exam trap: answer the scenario, not the keyword
The trap here is that candidates confuse the Lambda execution role (IAM::Role) with the invocation permission (Lambda::Permission), or mistakenly think S3 uses a bucket policy or event source mapping to trigger Lambda, when in fact S3 uses a push-based notification that requires a resource-based policy on the Lambda function.
Detailed technical explanation
How to think about this question
Under the hood, when S3 sends an event notification to Lambda, it uses a resource-based policy (the Lambda permission) that includes a Condition block with SourceArn and SourceAccount to prevent the confused deputy problem. This is critical because without these conditions, a malicious S3 bucket in another account could trick your Lambda into processing its events. In SAM, the AWS::Lambda::Permission is often auto-generated when you use the S3 event source in the template, but you can also define it explicitly to add conditions or cross-account access.
KKey Concepts to Remember
- AWS::Lambda::Permission grants other AWS services permission to invoke a Lambda function.
- It creates a resource-based policy directly on the Lambda function.
- The `Principal` property specifies the invoking service (e.g., `s3.amazonaws.com`).
- The `SourceArn` property restricts the permission to a specific resource, like an S3 bucket.
TExam Day Tips
- Watch for words such as best, first, most likely and least administrative effort.
- Review why wrong options are wrong, not only why the correct option is correct.
Key takeaway
AWS::Lambda::Permission grants other AWS services permission to invoke a Lambda function.
Real-world example
How this comes up in practice
A media company stores terabytes of video archives that are accessed once a year for audit purposes. Moving these objects to a cold storage tier (Azure Archive, S3 Glacier, or Google Nearline) costs a fraction of hot storage. Questions like this test whether you understand storage tiers, access frequency tradeoffs, and retrieval latency requirements.
What to study next
Got this wrong? Here's your next step.
Review aWS::Lambda::Permission grants other AWS services permission to invoke a Lambda function., then practise related DVA-C02 questions on the same topic to reinforce the concept.
- →
Deployment — study guide chapter
Learn the concepts, then practise the questions
- →
Deployment practice questions
Targeted practice on this topic area only
- →
All DVA-C02 questions
1,616 questions across all exam domains
- →
AWS Certified Developer Associate DVA-C02 study guide
Full concept coverage aligned to exam objectives
- →
DVA-C02 practice test guide
How to use practice tests most effectively before exam day
Related practice questions
Related DVA-C02 practice-question pages
Use these pages to review the topic behind this question. This is how one missed question becomes focused revision.
Development with AWS Services practice questions
Practise DVA-C02 questions linked to Development with AWS Services.
Security practice questions
Practise DVA-C02 questions linked to Security.
Deployment practice questions
Practise DVA-C02 questions linked to Deployment.
Troubleshooting and Optimization practice questions
Practise DVA-C02 questions linked to Troubleshooting and Optimization.
DVA-C02 fundamentals practice questions
Practise DVA-C02 questions linked to DVA-C02 fundamentals.
DVA-C02 scenario practice questions
Practise DVA-C02 questions linked to DVA-C02 scenario.
DVA-C02 troubleshooting practice questions
Practise DVA-C02 questions linked to DVA-C02 troubleshooting.
Practice this exam
Start a free DVA-C02 practice session
Short sessions build daily habit. Longer sessions build exam-day stamina. Try a timed session to simulate real conditions.
FAQ
Questions learners often ask
What does this DVA-C02 question test?
Deployment — This question tests Deployment — AWS::Lambda::Permission grants other AWS services permission to invoke a Lambda function..
What is the correct answer to this question?
The correct answer is: AWS::Lambda::Permission — AWS::Lambda::Permission is the correct resource because it explicitly grants the S3 service principal permission to invoke the Lambda function when an object is created. In AWS SAM, this resource is automatically generated when you define an S3 event source on a Lambda function, but if you need to declare it manually or override permissions, you use AWS::Lambda::Permission with a SourceArn pointing to the S3 bucket and a SourceAccount to prevent confused deputy attacks.
What should I do if I get this DVA-C02 question wrong?
Review aWS::Lambda::Permission grants other AWS services permission to invoke a Lambda function., then practise related DVA-C02 questions on the same topic to reinforce the concept.
What is the key concept behind this question?
AWS::Lambda::Permission grants other AWS services permission to invoke a Lambda function.
About these practice questions
Courseiva creates original exam-style practice questions with explanations and wrong-answer analysis. It does not publish real exam questions, exam dumps, or protected exam content. Learn why practice questions differ from exam dumps →
Last reviewed: Jun 11, 2026
This DVA-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 DVA-C02 exam.
Question Discussion
Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.
Sign in to join the discussion.