EvoSafeHarness: Evolving Model- and Domain-Specific Harnesses for Securing Agents

Nanxi Li, Yingzi Ma, Yulong Cao, Edward Suh, Bo Li, Dawn Song, Chaowei Xiao

arXiv:2609.05903 · 2026-09-11 공개 · arXiv · PDF

llm-agents benchmark-evaluation prompt-injection domain-specific adversarial-review safety-harnesses evolutionary-optimization utility-safety-tradeoff

Abstract

Large Language Model (LLM) agents are turning language into real-world effects, making safety necessary against both indirect prompt injections and direct harmful requests. System-level safety harnesses add an enforcement layer beyond model-level defenses, but existing harnesses are usually designed once by experts and applied across heterogeneous models and domains. Effective protection is deployment-dependent: models differ in how much enforcement they need before utility declines, while domains differ in the effects, state, and action sequences that must be governed. A harness that is strict enough for one model may over-block another, and a policy that transfers across domains may miss application-specific safety relations. We present EvoSafeHarness, a safety-specific optimization framework that synthesizes a deployable harness for a frozen model in a target domain. It jointly searches a natural-language policy and executable code logic, guided by model behavior, domain specifications, and fresh-context adversarial review to reject benchmark-specific rules. Across four agent benchmark families, EvoSafeHarness achieves a stronger safety-utility frontier than fixed expert-designed defenses. On DecodingTrust-Agent, it reduces average attack success rate from 45.6% to 10.0% at a 3.3-point utility cost and achieves the best score in 14 of 15 cells. On AgentDojo, it reaches 82.8% utility at 0.0% ASR, twice CaMeL's utility at the same operating point, and transfers unchanged to unseen AgentDyn suites. It also achieves the best score on Agent-SafetyBench for every victim and keeps mean ASR below 20% under adaptive PAIR attacks with a refinement budget of 16. Analysis shows that domain semantics determine which safety relations and trajectory state are needed, while model and runtime behavior determine how and where those relations should be enforced.

한국어 요약

한 줄 요약

EvoSafeHarness는 모델과 도메인에 맞춘 안전성 햬스를 진화적으로 생성하여, 기존 정적 햬스 대비 안전성-유틸리티 균형을 개선한다.

핵심 기여도

핵심 아이디어

기존 안전성 햬스는 전문가에 의해 한 번 설계되어, 다양한 모델과 도메인에 동일하게 적용되지만, 이는 모델 간 안전성 요구 수준과 도메인 간 보호해야 할 효과, 상태, 행동 시퀀스의 차이를 무시한다. EvoSafeHarness는 이 이질성을 해결하기 위해, 목표 도메인과 동결된 모델에 맞춘 햬스를 자동 생성한다. 이는 자연어 정책과 실행 가능한 코드 로직을 동시에 검색하며, 모델 행동, 도메인 명세, 적대적 검토를 통해 햬스 후보를 평가한다. 특히, 기존 햬스가 벤치마크 특성에 과적합되는 문제를 방지하기 위해, 신선한 맥락에서 적대적 검토를 수행한다.

기술적 접근법

주요 결과

의의 및 한계

EvoSafeHarness는 기존 정적 햜스 설계 방식의 한계를 극복하고, 모델과 도메인에 맞춘 햜스를 자동 생성함으로써, **안전성-유틸리티 균형**을 개선한다. 이는 학술적으로는 **자동 햜스 엔지니어링**의 새로운 패러다임을 제시하며, 실용적으로는 **모델과 도메인에 맞춘 보안 정책**을 구현할 수 있는 가능성을 열어준다. 그러나, **적대적 검토**나 **도메인 명세**의 질에 따라 햜스 품질이 달라질 수 있으며, **모델 행동 분석**의 정확성도 결과에 영향을 미친다. 또한, **실행 가능한 코드 로직**의 생성 과정에서 발생할 수 있는 **런타임 오류**나 **안전성 결함**도 주의가 필요하다.

실용적 활용

EvoSafeHarness는 금융, 보안, 의료 등 민감한 도메인에서 사용되는 **LLM 에이전트**에 적용 가능하다. 특히, **개인 정보 보호**, **금융 거래 감시**, **시스템 관리 작업** 등에서 **도메인 특화된 안전성 정책**을 자동 생성하여, **공격 방어**와 **정책 준수**를 동시에 달성할 수 있다.