AIF-C01 Applications of Foundation Models Practice Question
A company uses Amazon Bedrock to generate code. They want to ensure the code follows security best practices and does not contain vulnerabilities. Which approach is most effective?
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
✓
Use Amazon CodeGuru Security to review generated code.
Amazon CodeGuru Security reviews code for security vulnerabilities and provides recommendations. Using a model trained on secure code may not be sufficient; WAF is for web traffic; training a custom model requires significant effort and may not catch all issues.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
Implement a post-processing step using AWS WAF.
Why it's wrong here
AWS WAF protects web applications from common exploits, not a code review tool.
- ✓
Use Amazon CodeGuru Security to review generated code.
Why this is correct
CodeGuru Security automatically scans code for vulnerabilities and provides actionable recommendations.
- ✗
Train a custom model on the company’s secure code.
Why it's wrong here
Custom training requires large datasets and may not generalize to all security issues.
- ✗
Use a foundation model trained only on secure code.
Why it's wrong here
Even if trained on secure code, the model may still generate insecure patterns without explicit safeguards.
Go deeper
Related to this question
About these practice questions
Courseiva writes every AIF-C01 question from scratch — 619 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This AIF-C01 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 AIF-C01 exam.