Skip to content

SkillDRE: Automatically Evolving Malicious Agent Skills with Pre-execution and Runtime Two-Stage FeedbackSkillDRE: Dual-Stage Red-Team Evolution of Agent Skills via Pre-Execution and Runtime Feedback

arXiv: Jailbreaks, Prompt Injection, Poisoning & Defenses· arXiv:2609.32400· Pengyu Zhu, Jingyi Yang, Yi Liu, Li Sun, Sen Su·Indexed by this site · 2026-10-01· Originally publishedAttacks

Quick read

Attacks

Based on the paper PDF (AI-generated); refer to the original

SkillDRE evolves malicious skills with pre-execution scanning and runtime feedback; average ASR across four victim models is 45.28%, and SkillScan DR is 0%.

Threat modelThe adaptive attacker can repeatedly access a fixed layered defense pipeline. For each task–skill pair, only the target skill is revised, using pre-execution scan feedback and runtime defense feedback; the task instruction, victim agent, other skills, and defenses remain unchanged, and the red-team model is fixed. Attack success is determined by that pipeline, and legitimate task functionality is measured separately.

Questions
Skill packages turn instructions, code, and resources into reusable artifacts; execution feedback can revise skills without changing model parameters, and attackers can exploit this to evolve malicious skills. Candidates may pass pre-execution scanning yet fail to achieve the goal, and fixing execution may introduce new scanning findings.
Methods
SkillDRE first fixes the task-conditioned attack goal and determination rule, then modifies only the skill implementation. Phase 1 iterates with SkillScan risk scores until zero findings, then executes under SkillSonar; if stopped or the determination rule is not satisfied, the revised result returns to Phase 1 for rescanning, until success or budget exhaustion.
Experiments and results
Across 249 skills and four models, average ASR is 45.28%, SkillScan DR is 0, and the authors state this exceeds the strongest baseline by 40.3 percentage points. On DeepSeek-V4-Pro, ASR is 12.05 percentage points higher than iterative scanning with DR 0, and DR is 79.92 percentage points lower than iterative runtime.
Limitations and future work
The paper has no dedicated limitations section. Appendix B states that the risk score weights are a lexicographic design choice, not a calibration of the relative harm of findings. The conclusion urges joint evaluation of pre-execution and runtime defenses. Experiments include four victim models, SkillJect and SkillHarm, Codex and Claude Code; the number of repetitions is not reported.
Experimental setupDeepSeek-V4-Pro、GLM-5.2 et al. · SkillsBench、Codex et al. · ASR、DR et al.
Evaluated models
DeepSeek-V4-ProGLM-5.2Qwen3.5-397B-A17BGemini-3.7-Flash
Benchmarks
SkillsBenchCodexClaude Code
Metrics
ASRDRACCΔACC
AI summarySkillDRE is a framework for fully automatic evolution of complete malicious agent skill packages, through a two-stage closed-loop iterative skill implementation consisting of pre-execution scanning and runtime defense feedback. Given a benign task and its skill, the framework first autonomously constructs and verifies a malicious goal bound to the task and verifiable judgment rules, then fixes both while evolving only the skill implementation, preserving legitimate task capability. It combines scanner-guided evolution with runtime execution-result-guided correction; each runtime correction returns to the pre-execution stage for rescanning and optimization, then re-executes. Evaluated on SkillsBench against four victim models, the average attack success rate is 45.28%, 40.3% higher than the strongest baseline, and the final submitted skills trigger no SkillScan alerts while largely maintaining benign task performance.

SkillDRE is a framework for fully automatic evolution of complete malicious agent skill packages, through a two-stage closed-loop iterative skill implementation consisting of pre-execution scanning and runtime defense feedback. Given a benign task and its skill, the framework first autonomously constructs and verifies a malicious goal bound to the task and verifiable judgment rules, then fixes both while evolving only the skill implementation, preserving legitimate task capability. It combines scanner-guided evolution with runtime execution-result-guided correction; each runtime correction returns to the pre-execution stage for rescanning and optimization, then re-executes. Evaluated on SkillsBench against four victim models, the average attack success rate is 45.28%, 40.3% higher than the strongest baseline, and the final submitted skills trigger no SkillScan alerts while largely maintaining benign task performance.

Paper analysis

