D7: Prompt Injection & Jailbreak Defense
Claude Certified Developer – Foundations exam practice questions · 11 flashcards
Question
What is prompt injection?
1 / 11
Tip: Space flips the card, ← / → navigate.
Show all 11 Prompt Injection & Jailbreak Defense practice questions and answers
- What is prompt injection?Malicious instructions placed in input or data that try to override the app's intended instructions.
- Direct vs indirect prompt injection?Direct: the user types the attack. Indirect: it's hidden in content the model reads (web pages, files, emails, tool results).
- A summarizer reads a page with hidden 'ignore previous instructions' text. Best mitigation?Treat page content as untrusted, keep it separate from instructions, and use guardrails/hooks so it can't trigger sensitive actions.
- Does raising temperature help against injection?No. Temperature is unrelated.
- Is asking users not to inject in the system prompt a control?No. It isn't enforceable.
- Does a larger, more instruction-following model prevent injection?No. It can even be more susceptible.
- What is a jailbreak?An attempt to make the model break its safety rules or policies.
- How can you screen inputs for attacks?Use a lightweight classifier or a fast model to flag suspicious input before main processing.
- Why is least privilege key against injection?If injected text can't reach sensitive tools, the damage is limited.
- Why require human approval for high-impact actions?Injected instructions can't complete sensitive actions without a person confirming.
- Why monitor and log suspicious inputs?To detect attacks, tune defenses and investigate incidents.