scimeatlas

Research map / Large language models / Language, safety and interpretability

Defense Against Prompt Injection Attack by Leveraging Attack Techniques

Yulin Chen, Haoran Li, Zihao Zheng, Dekai Wu, Yangqiu Song, Bryan Hooi

ACL 2025Large language models › Language, safety and interpretabilityapproach: Safety alignment of LLMsopen problems in this approach76 citations (OpenAlex)

National University of Singapore · Hong Kong University of Science and Technology · Harbin Institute of Technology

Read the paperPlace an idea next to itCheck your own paper ↗

12measured effects
6improved
2no clear effect
3hurt
1mixed

AI-extracted. The measured effects below were read by AI from the paper's full text (no summary yet). Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.

Measured effects reported in the paper

What was changedWhereMeasuredEffect
use Fakecom-with-template defense instead of no defenseLlama3-8b-Instruct · Direct injection, Combined attackASR (%): 76.92 -> 1.44Improved
use Fakecom-with-template defense instead of SandwichLlama3-8b-Instruct · Indirect injection, Combined attackASR (%): 21.25 -> 0.05Improved
use Escape defense (escape characters) vs Ignore defense (ablation)Qwen2-7b-Instruct · Direct injection, Fakecom attackASR (%): 5.28 -> 70.19 (Ignore vs Escape)Hurt
apply defense to closed-source GPT-4oOurs-Ignore · Direct injection, Combined attackASR (%): 100.00 -> 0.0Improved
apply defense to GPT-3.5-Turbo vs GPT-4oOurs-Ignore / Ours-Fakecom · Direct injectionASR (%): Ignore Combined 4.32 (3.5) vs 0.0 (4o)Mixed
apply defenses against gradient-based GCG attackOurs-Fakecom-t · Direct injection, GCGASR (%): 87.01 -> 9.61Improved
use defense vs fine-tuning StruQ on unseen attack (Fakecom)Ours-Ignore · Indirect injection, FakecomASR (%): StruQ 35.55/35.70 vs 0.10Improved
delete original input instruction from prompt (ablation)Ours defenses · Direct injection, Llama3ASR (%): Ours-Ignore Combined 27.40 -> 18.75No clear effect
delete original input instruction from prompt (ablation)Sandwich · Direct injection, Llama3ASR (%): Combined 49.51 -> 61.53Hurt
remove retrieved data content (ablation)Llama3 QA · QAaccuracy (%): 78.05 -> 41.15Hurt
add Ours-Fakecom defenseLlama3-8b-Instruct · QA utility (no attack)accuracy (%): 78.05 -> 80.75Improved
add defense to Qwen2Ours-Fakecom-t · QA utility (no attack)accuracy (%): 76.60 -> 77.40No clear effect

Earlier methods this paper compares with

Named baselines from earlier accepted papers in this paper's results tables: better than 1 of 1 on most shared results.

Matched by method name in results tables read by AI. Authors' own tables tend to favour the newer method, and a comparison can be missed when a method is renamed.

Open problems in safety alignment of LLMs

How can LLM safety be shown to hold across languages, multi-turn use and models beyond small open ones?

All 5 open problems and what was already tried →

Closest papers by meaning

Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.

Open scime draft

Get the next scime Dispatch and a monthly field update

Free. We send a confirmation link first; every email has a one-click unsubscribe. Privacy