CAPTURE: Context-Aware Prompt Injection Testing and Robustness Enhancement

Fuente: arXiv
Enregistré dans:
Détails bibliographiques
Auteurs principaux: Kholkar, Gauri, Ahuja, Ratinder
Format: Preprint
Publié: 2025
Sujets:
Accès en ligne:
Tags: Ajouter un tag
Pas de tags, Soyez le premier à ajouter un tag!
_version_ 1866913897702752256
author Kholkar, Gauri
Ahuja, Ratinder
author_facet Kholkar, Gauri
Ahuja, Ratinder
contents Prompt injection remains a major security risk for large language models. However, the efficacy of existing guardrail models in context-aware settings remains underexplored, as they often rely on static attack benchmarks. Additionally, they have over-defense tendencies. We introduce CAPTURE, a novel context-aware benchmark assessing both attack detection and over-defense tendencies with minimal in-domain examples. Our experiments reveal that current prompt injection guardrail models suffer from high false negatives in adversarial cases and excessive false positives in benign scenarios, highlighting critical limitations. To demonstrate our framework's utility, we train CaptureGuard on our generated data. This new model drastically reduces both false negative and false positive rates on our context-aware datasets while also generalizing effectively to external benchmarks, establishing a path toward more robust and practical prompt injection defenses.
format Preprint
id arxiv_https___arxiv_org_abs_2505_12368
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle CAPTURE: Context-Aware Prompt Injection Testing and Robustness Enhancement
Kholkar, Gauri
Ahuja, Ratinder
Computation and Language
Artificial Intelligence
Prompt injection remains a major security risk for large language models. However, the efficacy of existing guardrail models in context-aware settings remains underexplored, as they often rely on static attack benchmarks. Additionally, they have over-defense tendencies. We introduce CAPTURE, a novel context-aware benchmark assessing both attack detection and over-defense tendencies with minimal in-domain examples. Our experiments reveal that current prompt injection guardrail models suffer from high false negatives in adversarial cases and excessive false positives in benign scenarios, highlighting critical limitations. To demonstrate our framework's utility, we train CaptureGuard on our generated data. This new model drastically reduces both false negative and false positive rates on our context-aware datasets while also generalizing effectively to external benchmarks, establishing a path toward more robust and practical prompt injection defenses.
title CAPTURE: Context-Aware Prompt Injection Testing and Robustness Enhancement
topic Computation and Language
Artificial Intelligence
url https://arxiv.org/abs/2505.12368