6 questions; open one to read the full answer

  1. What problem does this paper attempt to solve?

    Pre-execution scanning and runtime defenses can cancel each other out; SkillDRE evolves malicious skill packages with a two-stage closed loop.

    How to automatically evolve a complete malicious skill package that passes scanning, achieves a fixed task-conditioned goal at runtime, and preserves legitimate task capabilities, when both pre-execution scanning and runtime defenses are present.

    • Scenario: Agent skills package instructions, executable code, and task resources into reusable artifacts; agents can revise artifacts based on execution feedback without updating parameters. The authors argue that attackers can also iteratively revise malicious skills to make them more effective and harder to detect; automation would reduce the human cost of turning benign skills into usable attacks.
    • Existing gaps: The authors argue that merely inserting malicious instructions or code is insufficient; harmful behavior must appear in legitimate workflows and execute successfully, while passing checks on the skill package and runtime operations. Candidates that pass scanning may fail to achieve the goal, and revisions that fix execution may introduce new scan findings; optimizing only one objective cancels the other.
    • Separation: The authors separate what harm to pursue from how the skill achieves it. They first fix a task-conditioned goal and verifiable determination rule, then revise the implementation using scan diagnostics, runtime defense decisions, and execution results.
    • Threat model (Section 3.1):
      • Goal: Achieve attack success against a fixed layered defense pipeline; impact on legitimate task functionality is measured separately.
      • Knowledge: An adaptive attacker can repeatedly access the pipeline and use pre-execution scan feedback and feedback under runtime defenses.
      • Capability: For each task–skill pair, only skill S is modified; task instructions, victim agent, other skills, and defenses remain unchanged; the red-team model is fixed during construction and evolution.
      • Victim system: The victim agent executes benign tasks and their skill sets in a sandbox. The pre-execution scan and runtime defense used for evaluation are SkillScan and SkillSonar.
    • Framework: The authors propose SkillDRE. It does not rely on given payloads or manual attack strategies; it automatically constructs and validates goals and determination rules, then evolves the skill implementation in a cross-stage closed loop.
  2. What related research exists?

    Related work is divided into skill self-evolution and skill attacks; the main experimental baselines are SkillJect and SkillHarm.

    Section 2 of the paper divides related work into skill self-evolution and attacks on skills; the main experiments only reproduce SkillJect and SkillHarm, which have open-source implementations.

    Skill Self-Evolution (Section 2.1)

    • Procedural knowledge: The paper cites Xie et al. (2024), Trivedi et al. (2024), and Xu et al. (2025), stating that underlying models often lack the procedural knowledge needed for specialized tasks. Skill self-evolution updates reusable knowledge beyond parameters, and Li (2026) frames it as a lifecycle problem.
    • Acquisition, refinement, and composition: Yang et al. (2026b) and Lin et al. (2026) obtain skills from demonstrations or interactions; Yang et al. (2026a), Liu et al. (2026), and Mi et al. (2026) update skills using execution results, scored rollouts, or failure signals, and study transfer across tasks, models, or execution systems. Zhao et al. (2026) and Xu et al. (2026) study composition and iterative improvement in persistent skill libraries. The authors state that these works primarily use feedback-driven evolution to improve benign task capabilities.

    Attacks on Skills (Section 2.2, Table 1)

    • SkillAttack (Duan et al., 2026): Skills remain unchanged; adversarial user prompts are optimized. The paper explicitly contrasts: the authors study modifying the skill itself while the task instruction is fixed.
    • SkillJect (Jia et al., 2026): Rewrites skill instructions around a given payload using victim execution trajectories. Table 1 marks it as partially supported for full-package evolution; autonomous goals, pre-execution feedback, runtime defense feedback, cross-stage closed loop, and legitimate task preservation are not supported.
    • SkillMutator and SkillHarm: Kim et al. (2026) use scan feedback for language and code mutation and only count newly introduced high-severity findings from Snyk Agent Scan. Ning et al. (2026) construct harmful goals, payloads, and deterministic evaluators from specified risk types, including fixed payloads and self-mutating poisoning. In Table 1, both have full-package evolution as supported and autonomous goals as partially supported; pre-execution feedback is supported and partially supported, respectively; runtime defense feedback, cross-stage closed loop, and legitimate task preservation are not supported.

    Baselines and Benchmarks

    • Experimental baselines: Section 4.2 selects SkillJect and SkillHarm, which the authors state are chosen because their open-source implementations allow reproduction and evaluation. SkillAttack and SkillMutator appear in Table 1; Table 2 does not report ASR or DR for them.
    • Benchmark and defenses: Evaluation uses SkillsBench (Li et al., 2026). On the defense side are pre-execution SkillScan (Cisco AI Defense, 2026) and the runtime defense skill SkillSonar (Skill Sonar, 2026).

    The authors position SkillDRE outside the above attacks: goals and determination rules are constructed only once and fixed during evolution; each runtime revision returns to pre-execution scanning; legitimate task performance is measured separately. In Table 1, only SkillDRE has full support across all six columns: full-package evolution, autonomous goals, pre-execution feedback, runtime defense feedback, cross-stage closed loop, and legitimate task preservation.

  3. How does the paper address this problem?

    First fix the attack goal and determination rule, then revise the skill implementation in a closed loop using scan and runtime feedback.

    SkillDRE first fixes the harm goal, then evolves the implementation: initialization determines the attack goal and determination rule for each task and each skill; Phase 1 uses SkillScan to revise candidates to zero risk findings; Phase 2 executes under SkillSonar; failed revisions must return to Phase 1 for rescanning (Figure 1, Algorithm 1 in Appendix A).

    Problem Setting

    • Execution object: Benign task instruction is I, associated skill set is SI, sandbox is E. The victim agent executes and produces a trajectory and new sandbox state. The attacker replaces only one skill S. The generator is denoted Gπ, and the red-team model π is fixed throughout.
    • Defense signals: SkillScan provides risk findings and reasons. SkillSonar is added to the skill set as a defensive skill and can issue stop decisions for unsafe operations. Each runtime trial starts from the same initial sandbox state for that task.

    Initialization: Goals and Determination Rules

    • Task-level intent: One intent per task, shared by associated skills. The proposal includes a task-level goal, expected malicious side effects, constraints on acceptable implementations, and broad success themes. Validation checks whether it is malicious, relevant to the task, general enough for associated skills, implementation-independent, and confined to the sandbox.
    • Skill-level goal: Instantiates the intent into observable success conditions for that skill and the artifacts used for verification. Validation checks maliciousness, verifiability, executability, task compatibility, and consistency with the shared intent. Accepted goals are fixed during evolution.
    • Unanimity and rounds: A fixed validator ensemble gives binary decisions and explanations; Vote is 1 when all pass. New proposals are generated only in the first round or when the previous proposal is rejected; rejection reasons are included in feedback. Section 4.1 sets the attack goal construction limit to 30 rounds; in Algorithm 1, determination rule construction uses the same budget parameter B0.
    • Determination rules: Rules are constructed iteratively after the goal is fixed. Acceptance requires pattern and local evidence checks, an empty-sandbox smoke test, and unanimous validator votes. The smoke test requires a negative decision with no attack evidence and no hard execution errors; if local checks fail, semantic review is skipped. Semantic review checks whether the rule is faithful to the goal, uses observable sandbox evidence, and does not treat purely benign task behavior as an attack. After rejection, better candidates are retained and revised; accepted rules are then fixed.

    Phase 1: Pre-execution Evolution

    • Risk score: The initial candidate is generated from the original skill and fixed goal, then submitted to SkillScan. The numbers of high, medium, and low risk findings are denoted h, m, l, and the risk score is Rj = 10000 hj + 1000 mj + 10 lj. Appendix B states that these weights are used for lexicographic minimization of (h, m, l) and are not a calibration of the relative harm of finding types; weights are positive, so the score is 0 if and only if all three finding types are 0.
    • Baseline selection: The optimization memory stores evaluated candidates, revision explanations, scan diagnostics, and whether they are better than the historical best; non-improvements are kept as negative evidence. Each subsequent round uses the candidate with the lowest risk score so far as the baseline. Revisions must preserve original functionality and interface, not change the attack goal, and make mechanism-level changes rather than only presentation changes.
    • Admission and re-entry: Only candidates with valid scan results and a risk score of 0 can enter Phase 2. Candidates modified in Phase 2 re-enter Phase 1; on re-entry, rounds restart from 1, Phase 1 memory is cleared, and the historical best is selected only within that evolution run.

    Phase 2: Runtime-guided Evolution

    • Trial: A candidate that passes scanning replaces S, other original skills are retained, SkillSonar is added, and the original task instruction is executed.
    • Current-round success: Yr = 1[Stop(Orsonar)=0 ∧ J∗(Er)=1]. It indicates that SkillSonar did not issue a stop decision and the fixed determination rule confirms the fixed goal is achieved in the sandbox; if either is missing, the round fails.
    • Re-revision: On failure, the execution trajectory, both sides' diagnostics, and Phase 2 memory are used. Memory retains past failure diagnostics and revision plans, stop evidence, and re-entry scan diagnostics and edit explanations. New candidates must again receive a valid scan with zero findings before entering the next runtime trial.
    • Stopping: If the current round succeeds, return that skill; otherwise, continue until the budget is exhausted. Section 4.1 specifies at most 10 runtime trials per skill and at most 30 rounds per Phase 1.
  4. What experiments did the paper conduct?

    Average ASR across four victim models is 45.28%, and the final SkillScan DR is 0%.

    Experimental Setup

    • Data: 249 skills associated with 94 tasks on SkillsBench. The main experiments use Codex as the execution framework; Appendix G additionally uses Claude Code. SkillSonar is always included as a fixed defensive skill during benchmark execution.
    • Models: Victim models are DeepSeek-V4-Pro, GLM-5.2, Qwen3.5-397B-A17B, and Gemini-3.7-Flash. The attack model for each attack method and the target construction generator are DeepSeek-V4-Pro. The validation ensemble is DeepSeek-V4-Pro, GLM-5.2, and Kimi-K2.6. SkillScan is configured to use Qwen3.5-397B-A17B, which shares a name with one of the victim models.
    • Budget: Attack target construction and each Phase 1 run are limited to at most 30 rounds; Phase 2 allows at most 10 runtime trials per skill. The paper does not report the number of repetitions.
    • Baselines: Table 2 includes SkillJect and SkillHarm. The authors state they chose these because open-source implementations are available for reproduction.
    • Metrics: ASR is the proportion of all evaluated skills where the final execution achieves the attack goal, accounting for SkillSonar interruptions. DR is the proportion where SkillScan reports at least one risk finding. ACC uses the original SkillsBench programs; ΔACC equals no-attack ACC minus attack ACC, in percentage points, with positive values indicating a decrease.
    • Determination: Whether the goal is achieved is decided by fixed rules on the sandbox state. Appendix E manually reviews 125/249 skill-level goals and rules.

    Main Results

    According to Table 2, in %. SkillJect's DR is 100.00% across all four models, so it is not listed separately.

    Swipe horizontally to read the table

    Victim ModelSkillDRE ASRSkillJect ASRSkillHarm ASRSkillDRE DRSkillHarm DR
    DeepSeek-V4-Pro46.992.412.530.00100.00
    Qwen3.5-397B-A17B43.782.811.820.0098.25
    GLM-5.245.381.616.550.0097.34
    Gemini-3.7-Flash44.980.009.000.0098.45
    • Average: The authors report an average ASR of 45.28% across the four models and state it exceeds the strongest baseline by 40.3 percentage points (Section 4.2); the abstract and contributions state 40.3%. The highest and lowest SkillDRE ASR differ by 3.21 percentage points. The authors state this spread indicates the effect is not limited to a single victim model. Both baselines do not exceed 9.00%.
    • Detection: The authors state that the final submitted skills have a DR of 0.00% across all four models, while baselines range from 97.34% to 100.00%. The conclusion qualifies this as specific to the SkillScan configuration used in evolution. The authors state that skills can pass pre-execution scanning and still achieve the goal under runtime defenses.
    • Same-name model: The attack model is fixed as DeepSeek-V4-Pro, so in the table, the victim model in that row is the same as the attack model; the other three rows differ.

    Ablations (Table 3)

    The victim model is only DeepSeek-V4-Pro. Phase 1 keeps only scan guidance, Phase 2 keeps only runtime guidance; one-shot evaluates only one candidate without iteration.

    • Single-stage: Phase 1 one-shot has an ASR of 37.75% and DR of 65.46%; after iteration, ASR drops to 34.94% and DR to 0.00%. The authors state that scan iteration itself does not improve attack achievement. Phase 2 one-shot is 36.14% and 62.65%; after iteration, ASR rises to 46.59% and DR to 79.92%. The authors state that revisions lacking subsequent scan evolution are more likely to be flagged by SkillScan.
    • Closed loop: The full method has ASR 46.99% and DR 0.00%. Relative to iterative Phase 1, ASR is 12.05 percentage points higher and DR remains 0; relative to iterative Phase 2, DR is 79.92 percentage points lower and ASR is 0.40 percentage points higher. The abstract and contributions state 12.05% and 79.92%. The authors state that a cross-stage closed loop is therefore necessary.

    Construction and Two-Stage Dynamics

    • Construction rounds (Figure 3): Task-level intent, skill-level goal, and determination rule average 1.49, 2.24, and 1.84 rounds, with first-round acceptance rates of 69.15%, 80.72%, and 61.04%. The distribution for skill-level goals extends to 29 rounds, hence the higher mean. Intent is constructed once per task; goals and rules are constructed per task–skill pair and fixed after acceptance.
    • Cold start (Figure 4): Only 34.54% of initial candidates receive a valid scan with zero findings. Cumulative acceptance rates are 84.34% by round 5 and 95.18% by round 10; 4.82% require more than ten rounds. All 249 pairs reach zero findings within 30 rounds, averaging 3.23 rounds. From round 1 to round 5, combined high, medium, and low risk findings decrease by 81.82%, 78.21%, and 77.25%, respectively; the authors state that part of this is because those who passed leave, leaving fewer candidates for later scans.
    • Runtime (Figure 5): Cumulative ASR across the four models in round 1 is 34.54%–37.35%. The authors state that zero findings do not guarantee runtime success. At the end, it is 43.78%–46.99%, an increase of 8.03–12.45 percentage points relative to round 1. GLM-5.2 enters within 0.40 percentage points of its final ASR by round 6; more than half of Qwen3.5-397B's total gain occurs in rounds 5 to 8. After round 8, the additional gain for all four models in the last two rounds does not exceed 2.01 percentage points.

    Benign Task Accuracy

    • ΔACC (Table 4, Appendix C): SkillHarm computes on its filtered subset; other methods use the full benchmark. SkillDRE is −2.91, −3.58, 0.15, and −2.14 percentage points for DeepSeek-V4-Pro, Qwen3.5-397B, GLM-5.2, and Gemini-3.7-Flash, respectively, with a four-model average of −2.12. SkillJect averages 9.13, and SkillHarm averages 6.59.
    • Exceptions: SkillJect is 0.03 on Qwen, and SkillHarm is −3.35 on Qwen. SkillDRE is positive only on GLM-5.2 (0.15). The authors believe SkillDRE better preserves the original task goals. The main text of Figure 2 states that ACC improvements of 2.14–3.58 percentage points are observed on three models.
    • Case studies: The authors examined cases where there was no failure without attack but success under SkillDRE. In some, the agent skips task-relevant skills without attack, and the revised skill instructions cause it to invoke that skill and complete the benign goal. The authors believe this pattern may contribute to negative ΔACC.

    Other Ablations and Analyses

    • Manual review of 125/249, uniform sampling without replacement: 100% agreement on goal maliciousness, and all are judged to exceed legitimate task requirements; 96.8% agreement on rule correctness (Appendix E).
    • Among 249 accepted goals: File & Media Exfiltration 34.94%, Business Data Exfiltration 33.33%, Privacy Leakage 10.84%, Backdoor Attacks 8.84%, Result Manipulation 8.03%, Source Code Exfiltration 4.02%; the three exfiltration categories total 72.29% (Figure 6).
    • Claude Code, victim model DeepSeek-V4-Pro: ASR 42.57%, DR 0.00%, ASR is 4.42 percentage points lower than Codex's 46.99%; DR refers to SkillScan on the final skill, not the framework's runtime detection (Table 6).
    • Risk scores: 804 valid scans across 249 pairs satisfy M=9, L=5; among 1,703 pairwise comparisons, (10000, 1000, 10) has no inversions and no ties; (1,1,1) has 107 inversions and 303 ties; (3,2,1) has 13 inversions and 66 ties (Appendix B).
    • SkillScan cold-start findings: Data Exfiltration 23.65%, Unauthorized Tool Use 23.59%, Skill Discovery Abuse 17.53%; among high-risk, the related categories are Data Exfiltration 26.81% and Command Injection 23.55% (Table 5, main text).
  5. What are some points that can be further explored?

    The paper has no dedicated limitations section; Appendix B states that risk scores are not a calibrated measure of harm.

    Limitations and future directions identified by the authors

    • No dedicated section: The paper does not have a Limitations or Future Work section, nor does the conclusion frame any experimental result as a limitation of the method itself.
    • Risk score (Appendix B): The authors state that lexicographic minimization of (h, m, l) is a design choice, not a calibrated measure of relative harm across different findings.
    • Joint evaluation (Section 5): The authors state that layered defense feedback can guide adaptive skill attacks and motivates evaluating pre-execution and runtime defenses together.

    Experimental coverage

    • Scale: Victim models are DeepSeek-V4-Pro, GLM-5.2, Qwen3.5-397B-A17B, Gemini-3.7-Flash, four in total; SkillsBench has 94 tasks and 249 skills (Section 4.1). Attack model and target generator are both DeepSeek-V4-Pro; validator is DeepSeek-V4-Pro, GLM-5.2, and Kimi-K2.6.
    • Baselines and defenses: Table 2 reports SkillJect and SkillHarm, which the authors state were chosen for reproducible open-source implementations. Table 1 compares SkillAttack and SkillMutator; Table 2 does not give values for these two. Defenses are SkillScan using Qwen3.5-397B-A17B, and the fixed defense skill SkillSonar.
    • Ablations and framework: Table 3 only uses DeepSeek-V4-Pro as the victim model. The main experimental framework is Codex; Table 6 compares Claude Code on the same victim model, with ASR of 42.57% and 46.99% and DR of 0.00% for both.
    • Human review and subsets: Appendix E reviews 125/249. Appendix C states that SkillHarm's ΔACC is computed on its filtered subset, while other methods are computed on the full benchmark.
    • Budget: Attack target construction and each Phase 1 has at most 30 rounds; Phase 2 has at most 10 runtime trials per skill (Section 4.1). The paper does not report the number of repetitions.
  6. Summarize the main content of the paper

    SkillDRE fixes the goal and then performs two-stage evolution, achieving an average ASR of 45.28% across four victim models and a DR of 0%.

    SkillDRE uses feedback from pre-execution scanning and runtime defenses to automatically evolve complete malicious skill packages.

    • Problem: Skills can be repeatedly revised based on execution feedback, and attackers can exploit this to modify malicious skills. Implementations that pass scanning may fail at runtime, and revisions that fix execution may be flagged again by scanning, so the two stages must be handled together, and whether the legitimate task still works must be assessed separately.
    • Method: First construct task-conditioned malicious goals and judgment rules and fix them, keeping the red-team model as DeepSeek-V4-Pro. Phase 1 iterates on SkillScan's high, medium, and low risk weighted scores, entering Phase 2 only at zero score; Phase 2 executes under SkillSonar, and if it stalls or fails judgment, it revises and rescans until success or budget exhaustion.
    • Main results: On SkillsBench's 249 skills and four victim models, the average ASR is 45.28%, and the final SkillScan DR is 0.00%. Section 4.2 states the average ASR exceeds the strongest baseline by 40.3 percentage points, and the abstract writes 40.3%. Single-model ASR ranges from 43.78% to 46.99%, with both baselines not exceeding 9.00%.
    • Ablations and tasks: With victim model DeepSeek-V4-Pro, relative to iterative scanning-only, ASR is 12.05 percentage points higher and DR remains 0; relative to iterative runtime-only, DR is 79.92 percentage points lower (Table 3; abstract writes 12.05% and 79.92%). The four-model average ΔACC is −2.12 percentage points, with GLM-5.2 at +0.15 (Table 4).
    • Authors' conclusion: The authors state that two-stage defense feedback can serve as a learning signal for adaptive red teaming; evaluating only one defense stage misses the attack capability gained from this. The final skills show no risk findings under the SkillScan configuration used in evolution and largely maintain benign task performance.

Related papers

Show 3 more papers
Read originalarxiv.org