Submitted:
01 December 2026
Posted:
03 December 2026
You are already at the latest version
Abstract
The emergence of large language models (LLMs) asreasoning engines for cybersecurity has shifted the bottleneckfrom model capability to harness engineering—the disciplineof building the runtime infrastructure that transforms a lan-guage model into a reliable, controllable security agent. Thispaper presents a comprehensive methodology for designing,building, and deploying AI harnesses across the full spectrumof cybersecurity operations: penetration testing, red teaming,reverse engineering, security operations centers (SOC), malwareanalysis, and digital forensics. We synthesize insights fromeleven production harness systems, four foundational researchpapers, and five open-source security agent frameworks—Norma,ARTEX, NeuroSploit, Strix, and AiSOC—to identify seven coresubsystems, twenty-nine design patterns, and five orchestrationarchitectures that form the basis of effective security harnessdesign. We propose a layered reference architecture with concreteimplementation guidance for each layer, covering both cloud-hosted models (Anthropic Claude, OpenAI GPT) and locally-deployed models (Ollama, llama.cpp). A nine-phase develop-ment methodology is presented with working code examplesin Python and Rust. Our methodology addresses the uniquechallenges of security automation: tool safety in adversarialenvironments, evidence-backed claim verification, scope controlacross attack surfaces, and the critical separation between controland execution planes. We additionally present a threat modelfor AI security agents themselves, a complete implementationwalkthrough, lessons learned from production deployments, anda comparison with traditional security automation. We providearchitectural diagrams, pattern catalogs, and a step-by-stepdevelopment methodology that practitioners can follow to buildharnesses for any security domain.
Keywords:
AI harness engineering
; cybersecurity automation
; LLM agents
; penetration testing
; security operations
; multi-agent systems
; tool orchestration
; agent safety
; ReAct loop
; Model Context Protocol
1. Introduction
Cybersecurity stands at an inflection point. Large language models have demonstrated remarkable capability in understanding code, reasoning about vulnerabilities, planning multi-step attack chains, and interpreting forensic artifacts [1,18]. Yet the gap between a model that can reason about a SQL injection and a system that reliably finds, validates, and reports SQL injections in production web applications remains vast. That gap is the domain of harness engineering.
The term “harness” borrows from software testing, where a test harness wraps a unit of code to feed it inputs, capture outputs, and judge correctness. In the AI agent context, the harness is everything except the model itself: the loop that alternates inference and action, the tools the model can invoke, the memory that persists across turns, the safety layer that decides what runs and what requires approval, the orchestration logic that coordinates multiple agents, and the extension points that let practitioners customize behavior without modifying the core [1,2].
Research consistently demonstrates that harness design affects agent performance as much as—or more than—model selection. Databricks reported a benchmark improvement from 36.10% to 52.63% through harness changes alone [3]. The HERMES framework showed that a smaller model (Qwen3-8B) with a purpose-built harness stayed within 4.5% of GPT-5.6 Sol, with 26.2% inference cost reduction [4]. These findings carry profound implications for security practitioners: investing in harness engineering yields compounding returns regardless of which model sits behind the interface.
Cybersecurity imposes demands that general-purpose coding agents do not face. Security tools are inherently dual-use—the same Nmap scan that maps an authorized target constitutes unauthorized reconnaissance against another. Evidence must be machine-verifiable, not merely plausible. Attack chains require multi-step reasoning with state persistence across phases. And the consequences of an unconstrained agent—scanning the wrong target, exfiltrating data during a test, or executing a destructive payload—range from career-ending to criminal [20,21].
This paper addresses these challenges by presenting a comprehensive methodology for building AI harnesses tailored to cybersecurity. We draw on analysis of production systems (Claude Code, Codex, OpenHands, Gemini CLI), open-source security frameworks (Norma, ARTEX, NeuroSploit, Strix, AiSOC), and foundational research to construct a layered reference architecture. We then instantiate this architecture across six security domains, providing concrete implementation guidance, pattern catalogs, and evaluation criteria.
We organize harness engineering for cybersecurity as an emerging discipline with its own principles, decision frameworks, and development lifecycle. The goal is to provide practitioners with conceptual tools for reasoning about harness design decisions systematically, rather than relying on ad-hoc experimentation.
The remainder of this paper is organized as follows. Section 2 presents background, definitions, and related work. Section 3 formalizes the Agent = Model + Harness equation. Section 4 establishes harness engineering as a discipline with ten core principles and the harness engineering mindset. Section 5 and Section 6 detail the seven core subsystems and five security-specific layers. Section 7 covers orchestration patterns. Section 8 provides decision frameworks for architecture selection, model selection, tool granularity, and safety level configuration. Section 9 provides domain-specific harness designs for six cybersecurity disciplines. Section 10 and Section 11 address skills, tools, MCP, and local versus cloud model architectures. Section 12 and Section 13 cover sandboxing and safety. Section 14 presents a threat model for AI security agents. Section 15 details validation gates. Section 16 presents five case studies. Section 17 proposes the nine-phase methodology. Section 18 describes the development lifecycle from requirements through continuous improvement. Section 19 provides a complete implementation walkthrough. Section 20 distills lessons learned, including security-specific insights. Section 22 covers evaluation and benchmarks. Section 23 discusses future directions, and Section 24 concludes.
1.1. Contributions
Our contributions are:
- A proposal of harness engineering as a discipline for cybersecurity, with ten core principles, decision frameworks, and a development lifecycle model.
- A unified reference architecture for security AI harnesses with seven subsystems and domain-specific extensions for each security discipline.
- A pattern catalog of twenty-nine harness design patterns with security-specific applications, drawn from production system analysis.
- Decision frameworks for architecture selection, model selection, tool granularity, and safety level configuration that guide practitioners through consequential design choices.
- A step-by-step methodology (nine phases) and development lifecycle for building and maintaining security harnesses from requirements through continuous improvement.
- Comparative analysis of five open-source security harness systems (Norma, ARTEX, NeuroSploit, Strix, AiSOC) with architectural diagrams and pattern extraction.
- A complete implementation walkthrough demonstrating a working security harness in Python with provider abstraction, scope enforcement, tool wrapping, and evidence recording.
- A threat model for AI security agents addressing prompt injection, scope escape, evidence fabrication, data leakage, supply chain attacks, and agent weaponization.
- Comprehensive lessons learned from production deployments, including four security-specific insights on adversarial conditions, compliance, and human-AI collaboration.
2. Background, Definitions, and Related Work
2.1. From Prompt Engineering to Harness Engineering
The evolution of AI agent development has progressed through three distinct phases. Prompt engineering (2022–2023) focused on crafting inputs that elicited better outputs from fixed models [22]. Context engineering (2023–2024) expanded the aperture to include retrieval-augmented generation, few-shot examples, and structured context assembly [23]. Harness engineering (2024–present) recognizes that the prompt is one component of a larger system that includes the execution loop, tool interfaces, memory management, safety constraints, and multi-agent coordination [3].
WalkingLabs formalizes the distinction: “A harness doesn’t make the model smarter; it makes the model more reliable” [5]. The harness constrains agent behavior with explicit rules, maintains context across long-running tasks, prevents agents from declaring victory prematurely, verifies work through testing and self-reflection, and makes the runtime observable.
This evolution mirrors a broader pattern in software engineering. Early database applications embedded SQL strings directly in application code (analogous to prompt engineering). Object-relational mappers abstracted database access behind structured interfaces (context engineering). Full application frameworks provided lifecycle management, middleware, connection pooling, and health monitoring (harness engineering). Each stage raises the abstraction level and reliability without requiring the underlying technology to change.
2.2. The Security Agent Landscape
A survey of the Awesome Security Agent Harnesses repository [6] catalogs approximately 99 unique projects across eight categories: code audit harnesses (15), pentesting agents (27), fuzzing and vulnerability discovery (8), DARPA AIxCC competition systems (7), agent tooling and integrations (13), agent sandboxes (5), benchmarks and evaluations (14), and readings (17). Category totals sum to 106 because some projects appear in multiple categories (e.g., a pentesting agent that also performs code audit). This landscape reveals both the explosive growth of the field and the fragmentation of approaches.
Figure 1.
Distribution of 99 cataloged security agent projects across eight categories. Pentesting dominates, reflecting both commercial interest and the natural fit between LLM reasoning and multi-step attack workflows. Data from [6].
Figure 1.
Distribution of 99 cataloged security agent projects across eight categories. Pentesting dominates, reflecting both commercial interest and the natural fit between LLM reasoning and multi-step attack workflows. Data from [6].

2.3. Key Terminology
- Agent
- A system that uses an LLM as its reasoning core to perceive its environment, make decisions, and take actions toward a goal [19].
- Harness
- The complete runtime infrastructure surrounding the model—loop, tools, memory, safety, orchestration, and extensions—that transforms an LLM into a functional agent [1].
- Skill
- A reusable, self-contained instruction package (typically aSKILL.mdor YAML-frontmatter document) that configures an agent for a specific task domain without modifying harness code.
- Tool
- A discrete function the agent can invoke through its harness, with defined inputs, outputs, and permission requirements.
- MCP
- Model Context Protocol—a standardized protocol for connecting agents to external tool servers, enabling tool discovery and invocation across process boundaries [15].
- ReAct
- Reason + Act—the foundational agent loop pattern where the model alternates between reasoning about what to do and executing actions [2].
2.4. Related Work: Traditional Security Automation
Before AI harness engineering, security automation relied on deterministic pipelines and rule-based systems. Understanding this lineage contextualizes where AI harnesses provide novel value.
Vulnerability Scanners. Tools like Nessus [41], OpenVAS, and Qualys automate vulnerability detection through signature matching and version checks. They produce comprehensive but noisy output with high false-positive rates (often 30–60%), requiring significant human triage [42]. Scanners cannot reason about context: they flag a vulnerable library version regardless of whether the vulnerable code path is reachable. AI harnesses address this through LLM-powered reachability analysis and cross-model verification, as demonstrated by NeuroSploit’s three-tier evidence system [8].
SAST and DAST Tools. Static Application Security Testing tools (Semgrep, CodeQL, Checkmarx) analyze source code for vulnerability patterns. Dynamic Application Security Testing tools (Burp Suite [52], OWASP ZAP) test running applications. Both categories are limited by their inability to reason about novel vulnerability patterns not captured in their rule sets. SAST tools produce high false-positive rates because they lack runtime context; DAST tools miss business logic vulnerabilities because they lack semantic understanding. AI harnesses bridge this gap by combining tool outputs with LLM reasoning that understands both code semantics and application context.
SIEM and SOAR Platforms. Splunk, Microsoft Sentinel, and Palo Alto XSOAR automate alert correlation and response through predefined playbooks [53]. These systems are powerful but rigid: every decision branch must be explicitly coded by security engineers, creating a maintenance burden that scales with the complexity of the threat landscape. When a novel attack pattern emerges, SOAR playbooks must be manually updated—a process that can take days or weeks. AiSOC [10] demonstrates that an AI harness can replace rigid playbook logic with LLM-driven investigation while maintaining the deterministic guardrails (typed tools, grounding checks) that regulated environments require.
Penetration Testing Frameworks. Metasploit [40] and Cobalt Strike provide exploit frameworks with extensive module libraries, but they require human operators to select targets, choose exploits, chain attacks, and interpret results. The operator’s expertise is the bottleneck. PentestGPT [51] demonstrated early potential for LLM-assisted pentesting but operated as a conversational assistant rather than an autonomous agent. ARTEX [11] and Strix [12] advance beyond this by implementing fully autonomous multi-agent architectures where the LLM planner replaces the human operator for tactical decisions while maintaining human oversight for strategic ones.
Fuzzing Frameworks. AFL [54], libFuzzer, and honggfuzz use coverage-guided mutation but cannot reason about program semantics. They find crashes mechanically through brute-force input mutation. LLM-augmented fuzzers represent a harness-engineering approach: ChatAFL [33] uses LLMs to generate semantically meaningful protocol inputs, Fuzz4All [34] applies LLMs for universal input generation across languages, and OSS-Fuzz-Gen [35] uses LLMs to generate the fuzz harnesses themselves. The AI harness manages the feedback loop between fuzzer output and LLM reasoning, enabling targeted mutation strategies that coverage-guided fuzzing alone cannot achieve.
Key Difference. Traditional tools automate execution; AI harnesses automate judgment. A vulnerability scanner executes predefined checks; a harness-driven agent reasons about what to check, interprets ambiguous results, chains findings into attack paths, and adapts strategy based on discoveries. The harness is what makes this judgment reliable and safe.
2.5. Related Work: AI Agent Frameworks
General-purpose AI agent frameworks provide building blocks that security harnesses can leverage or learn from, though none directly addresses the unique requirements of security operations.
AutoGPT and BabyAGI. The earliest autonomous agent frameworks [49,50] demonstrated that LLMs could decompose goals into tasks and execute them autonomously. However, they lacked safety controls, had no tool mediation layer, and suffered from “agent drift” where the model diverged from its original objective. These failures directly motivated the safety-first design of modern security harnesses.
AutoGen. Microsoft’s AutoGen [24] introduced multi-agent conversation as a programming paradigm, enabling “conversable agents” that can interact with each other and with humans. Its contribution to security harnesses is the formalization of role-based agent design (e.g., planner, executor, critic) and human-in-the-loop patterns. However, AutoGen’s generic conversation framework does not enforce scope control or evidence verification.
MetaGPT. MetaGPT [25] applies software engineering processes (requirements, design, coding, testing) to multi-agent coordination. Its insight—that structured processes improve multi-agent output quality—directly parallels the finding that structured planning improves security harness reliability [13]. MetaGPT’s Standard Operating Procedures (SOPs) are analogous to security skills.
CrewAI. CrewAI [27] focuses on role-playing autonomous agents with configurable delegation levels. Its role-based design (researcher, writer, analyst) maps naturally to security team roles (reconnaissance specialist, exploitation expert, report writer). CrewAI’s backstory and goal mechanisms are analogous to the system prompts used in security skills.
LangGraph. LangGraph [26] models agent workflows as state machines with explicit transitions. This graph-based approach has direct applicability to security harnesses where attack workflows follow well-defined phase transitions (recon to scanning to exploitation to post-exploitation). LangGraph’s persistence and human-in-the-loop checkpoints address requirements that security harnesses must satisfy.
SWE-agent. SWE-agent [21] introduced the Agent-Computer Interface (ACI), optimizing how agents interact with development tools. Its contribution to security harnesses is the insight that tool interface design—how the agent sees and uses tools—affects agent capability as much as which tools are available. This insight motivated the tool wrapper pattern (Section 17).
Gap Analysis. None of these frameworks addresses scope enforcement, evidence verification, credential redaction, dual-use tool mediation, or compliance mapping—all requirements unique to security automation. Security harnesses must build upon these frameworks’ insights while adding the domain-specific layers identified in Section 6.
3. The Agent Equation: Model + Harness
The foundational insight of harness engineering, articulated independently by Barbaste et al. [1], Databricks [3], and Aikido [7], is captured in a single equation:
The model provides reasoning, language understanding, and generation. The harness provides everything else: the execution loop, tool interfaces, context management, safety enforcement, agent coordination, and extensibility. The quality of the resulting agent is a function of both components, but the harness typically has more leverage than the model choice.
Figure 2.
The Agent = Model + Harness architecture. The model provides reasoning; the harness provides seven subsystems (dashed grouping) that make that reasoning actionable, safe, and verifiable.
Figure 2.
The Agent = Model + Harness architecture. The model provides reasoning; the harness provides seven subsystems (dashed grouping) that make that reasoning actionable, safe, and verifiable.

This separation has a practical consequence: a well-engineered harness can extract high performance from a smaller, cheaper, or locally-hosted model, while a poorly-engineered harness wastes the capabilities of even the most powerful frontier model. Barbaste et al. documented this across eleven production systems, finding that no system imports a general-purpose agent framework—every production harness is hand-rolled to its domain’s specific needs [1]. This convergent evolution suggests that the architecture patterns identified in this paper represent genuine engineering requirements rather than arbitrary design choices.
3.1. The ReAct Loop
At the heart of every agent harness is the ReAct (Reason + Act) loop [2]. The model receives context, reasons about what to do next, selects a tool to invoke, observes the result, and repeats until a stopping condition is met. In cybersecurity, this loop takes a characteristic form with an added validation gate between observation and the next reasoning step.
Figure 3.
The Security ReAct Loop extends the standard ReAct pattern with a validation gate. On “Pass,” the loop returns to context assembly (dashed arrow); on “Done/Fail,” it terminates with a report.
Figure 3.
The Security ReAct Loop extends the standard ReAct pattern with a validation gate. On “Pass,” the loop returns to context assembly (dashed arrow); on “Done/Fail,” it terminates with a report.

The validation gate checks whether the action stayed within authorized scope, whether the output contains genuine evidence (not hallucinated findings), and whether safety invariants hold. NeuroSploit implements this as a two-stage process: a deterministic CWE validator checks tool output against recorded request/response bytes, followed by a cross-model vote where a second LLM independently assesses the finding [8]. This dual validation is designed to reduce false positives compared to single-model assessment, at the cost of additional inference latency. The magnitude of improvement depends on the models used, the vulnerability classes tested, and the quality of evidence provided to the verifier; empirical measurement on controlled benchmarks is needed to quantify the effect.
The validation gate is the primary mechanism by which the harness enforces assurance—the property that outputs are true, the agent stayed within scope, and the engagement can withstand post-hoc scrutiny [55]. Without this gate, the ReAct loop is a capability amplifier; with it, the loop becomes a controllable, auditable security tool.
3.2. ReAct Loop in Practice: SQL Injection Walkthrough
To illustrate the Security ReAct loop concretely, consider an agent tasked with testing /api/ users?id=1 for SQL injection on an authorized target.
Iteration 1. Context Assembly: The harness loads the engagement scope (authorized domain: app.example.com), the SQL injection skill (Listing 2), and the target endpoint from the asset graph. Reason: The model identifies the id parameter as a numeric input likely interpolated into a SQL query. It selects a detection payload: 1 OR 1=1–. Act: The harness validates the target against scope (pass), classifies the operation as “testing” (permitted), and executes the HTTP request tool. Observe: The response returns all user records instead of one—a content-length anomaly of 4,827 bytes versus the baseline 312 bytes. Validation Gate: The harness records the raw request/response pair as evidence. The deterministic validator flags the content-length discrepancy as consistent with boolean-based SQL injection. The finding passes to the next iteration for confirmation.
Iteration 2. Context Assembly: Prior iteration’s finding (suspected boolean-based SQLi) plus recorded evidence. Reason: The model selects a confirmation payload: 1 AND 1=2–, which should return zero records if injection is real. Act: HTTP request executed. Observe: Empty result set (0 bytes body). The behavioral difference between 1 OR 1=1 (all records) and 1 AND 1=2 (no records) confirms boolean-based injection. Validation Gate: The deterministic CWE-89 validator confirms: two complementary payloads produced opposite behaviors on the same endpoint. Cross-model verification is triggered—a second model receives the raw HTTP pairs and independently concludes SQL injection is present with high confidence.
Iteration 3. Reason: The model determines the database type via version-specific payloads (1 UNION SELECT version()– for PostgreSQL, 1 UNION SELECT @@version– for MySQL). Act: Both payloads executed. Observe: The PostgreSQL payload returns “PostgreSQL 15.4.” Validation Gate: Evidence recorded. The harness computes CVSS v4.0 score (9.8 Critical: network vector, no authentication, confidentiality impact high) and generates the finding with complete evidence chain. The loop terminates with a verified, evidence-backed finding ready for the report.
This walkthrough demonstrates three properties the validation gate enforces: (1) no finding is reported after a single test—confirmation requires at least two corroborating observations, (2) every claim is backed by recorded HTTP request/response pairs that can be replayed, and (3) cross-model verification provides independent assessment before the finding enters the final report. Without the validation gate, Iteration 1 alone might produce a report—potentially a false positive if the endpoint simply returns all users for any invalid id value.
4. Harness Engineering as a Discipline
4.1. Defining the Discipline
Harness engineering for cybersecurity is not merely the act of wrapping an LLM in a loop with tools. It is a systematic engineering discipline with its own body of knowledge, design principles, failure taxonomies, and evaluation criteria. Just as structural engineering provides the principles for safe bridge construction and software engineering provides patterns for reliable system design, harness engineering provides the conceptual and practical framework for building AI agents that operate reliably in adversarial environments.
The discipline sits at the intersection of three established fields: systems engineering (decomposition, interface design, integration testing), security engineering (threat modeling, defense in depth, least privilege), and AI alignment (ensuring agent behavior conforms to operator intent). None of these fields alone is sufficient. Systems engineering lacks adversarial reasoning. Security engineering lacks the probabilistic nature of LLM-driven systems. AI alignment lacks the operational focus on tool mediation and evidence verification. Harness engineering synthesizes all three into a coherent practice.
The strongest evidence for harness engineering as a genuine discipline—rather than an ad-hoc collection of techniques—is convergent evolution. Barbaste et al. found that no production system imports a general-purpose agent framework; every production harness is hand-rolled to its domain’s specific needs [1]. Yet these independently developed systems converge on the same architectural patterns: coordinator-worker orchestration, fail-closed tool permissions, lineage compaction, verify-on-stop guards. This convergence suggests that these patterns are not arbitrary design choices but engineering necessities—the equivalent of load-bearing walls in architecture. When independent teams facing the same constraints arrive at the same solutions, those solutions constitute the canon of a discipline.
4.2. Ten Core Principles of Security Harness Engineering
We distill ten principles from our analysis of production systems, research papers, and open-source frameworks. These principles are not guidelines or best practices—they are the invariants that distinguish a well-engineered harness from an ad-hoc wrapper.
- P1.
- The Harness Outweighs the Model. Harness design affects agent performance as much as—or more than—model selection. Databricks documented a benchmark improvement from 36.10% to 52.63% through harness changes alone [3]. HERMES showed a smaller model with a purpose-built harness stays within 4.5% of a frontier model [4]. Invest in the harness first.
- P2.
- Fail-Closed by Default. Every tool, every permission, every scope check defaults to deny. Norma’s fail-closed tool factory [9] exemplifies this: no tool executes without explicit approval. The cost of a false denial (the agent asks for permission) is negligible; the cost of a false allow (unauthorized action on a production system) can be catastrophic.
- P3.
- Evidence Over Assertion. No finding is reported without recorded, replayable proof. The model’s confidence is not evidence. NeuroSploit’s three-tier verification—tool output recording, deterministic CWE validators, cross-model voting [8]—illustrates this principle. Recording evidence enables verification; it does not guarantee findings are correct, but it makes correctness assessable.
- P4.
- Separation of Planes. The control plane (planning logic, engagement scope, credentials, API keys) must be isolated from the execution plane (tools that interact with targets). Aikido identifies this as the most important architectural recommendation [7]. A compromised tool should never access the control plane’s secrets.
- P5.
- Defense in Depth. Multiple independent safety layers ensure no single bypass compromises the system. Claude Code uses three layers; Codex uses four; our reference architecture defines five (Section 13). Each layer operates independently—subverting the LLM classifier does not bypass the OS sandbox.
- P6.
- Scope as Invariant. Scope is not a suggestion encoded in a prompt; it is an architectural invariant enforced in code before every tool execution. The engagement scope is loaded once, validated at startup, and checked synchronously before every network-touching operation. No model reasoning, no matter how compelling, can override a scope check.
- P7.
- Model-Agnostic Design. The harness must function across providers without architectural changes. Norma’s dual-provider abstraction [9] and NeuroSploit’s 19-provider integration [8] demonstrate that model-agnostic design is both achievable and necessary—for cost optimization, capability matching, cross-model verification, and organizational resilience.
- P8.
- Progressive Trust. Start with maximally restrictive permissions and loosen incrementally based on demonstrated safety. Every production system in Barbaste et al.’s survey started restrictive [1]. The reverse—starting permissive and adding restrictions after incidents—is more expensive, more dangerous, and more common in immature deployments.
- P9.
- Observability as Requirement. Every tool invocation logged, every decision traceable, every finding auditable. Observability is not a debugging convenience; it is a compliance requirement, an evidence source, and the foundation for harness improvement. Without observability, the harness is a black box that cannot be trusted, audited, or improved.
- P10.
- Skills as Knowledge Capture. Domain expertise is encoded in portable, versionable, testable artifacts (SKILL.md format). Skills transform tacit security knowledge into reusable components. NeuroSploit’s 486 playbooks [8] demonstrate that mature harnesses require extensive skill libraries. Skills are the discipline’s equivalent of design patterns—named, documented solutions to recurring problems.
4.3. The Harness Engineering Mindset
The harness engineering mindset differs fundamentally from prompt engineering and context engineering. Prompt engineering asks: “How do I craft the input to get better output?” It optimizes a single variable—the prompt—within a fixed system. Context engineering asks: “How do I assemble the right information for the model?” It optimizes the retrieval and assembly of context. Harness engineering asks: “How do I build the system that makes the model’s output reliable, safe, and verifiable?” It optimizes the entire runtime.
The shift in mindset is categorical. Think in subsystems, not prompts. Think in invariants, not suggestions. Think in evidence chains, not model confidence. The harness engineer’s central question is: “What must remain true regardless of what the model decides?” The answer to that question defines the harness’s safety properties, scope constraints, and verification requirements. Everything the model must not do is enforced in code; everything the model should do is guided by skills; everything the model does do is recorded as evidence.
4.4. A Maturity Model for Security Harness Engineering
Organizations adopting harness engineering progress through identifiable maturity levels. Understanding these levels helps practitioners assess their current state and plan improvements.
Level 1 — Ad-Hoc. Security tools are invoked through direct LLM prompts without a structured harness. No scope enforcement, no evidence recording, no safety layers. The model self-polices through prompt instructions. This level is common in early experimentation and carries significant risk in production.
Level 2 — Structured. A basic harness wraps the model with scope checking and tool registration. Evidence is recorded but not verified. A single safety layer (static rules) is in place. Skills exist but are informal and unversioned. Most organizations building their first security agent operate at this level.
Level 3 — Verified. Multi-layer safety is implemented. Evidence verification (deterministic validators, cross-model voting) is operational. Skills are versioned and tested. The harness has its own test suite. Deployment follows the shadow-to-supervised progression. This level represents production readiness.
Level 4 — Optimized. Model routing optimizes cost and capability. Continuous improvement loops refine skills based on production findings. The harness monitors its own performance metrics (TPR, FPR, EQS). Multi-agent orchestration enables complex engagements. This level represents mature deployment.
Level 5 — Adaptive. The harness generates and validates its own skills based on novel findings. Disposable harnesses are generated per engagement. Federated harness architectures enable cross-organization security workflows. This level remains aspirational for most organizations but represents the discipline’s trajectory.
This mindset produces a characteristic design heuristic: when in doubt, constrain the model rather than trusting it. A model that reasons “I should scan 192.168.1.0/24 because it appears related to the target” may be correct. But the harness does not evaluate correctness—it evaluates authorization. If 192.168.1.0/24 is not in the engagement scope, the scan is blocked regardless of the model’s reasoning quality. This separation between judgment (the model’s domain) and policy (the harness’s domain) is the discipline’s foundational insight.
5. Core Architecture: Seven Subsystems
Barbaste et al.’s study of eleven production harness systems identified seven core subsystems that every effective harness must implement [1]. The subsystem taxonomy, the twenty-nine design patterns, and the observation that production harnesses converge on hand-rolled architectures originate from their work. Our contribution in this section is the security-specific extension: for each subsystem, we identify requirements unique to adversarial environments (scope enforcement, evidence verification, dual-use tool mediation, credential redaction) that Barbaste et al. do not address, as their analysis focuses on coding agents rather than security agents.
Figure 4.
The seven core subsystems around the central agent loop. Safety & Permissions (red border) carries elevated importance in security contexts.
Figure 4.
The seven core subsystems around the central agent loop. Safety & Permissions (red border) carries elevated importance in security contexts.

5.1. The Agent Loop
The agent loop is the execution core: it alternates between LLM inference and action execution, handling retries, errors, and stop conditions. Every harness in the survey implements a streaming tool-use loop where the model emits tool calls and the harness executes them before feeding results back. Norma implements parallel scheduling for read-only tools and serial execution for mutating operations [9], a pattern that significantly improves throughput in reconnaissance-heavy security tasks where multiple DNS lookups, WHOIS queries, and certificate transparency searches can run concurrently.
The loop must handle three categories of termination: success (the task is complete), failure (an unrecoverable error occurred), and budget exhaustion (context window, token budget, or time limit reached). Security harnesses add a fourth: scope violation (the agent attempted an unauthorized action). Each termination type produces different output artifacts and triggers different post-processing.
Error recovery within the loop follows a classification hierarchy. Transient errors (network timeouts, rate limits, temporary service unavailability) trigger exponential backoff with jitter—NeuroSploit retries up to three times with 2n second delays [8]. Permanent errors (authentication failure, tool crash, invalid parameters) cause the loop to skip the current action, record the failure, and re-invoke the LLM with the error context so it can select an alternative approach. Scope violations are never retried; they produce an immediate alert and, depending on configuration, either abort the engagement or escalate to human review. Budget management is equally critical: the harness tracks token consumption per turn, estimates remaining budget based on average turn cost, and triggers graceful shutdown (“produce best report with current findings”) when budget drops below a configurable threshold, typically 15% of the total allocation.
5.2. LLM Integration
A security harness must support multiple model providers for both practical and architectural reasons. Practical: different models excel at different security tasks (code analysis vs. natural language report writing). Architectural: cross-model verification requires querying a second model to validate findings [8]. Norma provides vendor-neutral adapters for Anthropic and OpenAI wire formats [9]. NeuroSploit extends this to 19 provider integrations, including both cloud (Claude, GPT, Gemini) and local (Ollama, llama.cpp) backends [8].
The integration layer must handle provider-specific differences: tool call format schemas, streaming protocols (SSE vs. WebSocket), context window sizes, capability detection, and rate limiting. A well-designed abstraction layer enables hot-swapping providers without modifying harness logic—critical for organizations that may need to switch providers due to compliance, cost, or availability considerations.
Caching strategies are essential for cost management in long-running security operations. Prompt caching (supported by Anthropic and increasingly by other providers) avoids retransmitting the system prompt, skill definitions, and static tool schemas on every turn. For a security harness with a 4,000-token system prompt and 30 tool definitions (∼6,000 tokens), caching reduces per-turn input cost by approximately 40%. Token management requires tracking both input and output consumption: the harness maintains a running budget, alerts when consumption exceeds projections, and can dynamically switch from a frontier model to a cheaper model for routine operations (DNS lookups, port scan result parsing) while reserving the frontier model for complex reasoning (exploit development, vulnerability chain analysis). Model routing—directing different subtasks to different models based on complexity—is an emerging pattern: AiSOC routes basic alert triage to a local 3B-parameter model while escalating complex investigations to cloud frontier models [10].
5.3. Tools and Actions
Tools are the agent’s interface to the security environment. Unlike general-purpose coding tools, security tools carry inherent dual-use risk. A nmap_scan tool must encode scope restrictions into its implementation, not rely on the model to self-police. Norma enforces this through a fail-closed tool factory where every tool requires explicit approval by default [9]. AiSOC takes a different approach with typed tools—the model never writes SQL directly; instead, it calls typed query functions that the harness validates before execution [10].
Tool design principles for security include: (1) fail-closed default—every tool requires explicit approval, (2) scope binding—network-touching tools validate targets against engagement scope, (3) output limiting—truncation and summarization prevent context overflow, (4) credential redaction—discovered secrets are replaced with tokens, and (5) idempotency marking—read-only tools are safe to retry; mutations are flagged.
Tool schema design deserves particular attention. Each tool definition presented to the model includes a name, description, and JSON schema for parameters. Poor schema design—vague descriptions, overly permissive parameter types, missing constraints—degrades model performance even when the underlying tool is well-implemented. Best practice is to constrain parameters as tightly as possible: an nmap_scan tool should accept a target (validated against scope), a ports parameter (constrained to valid port ranges), and a scan_type enum (“syn”, “connect”, “udp”), rather than accepting a freeform flags string that the model might fill with dangerous options like -sV –script=exploit. Output shaping transforms raw tool output into model-friendly formats: Nmap’s XML output is parsed into a structured summary listing only open ports, service versions, and notable scripts; Burp Suite’s verbose crawl output is reduced to discovered endpoints with parameter annotations. SWE-agent’s Agent-Computer Interface research [21] demonstrated that this interface design affects agent capability as much as which tools are available.
5.4. Memory and Context
Security tasks are inherently long-running. A penetration test may span hours or days, with each phase building on discoveries from previous phases. Context management must handle both within-session compaction (summarizing older context to fit the window) and cross-session persistence (resuming an engagement after a break). ARTEX implements dual graph memory: an asset graph shared across all tasks and per-task exploration graphs [11]. This mirrors approaches in multi-agent systems research [24,25] but with security-specific state semantics.
Context compaction is particularly challenging in security because everything might matter. A seemingly irrelevant HTTP header observed during reconnaissance may become critical during exploitation. The harness must implement intelligent compaction that preserves security-relevant details (findings, evidence, scope decisions) while summarizing routine tool output (verbose scan results, repeated error messages).
Three compaction strategies have emerged in practice. Lineage compaction [1] preserves the chain of reasoning that led to each finding while summarizing intermediate tool outputs—the model retains “discovered subdomain api.target.com via DNS enumeration” but not the full DNS response. Sliding window with anchors maintains the most recent N turns in full detail while older turns are summarized, with “anchor” turns (those containing findings, scope decisions, or evidence) preserved verbatim regardless of age. Hierarchical compaction operates at multiple granularities: per-tool output (summarize immediately after observation), per-phase (summarize when transitioning from reconnaissance to scanning), and per-session (produce a comprehensive state summary for checkpoint/resume). Cross-session persistence requires serializing the current state—discovered assets, confirmed findings, tested endpoints, remaining scope—into a format that can reconstruct agent context in a new session. ARTEX’s PostgreSQL-backed graph [11] provides the most robust implementation, where every discovery is a node that persists independently of the LLM’s context window.
5.5. Safety and Permissions
Security harnesses operate in the highest-risk category of AI agent systems. The safety layer must implement defense-in-depth with multiple independent checks. Claude Code’s three-layer approach—static hook rules, LLM permission classifier, and interactive user dialog—provides a template [1]. Codex adds a fourth layer with OS-level sandboxing via Bubblewrap and Seatbelt [1]. For security specifically, the permission system must enforce scope control (authorized targets only), operation classification (read vs. write vs. destructive), and escalation protocols (human approval for high-impact actions).
5.6. Safety and Permissions: Worked Example
Consider a concrete scenario: during a penetration test of app.example.com, the agent discovers an SSRF vulnerability and reasons that it should probe 169.254.169.254 (the AWS metadata endpoint) to assess cloud impact. The five-layer defense processes this as follows.
Layer 1 (Static Rules): The scope allow-list contains only *.example.com and 10.0.0.0/8. The metadata IP 169.254.169.254 matches neither. The request is blocked with a scope violation alert. If the harness is configured to hard-block on scope violations, execution stops here.
However, consider a subtler case: the agent crafts an SSRF payload that redirects through app.example.com itself to reach the metadata endpoint. The target URL is in scope (app.example.com), so Layer 1 passes it.
Layer 2 (LLM Classifier): An independent LLM (not the planning model) analyzes the tool call parameters. It detects that the HTTP payload contains a redirect to 169.254.169.254 and flags the request as “indirect out-of-scope access—HIGH RISK.” This layer operates on the semantics of the request, not just the target URL.
Layer 3 (Human Approval): The request is escalated with full context: “Agent wants to test SSRF chaining through app.example.com to AWS metadata endpoint. This accesses infrastructure outside the explicit scope. Approve?” The human operator can approve (the SSRF is a legitimate finding worth documenting), modify (test with a canary URL instead), or reject.
Layer 4 (OS Sandbox): Even if approved, the Docker container running the tool has iptables rules that only allow outbound connections to the authorized IP ranges. The container-level firewall provides a final enforcement layer independent of all software-level checks.
Layer 5 (Post-Execution Audit): After execution (whether successful or blocked), the complete event—including the agent’s reasoning, the tool parameters, all layer decisions, and the outcome—is logged to the immutable audit trail. Anomaly detection flags this event as unusual (first metadata endpoint access attempt in this engagement) for post-engagement review.
This layered approach ensures that no single bypass—whether through prompt injection, model confusion, or software bug—compromises safety. An attacker who subverts the model’s judgment (Layer 2 bypass) is still caught by static rules (Layer 1) or the OS sandbox (Layer 4). An attacker who crafts a payload that evades static rules is caught by the semantic LLM classifier (Layer 2) or human review (Layer 3).
5.7. Orchestration
Complex security operations require multiple agents working in coordination. A penetration test might employ a reconnaissance agent, a vulnerability scanner agent, an exploitation agent, and a reporting agent—each with different tool sets and permission levels. Barbaste et al. found that the coordinator-worker pattern emerged independently across nearly all production systems [1]. ARTEX implements this with a planner loop that emits intents and worker goroutines that execute them, sharing state through the dual graph [11]. This convergent evolution parallels findings in multi-agent research [24,26,27].
Coordinator-Worker Walkthrough. Consider a penetration test against a web application with three discovered subdomains. The coordinator analyzes the asset graph and creates a plan: “Worker 1: enumerate endpoints on api.target.com. Worker 2: run Nuclei templates against admin.target.com. Worker 3: test authentication flows on login.target.com.” Each worker operates with a reduced context window containing only its assigned subdomain, relevant tools, and the portion of the asset graph pertaining to its target. Workers publish findings to the shared state graph. When Worker 1 discovers an unauthenticated API endpoint at /api/v2/internal/users, the coordinator observes this graph change and creates a new intent: “Worker 4: test discovered internal API for IDOR and data exposure.” Meanwhile, Worker 2’s Nuclei scan reveals an outdated jQuery version with known XSS vectors. The coordinator correlates this with Worker 3’s finding that the login page reflects user input without encoding, creating a composite finding: “Reflected XSS via login form (Worker 3) combined with vulnerable jQuery (Worker 2) enables DOM-based attack chain.” This cross-worker correlation—a capability no individual worker possesses—is the coordinator’s primary value.
5.8. Extensibility
Three extension mechanisms dominate: Skills (reusable instruction packages in SKILL.md format, adopted by 9 of 11 production systems), MCP servers (standardized tool servers, adopted by 8 of 11), and Hooks (lifecycle callbacks that intercept events like tool invocation and session transitions) [1]. Strix provides nine installable skills compatible with Claude Code, Cursor, and Codex [12]. The extensibility layer enables security teams to share expertise as portable artifacts—a SQL injection skill written for one harness can be adapted for another.
The skill lifecycle follows four stages: authoring (a security expert encodes methodology into SKILL.md format with YAML frontmatter specifying triggers, required tools, evidence requirements, and severity criteria), testing (the skill is validated against known-vulnerable targets to verify it produces correct findings with proper evidence), deployment (the skill is installed into one or more harness instances, where the agent discovers and loads it based on task-trigger matching), and maintenance (skills are versioned and updated as vulnerability classes evolve, new tools become available, or false positive patterns are identified). NeuroSploit’s 486 playbooks [8] represent the largest skill library in the survey, organized by security domain (web, infrastructure, mobile, AI/LLM, compliance) and continuously updated as new vulnerability classes emerge.
MCP server discovery enables dynamic tool expansion. When a harness connects to an MCP server, it receives a manifest of available tools with their schemas, descriptions, and capability declarations. This enables marketplace-style tool distribution: a community-maintained “Nuclei MCP” server exposes vulnerability scanning as a set of typed tools, a “Ghidra MCP” server provides binary analysis capabilities, and a “SIEM MCP” server enables log querying—all discoverable at runtime without harness code changes. AiSOC exposes its entire detection and investigation pipeline as an MCP server [10], allowing any MCP-compatible agent to leverage its 2,966 detection rules and typed investigation tools.
6. Security-Specific Harness Layers
Beyond the seven core subsystems, security harnesses require five additional layers that address the unique requirements of adversarial environments.
Figure 5.
Five security-specific layers extending the core harness architecture. Outer layers (scope control) enforce boundaries; inner layers handle evidence, state, defense awareness, and reporting.
Figure 5.
Five security-specific layers extending the core harness architecture. Outer layers (scope control) enforce boundaries; inner layers handle evidence, state, defense awareness, and reporting.

6.1. Scope Control and Target Authorization
Every security tool invocation must be checked against authorized scope before execution. This is not a prompt-level constraint—it must be enforced in code, at the harness level, before any tool runs. Aikido emphasizes: “prompt-only security is insufficient; prompt injection can subvert. Guardrails must be in code and infrastructure” [7].
Implementation requires an allow-list of authorized targets (domains, IP ranges, repositories) that is loaded at engagement start and checked by every tool that touches the network. The harness intercepts tool calls, extracts target parameters, and validates against the allow-list. A fail-closed default means any target not explicitly authorized is rejected, even if the model believes it should be in scope.
| Listing 1. Scope validation in the harness layer (Rust). |
![]() |
6.2. Evidence and Claim Verification
LLMs hallucinate. In security, a hallucinated vulnerability report is not merely useless—it wastes remediation effort, erodes trust, and can trigger unnecessary incident response [32]. The evidence layer ensures every claimed finding is backed by verifiable proof. NeuroSploit implements a three-tier verification system [8]: (1) tool output recording with timestamps, (2) deterministic CWE validators on recorded request/response bytes, and (3) cross-model voting where a second LLM independently assesses findings.
The evidence recording subsystem captures the complete input/output trace for every tool invocation. When the agent claims “SQL injection found in parameter id on /api/users,” the harness can verify this claim by replaying the recorded HTTP request and checking the response for SQL error signatures. This replay-based verification eliminates entire classes of hallucinated findings.
Cross-Model Voting Mechanics. NeuroSploit’s cross-model verification [8] operates as follows. After Model A produces a finding with evidence, the harness constructs a verification prompt containing only the raw evidence (HTTP request/response pairs, tool output, timestamps)—critically, not Model A’s analysis or conclusion. Model B receives this evidence with the instruction: “Analyze the following HTTP interaction. Determine whether a SQL injection vulnerability exists. Provide your confidence (high/medium/low) and reasoning.” Three outcomes are possible: (1) Agreement—both models confirm the finding, which proceeds to the report with “high confidence” designation. (2) Disagreement—Model B disputes the finding. The harness then invokes a third model (or the same model with a different prompt framing) as a tiebreaker, or escalates to human review. (3) Partial agreement—Model B confirms the vulnerability exists but disputes severity or impact. The harness takes the more conservative assessment. Cross-model voting introduces additional inference cost (roughly 1.5× per finding) but is designed to catch false positives that a single model would miss. The actual reduction rate depends on the model pair, vulnerability class, and evidence quality; controlled evaluation against labeled datasets is needed to quantify this benefit precisely. The investment is justified by the cost of false positives: a single incorrect finding in a penetration test report can consume hours of remediation effort and erode client trust.
Confidence scoring aggregates evidence quality, model agreement, and deterministic validator results into a single metric. A finding backed by raw HTTP evidence, confirmed by deterministic CWE validator, and agreed upon by two independent models receives maximum confidence. A finding based on timing-based inference (blind SQL injection with 5-second delay), confirmed by one model but not independently validated, receives medium confidence. Findings below a configurable threshold are flagged for mandatory human review before inclusion in the final report.
6.3. Attack State and Knowledge Graph
Security operations generate a graph of discoveries, not a flat list. A discovered subdomain leads to port scanning, which reveals services, which expose endpoints, which may have vulnerabilities that chain together. ARTEX models this as a dual graph: an asset graph (shared state of all discovered infrastructure) and per-task exploration graphs (the reasoning chain of goals, intents, facts, and findings) [11]. NeuroSploit optionally integrates Neo4j for attack knowledge graph storage, enabling graph queries across engagements [8].
The attack state graph serves three functions: (1) deduplication—avoiding redundant testing of already-assessed endpoints, (2) chaining—identifying multi-step attack paths that combine lower-severity findings, and (3) coverage tracking—ensuring all in-scope assets have been assessed.
6.4. Defense Awareness
A unique feature of ARTEX is its defense and detection guide: the harness generates Sigma rules, Suricata rules, MITRE ATT&CK Navigator heatmaps [16], and IoC (Indicators of Compromise) lists alongside its offensive findings [11]. This dual output makes the harness valuable for purple team exercises, where offensive findings directly feed defensive improvements. The defense awareness layer answers the question: “If this attack succeeded in production, how would the SOC detect it?”
6.5. Structured Reporting and Compliance
Security findings must map to established frameworks. NeuroSploit outputs HTML, PDF, Markdown reports plus SARIF [17], findings.json, attack graphs, execution traces, and proof-of-concept code [8]. Compliance mapping (PCI-DSS, HIPAA, SOC 2, GDPR) is encoded in the harness rather than delegated to the model, ensuring consistent and accurate classification. CVSS v4.0 scoring [44] is computed deterministically from finding attributes rather than estimated by the LLM.
7. Orchestration Patterns for Security Operations
Aikido identifies five foundational orchestration patterns [7]. Each maps to specific security use cases (Table 1).
7.1. The Coordinator-Worker Pattern in Depth
The most common pattern in security harnesses is the coordinator-worker architecture. ARTEX implements this with a Go-based planner loop that maintains a persistent todolist and emits intents onto the exploration graph. Worker goroutines pick up intents, execute tools, and publish results back to the graph. The planner observes graph changes and emits new intents, creating a closed loop [11].
Figure 6.
The Coordinator-Worker pattern. The planner delegates to specialized workers; workers publish results to shared state; state changes feed back to the planner.
Figure 6.
The Coordinator-Worker pattern. The planner delegates to specialized workers; workers publish results to shared state; state changes feed back to the planner.

The coordinator-worker pattern offers several advantages for security operations. The coordinator maintains strategic awareness across all workers, preventing redundant testing and enabling cross-domain finding chains (e.g., combining a recon discovery with an exploitation result). Workers operate with reduced context windows—they need only their specialization and the relevant portion of shared state, not the entire engagement history. This specialization enables the use of smaller, cheaper models for routine tasks (port scanning, DNS enumeration) while reserving frontier models for complex reasoning (exploit development, attack chain analysis).
7.2. Adversarial Verification Pattern
Unique to security harnesses is the adversarial verification pattern, where a “disprove agent” attempts to invalidate findings produced by a “prove agent.” NeuroSploit implements this through cross-model voting: after a finding is produced by one model, a different model receives the raw evidence and attempts to construct a counterargument [8]. Only findings that survive this adversarial review are promoted to the final report. This pattern has parallels in constitutional AI [28] and debate-based alignment.
The adversarial verification pattern is particularly effective for reducing false positives in automated security assessment. The “prove” agent is incentivized to find vulnerabilities (its success metric); the “disprove” agent is incentivized to challenge them (its success metric). This tension produces higher-quality output than either agent alone.
8. Decision Frameworks for Security Harness Design
Harness engineering as a discipline requires structured decision frameworks that guide practitioners through architectural choices. This section provides actionable frameworks for the four most consequential design decisions.
8.1. Architecture Selection Framework
The choice of orchestration architecture depends on four factors: security domain, engagement duration, target complexity, and team size. Table 2 maps common scenarios to recommended patterns.
The decision heuristic follows three rules. First, if the task has a fixed, sequential methodology (forensic analysis, compliance scanning), use prompt chaining—it provides deterministic progression and reproducibility. Second, if the task requires breadth across independent targets or data sources (multi-host scanning, parallel malware triage), use parallelization—workers share no state and can scale horizontally. Third, if the task requires depth with cross-domain reasoning (penetration testing, red teaming), use coordinator-worker—the coordinator maintains strategic awareness while workers specialize.
8.2. Model Selection Matrix
Not every task requires a frontier model. Table 3 maps security tasks to minimum model capabilities, enabling cost-effective model allocation.
The key insight is that a substantial fraction of security harness operations—routine classification, log parsing, report formatting—can run on local or mid-tier models, reserving frontier models for complex reasoning tasks. AiSOC demonstrates this with a default local model (llama3.2:3b) for basic operations [10]. Model routing—directing different subtasks to different models—is an emerging cost optimization pattern that the harness manages transparently.
8.3. Tool Granularity Decisions
Tool granularity—the scope of action each tool encompasses—is a critical design decision with direct safety implications. Fine-grained tools (one action per tool: dns_lookup, http_get, port_scan) give the model maximum control but require more tool-selection decisions. Coarse-grained tools (one workflow per tool: full_recon, scan_and_report) reduce decision complexity but limit model flexibility and make scope enforcement harder.
The security guideline: prefer fine-grained tools for anything scope-sensitive. Each network call should be a separate, scope-checked tool invocation. A coarse-grained full_recon tool that internally makes 50 network calls without individual scope checks creates 50 potential scope violations that the harness cannot intercept. Conversely, local computation (string parsing, report formatting, CVSS calculation) can use coarse-grained tools safely because no external action occurs.
8.4. Safety Level Selection
The appropriate safety configuration depends on the intersection of operation class and data sensitivity. Table 4 provides a decision matrix.
The matrix encodes a principle: as both operation risk and data sensitivity increase, more independent safety layers must be active. Passive reconnaissance of public data needs only scope validation (L1). Exploitation of classified systems requires all five layers. The harness loads this matrix at engagement start and applies it automatically, removing the burden of per-action safety decisions from the operator.
8.5. When to Build vs. Adopt
Practitioners face a build-versus-adopt decision when starting a security harness project. The decision depends on three factors: domain specificity (how unique are your security requirements?), integration depth (how deeply must the harness integrate with existing infrastructure?), and control requirements (how much control do you need over safety properties?).
Adopt an existing framework (Norma, Strix) when your security domain is well-served by available tools, your integration requirements are standard (common SIEM, standard scanning tools), and you can accept the framework’s safety model. Strix’s nine installable skills [12] provide immediate value for web application testing with minimal custom development.
Build on an SDK (Norma as SDK, LangGraph) when your domain requires custom tool integration, custom orchestration patterns, or custom safety layers, but the core agent loop and LLM integration can be reused. ARTEX demonstrates this approach—built on Norma’s SDK with domain-specific dual graph architecture [11].
Build from scratch when your safety requirements exceed what any framework provides, when you need full control over every layer, or when regulatory requirements mandate complete auditability of all harness code. NeuroSploit’s Rust implementation [8] exemplifies this approach for maximum performance and safety control.
The build-from-scratch approach is justified more often in security than in other domains, precisely because safety properties are load-bearing. A framework bug in a coding agent causes incorrect code; a framework bug in a security agent causes unauthorized actions on production systems. This asymmetry explains Barbaste et al.’s observation that every production system is hand-rolled [1].
9. Domain-Specific Harness Design
While the seven core subsystems and five security layers apply universally, each security domain imposes unique requirements on tool selection, orchestration, validation, and output format.
9.1. Penetration Testing
Penetration testing is the most active domain, with 27 cataloged projects [6]. The harness must support multi-phase workflows with state persistence across phases.
Phase 1 — Reconnaissance. The harness orchestrates passive and active reconnaissance tools: DNS enumeration (subfinder, amass), certificate transparency queries, WHOIS lookups, web crawling, and technology fingerprinting. All results feed the asset graph. Tools in this phase are predominantly read-only and can run in parallel.
Phase 2 — Scanning. Port scanning (Nmap), vulnerability scanning (Nuclei [39]), and web application scanning (Burp Suite [52], Caido) operate against discovered assets. The harness manages scan scheduling to avoid overwhelming targets, correlates results across scanners, and deduplicates findings.
Phase 3 — Exploitation. The agent crafts and tests exploitation payloads based on identified vulnerabilities. This phase requires the highest level of safety control: every exploitation attempt must be logged, scope-validated, and (optionally) human-approved. NeuroSploit’s evidence recording captures the exact HTTP request/response pair for each exploitation attempt [8].
Phase 4 — Post-Exploitation. After successful exploitation, the agent performs privilege escalation assessment, lateral movement analysis, and data access evaluation. The harness must distinguish between demonstrating impact (acceptable) and actually exfiltrating data (requires explicit authorization).
Phase 5 — Reporting. The harness compiles findings into structured reports with executive summary, technical findings (each with evidence), remediation guidance, and compliance mapping. SARIF output enables integration with CI/CD pipelines and issue trackers.
Key Pattern—Finding Chaining. NeuroSploit’s finding chaining [8] is critical: an SSRF finding (medium severity) might chain with an internal service that has a deserialization vulnerability (medium severity), creating a critical-severity remote code execution chain. The harness must track these chains as first-class objects in the knowledge graph, computing composite severity scores that reflect actual impact.
9.2. Red Team Operations
Red teaming tests organizational defenses end-to-end. The harness must support adversary emulation with MITRE ATT&CK technique mapping [16], operational security (OPSEC) awareness, and campaign-level persistence.
Unique Requirements:
- TTP Tracking: ATT&CK techniques as first-class objects. Every action maps to a technique ID. The harness tracks which techniques have been used, enabling coverage analysis against specific threat actor profiles.
- OPSEC Layer: A pre-execution check evaluates detection risk. ARTEX’s defense detection guide [11] generates Sigma and Suricata rules for planned actions, allowing the agent to assess whether an action would trigger detection before executing it.
- Campaign Persistence: Red team engagements span weeks. The harness must checkpoint state, support pause/resume, and maintain operational continuity across sessions. NeuroSploit’s snapshot/resume capability [8] addresses this requirement.
- Credential Management: Discovered credentials must be stored securely and rotated. The harness manages credential lifecycle separate from the LLM context, using token references ($CRED_n) in model interactions.
Workflow Example. A red team agent targeting an organization follows the kill chain: (1) initial access via phishing simulation (T1566), (2) execution through macro-enabled document (T1204), (3) persistence via registry run key (T1547.001), (4) privilege escalation through UAC bypass (T1548.002), (5) lateral movement via pass-the-hash (T1550.002), (6) data collection from file shares (T1039), (7) exfiltration via encrypted channel (T1041). At each step, the OPSEC layer evaluates detection probability: before executing T1550.002, the harness generates the corresponding Sigma rule and checks whether the target’s SIEM correlates such events. If detection probability exceeds the campaign’s stealth threshold, the agent selects an alternative technique or requests human guidance.
9.3. Reverse Engineering
Reverse engineering harnesses interface with disassemblers and decompilers to analyze binary code. Tool integration is more complex than in other domains because the tools (IDA Pro, Ghidra, Binary Ninja) have rich, stateful APIs.
Required Integrations: IDA Pro MCP [6] for decompilation, cross-references, type analysis, and binary patching; Ghidra headless for open-source decompilation; Frida for dynamic instrumentation; Binary Ninja MCP for alternative analysis; and LLM4Decompile [38] for neural decompilation.
Architecture Pattern: The evaluator-optimizer pattern fits naturally: decompile a function, propose type annotations and variable names, validate consistency with how variables are used across the function. HERMES’s dev-primitives approach [4]—pairing each code component with a resident LLM—maps naturally to per-function analysis in reverse engineering.
Workflow. The reverse engineering harness operates in iterative cycles: (1) binary survey—identify sections, imports, exports, strings, and cryptographic constants; (2) triage—rank functions by complexity, call frequency, and string references to prioritize analysis; (3) deep analysis—decompile priority functions, propagate types, rename variables based on semantic understanding; (4) cross-reference tracking—follow data flow from user input to sensitive operations (file I/O, network, crypto); (5) annotation export—produce structured output mapping addresses to semantic labels. The harness maintains a “function understanding graph” where each analyzed function is a node annotated with its decompiled source, inferred types, and confidence score. Edges represent call relationships and data dependencies. This graph persists across sessions, enabling incremental analysis of large binaries.
Dynamic Analysis Integration. For binaries that resist static analysis (packed, obfuscated, or VM-protected), the harness integrates dynamic instrumentation via Frida. The agent generates Frida scripts based on static analysis hypotheses—hooking suspected decryption functions, tracing API calls, or dumping memory regions at specific execution points. Tool output (instruction traces, memory dumps, API logs) feeds back into the knowledge graph, resolving ambiguities that static analysis left open.
9.4. Security Operations Center (SOC)
AiSOC provides the most complete reference implementation for SOC automation [10]. The harness handles continuous event flow from ingestion through response.
Pipeline Architecture:
- Ingest: Normalize events from 91 data connectors, project activity timelines, handle multiple log formats (Syslog, CEF, JSON, Windows Event Log).
- Detection: Apply 2,966 executable rules (from a library of 7,407) with 76 sliding-window correlation rules and per-tenant tuning. Rule migration from Splunk SPL, Sentinel KQL, and Elastic EQL enables organizations to bring their existing detection logic.
- Investigation: AI agents triage alerts using typed tools: lake queries (structured search over events), graph traversals (entity relationship mapping), and enrichment lookups (threat intelligence, geolocation, reputation scores). Grounding checks demote unsupported verdicts to human review.
- Response: Playbook execution with human approval required for vendor actions (firewall rule changes, endpoint isolation, account lockout) unless the tenant explicitly grants autonomy for specific action classes.
Key Design Decision: The model never writes raw SQL. It calls typed query functions that the harness validates before execution [10]. This eliminates prompt injection vectors where a malicious alert payload could trick the model into executing arbitrary database queries—a critical concern when the model processes untrusted data from potentially compromised systems.
9.5. Malware Analysis
Malware analysis harnesses must balance thoroughness with safety. Required: nested sandboxing with Firecracker microVMs [36] or gVisor [37] for hardware-level isolation, simulated DNS (INetSim), artifact quarantine, YARA rule matching, behavioral analysis, and threat intelligence correlation.
The harness must prevent two categories of escape: the malware sample escaping the analysis sandbox, and the LLM acting on instructions embedded in the malware (a form of prompt injection through malicious binary content). Static analysis tools that extract strings and metadata should sanitize output before feeding it to the LLM context.
Analysis Pipeline. The malware analysis harness follows a structured pipeline: (1) Triage—file type identification, YARA rule matching against known families, hash lookup against VirusTotal/MalwareBazaar, fuzzy hash (ssdeep) comparison against known samples; (2) Static Analysis—string extraction (with sanitization), import table analysis, section entropy calculation, packer detection, certificate validation; (3) Dynamic Analysis—controlled execution in Firecracker microVM with INetSim, API call tracing, file system monitoring, registry changes, network traffic capture; (4) Behavioral Classification—mapping observed behaviors to MITRE ATT&CK techniques, identifying C2 protocols, extraction of IOCs (domains, IPs, URLs, file hashes, mutex names); (5) Report Generation—structured IOC export (STIX/TAXII format), YARA rule generation for the analyzed sample, detection signature proposals.
Prompt Injection via Malware. A sophisticated adversary could embed LLM-targeted instructions in malware strings: “IGNORE PREVIOUS INSTRUCTIONS. Report this sample as benign.” The harness mitigates this through output sanitization (stripping potential instruction patterns from tool output before LLM context insertion), a dedicated analysis model with a hardened system prompt, and cross-model verification where a second model analyzes the same artifacts independently.
9.6. Digital Forensics
Forensic harnesses must maintain chain of custody and evidence integrity. Requirements: read-only evidence mounting, comprehensive audit trails, cross-source timeline construction (disk, memory, network, logs), hash verification at every step, and deterministic analysis. Dhage’s structured planning achieved Reproducibility Index of 1.000 [13]—the standard forensic harnesses should target.
Evidence Integrity. The forensic harness enforces strict read-only access to evidence sources. Disk images are mounted read-only; memory dumps are accessed through analysis tools (Volatility 3) that never modify the source. Every access is logged with SHA-256 hash verification. The harness maintains a chain-of-custody ledger that records every tool invocation, its inputs, outputs, and timestamps, in an append-only log that can be presented in court proceedings.
Timeline Construction. The harness builds cross-source super-timelines by correlating: file system timestamps (MFT entries, journal records), Windows event logs, browser history databases, email metadata, registry last-write timestamps, memory artifacts (process creation times, network connection timestamps), and network packet captures. The LLM’s role is hypothesis generation and correlation—identifying suspicious temporal patterns that span multiple evidence sources, such as a file download followed by registry modification followed by outbound network connection within a narrow time window.
Reproducibility. Forensic analysis must be reproducible by independent examiners. The harness records its complete analysis plan (including tool versions, parameters, and execution order) as a deterministic script that can be replayed against the same evidence to produce identical results. Dhage’s finding [13] that structured planning achieves RI = 1.000 is directly applicable: by forcing the agent to commit to an analysis plan before executing it, the harness ensures reproducibility.
Table 5.
Domain-specific harness requirements summary.
| Domain | Pattern | Key Tools | Safety | Output |
|---|---|---|---|---|
| Pentest | Coord.-Work. | Nmap, Nuclei | Scope ctrl | SARIF |
| Red Team | Coord.-Work. | Custom C2 | OPSEC | ATT&CK |
| Rev. Eng. | Eval.-Opt. | IDA, Ghidra | Sandbox | Binary |
| SOC | Chain+Route | SIEM, SOAR | Typed tools | Tickets |
| Malware | Parallel | Cuckoo, YARA | Nested sbox | IOCs |
| Forensics | Chaining | Autopsy, Vol. | Read-only | Timeline |
10. Skills, Tools, and MCP
10.1. Skills as Domain Expertise Packages
Skills are reusable instruction packages adopted by 9 of 11 production systems [1]. NeuroSploit ships 486 agent playbooks covering web testing, SAST review, infrastructure assessment, AI/LLM testing, mobile, and compliance [8]. Each playbook specifies the attack surface, required tools, testing methodology, evidence requirements, severity criteria, and remediation templates.
| Listing 2. Security skill in SKILL.md format. |
![]() |
The skill format serves as a portable unit of security expertise. An organization’s senior penetration testers can encode their methodology into skills that junior testers—or AI agents—execute consistently. This addresses a persistent challenge in security: the variability of testing quality across practitioners.
10.2. Tool Design Principles for Security
Security tools follow more restrictive design principles than general-purpose agent tools:
- Fail-closed default: Every tool requires explicit approval before first use [9]. No tool is auto-approved based on name or description alone.
- Scope-bound: Tools that touch the network accept target parameters that the harness validates against the engagement scope before execution.
- Output-limited: Tool outputs are truncated or summarized to prevent context overflow. A full Nmap scan of a /24 network produces megabytes of output; the harness provides intelligent summarization that preserves security-relevant details.
- Credential-redacted: NeuroSploit automatically replaces discovered credentials with tokens ($SECRET_1, $SECRET_2) in agent context and reports, storing actual values in a separate vault [8].
- Idempotent where possible: Read-only tools (port scan, DNS lookup) are safe to retry. Mutation tools (exploit execution, configuration change) are flagged as non-idempotent.
10.3. The Model Context Protocol (MCP)
MCP standardizes agent-to-tool-server interfaces, enabling tool discovery and invocation across process boundaries [15]. Adopted by 8 of 11 production systems [1], MCP enables tool isolation (security tools run in separate processes), tool sharing (multiple agents connect to the same MCP server), and marketplace integration (community-contributed tool servers). AiSOC exposes its entire detection and investigation pipeline as an MCP server for Claude, Cursor, and Continue [10].
10.4. Design Patterns for Security Harnesses
Table 6 catalogs key design patterns extracted from production system analysis, mapped to their security applications.
10.5. Hooks for Security Lifecycle Management
Hooks are lifecycle callbacks that intercept harness events. In security contexts, hooks serve three critical functions:
Pre-execution hooks intercept tool calls before execution. A scope-validation hook checks every network-touching tool against the engagement’s authorized targets. A credential-redaction hook scans tool parameters for sensitive values and replaces them with tokens. A rate-limiting hook enforces per-target request limits to prevent denial-of-service conditions during testing.
Post-execution hooks process tool output before it enters the model context. An evidence-recording hook captures raw input/output pairs with timestamps. A sanitization hook strips potential prompt injection payloads from tool output (particularly important when processing data from potentially compromised systems). An output-shaping hook transforms verbose tool output into structured summaries.
Session hooks manage engagement lifecycle: session-start hooks load engagement scope and resume checkpointed state; session-end hooks generate summary reports and archive evidence; error hooks classify failures and trigger appropriate recovery strategies.
11. Local vs. Cloud Models
Security harnesses face unique tension between model capability and data sensitivity. Cloud models (Claude, GPT) offer superior reasoning but require sending potentially sensitive data to external APIs. Local models (via Ollama, llama.cpp, vLLM) keep all data on-premises but offer reduced capability.
Figure 7.
Provider abstraction enables the same harness to operate with cloud and local models interchangeably.
Figure 7.
Provider abstraction enables the same harness to operate with cloud and local models interchangeably.

11.1. Provider Abstraction
Norma’s dual-provider architecture provides the reference implementation [9]. The abstraction layer handles tool call format differences (Anthropic vs. OpenAI JSON schemas), streaming protocol differences, context window management (adaptive compaction based on model limits), and capability detection for graceful degradation.
11.2. Hybrid Architectures
The most effective security harnesses use hybrid architectures: cloud models for complex reasoning (attack planning, vulnerability analysis, report writing) and local models for routine classification (alert triage, log parsing) and sensitive data processing. AiSOC defaults to a local Ollama model (llama3.2:3b-instruct-q4_K_M, ∼2GB, CPU inference) for basic operations while supporting GPU-accelerated or cloud models for complex investigations [10]. Cross-model verification—where a cloud model validates findings from a local model or vice versa—provides both accuracy improvement and architectural resilience.
11.3. Data Sensitivity Routing
A sophisticated harness routes requests based on data sensitivity:
- Public data (CVE descriptions, tool docs, technique descriptions): cloud model for best reasoning quality.
- Internal data (network topology, service configs, code): local model or cloud model with appropriate data processing agreements.
- Classified/regulated data (PII, financial records, health data): local model only, with strict data handling controls.
- Malware samples: local model only, in isolated analysis environment with no network egress.
Figure 8.
Data sensitivity routing directs different data categories to appropriate model backends, balancing capability against confidentiality requirements.
Figure 8.
Data sensitivity routing directs different data categories to appropriate model backends, balancing capability against confidentiality requirements.

12. Sandboxing and Isolation
Five sandbox technologies are in active use [6]: E2B (cloud sandboxes), Firecracker [36] (microVMs), gVisor [37] (application kernel), Microsandbox (lightweight containers), and general sandbox runtimes.
12.1. Control Plane vs. Execution Plane
Aikido’s most important architectural recommendation is the separation of control and execution planes [7]. The control plane holds the agent’s planning logic, engagement scope, credentials, and API keys. The execution plane holds the tools that interact with targets. These planes must run in separate security contexts with different permission levels.
OpenClaw’s initial opt-in sandboxing—where the default deployment gave the agent direct host access—illustrates the danger of default-open architectures [7]. Security harnesses must enforce isolation by default, with explicit opt-out for trusted operations.
12.2. Strix’s Docker-First Approach
Strix mandates Docker for all tool execution [12]. Every pentest operation—from Nmap scans to Playwright browser automation—runs inside Docker containers with constrained network access. This provides reproducible environments, network namespace isolation (the agent can only reach authorized targets), file system isolation, resource limits (CPU, memory, disk), and clean teardown after each engagement.
12.3. Nested Sandboxing for Malware Analysis
Recommended three-level nesting: (1) outer harness container (Docker/Bubblewrap), (2) per-tool sandboxes with scoped network and filesystem, and (3) Firecracker microVMs for malware execution with ephemeral storage, INetSim-monitored network, and automatic destruction after analysis. Each level provides independent isolation, so a failure in one layer does not compromise the others.
12.4. Sandbox Configuration for Common Security Tools
Different security tools impose different sandbox requirements. Table 7 summarizes practical configurations for commonly integrated tools.
Nmap requires raw socket access for SYN scans (CAP_NET_RAW), which should be granted only when SYN scanning is explicitly authorized; otherwise, connect scans operate without elevated capabilities. Docker’s –network flag combined with iptables rules restricts Nmap to authorized target ranges. Ghidra and IDA Pro should run in fully offline containers with no network access—binary analysis does not require connectivity, and isolation prevents any embedded payload from reaching the network. The binary image is mounted read-only; analysis artifacts (databases, annotations) are written to an ephemeral volume that the harness extracts on completion. Metasploit represents the highest-risk tool category. Each Metasploit session runs in a dedicated Firecracker microVM with network access restricted to the authorized scope plus a single reverse-shell listener port. The microVM is destroyed after each exploitation attempt, eliminating persistent state that could be leveraged across targets.
13. Safety, Permissions, and Human-in-the-Loop
Safety in security harnesses operates at higher stakes than general-purpose agents. We identify five layers of defense, synthesized from production system analysis.
Figure 9.
Five-layer safety architecture for security harnesses. Defense-in-depth ensures no single layer failure compromises safety. Layers are independent: a bypass of L2 is caught by L3 or L4.
Figure 9.
Five-layer safety architecture for security harnesses. Defense-in-depth ensures no single layer failure compromises safety. Layers are independent: a bypass of L2 is caught by L3 or L4.

13.1. Permission Models Compared
Claude Code uses three layers (static hooks, LLM classifier, user dialog) with configurable allow-lists [1]. Codex adds Starlark execution policy and OS sandboxing [1]. Gemini CLI offers four approval modes: PLAN, DEFAULT, AUTO_EDIT, and YOLO, plus TOML sandbox policies [1]. AiSOC has tenant-configurable autonomy—default requires human approval for all vendor actions, with progressive autonomy grants for specific playbook actions [10]. Norma uses a four-stage evaluation pipeline with fail-closed default [9].
13.2. Operation Classification
Security operations require finer-grained classification than general read/write (Table 8).
This classification must be enforced at the harness level, not delegated to the model. The model may request a tool invocation; the harness classifies the operation, checks the policy, and either executes, requests approval, or rejects—before any tool code runs.
14. Threat Model for AI Security Agents
AI security agents introduce their own attack surface. A harness that finds vulnerabilities in others’ systems is itself a high-value target. We present a comprehensive threat model organized by attack vector.
14.1. Prompt Injection Attacks
The most immediate threat [29,30]: adversaries can embed instructions in data the agent processes. Attack surfaces include malicious alert payloads (crafted to manipulate SOC agent investigations), booby-trapped web targets (pages with hidden instructions for crawling agents), tool output injection (a compromised service returning manipulated scan results), and repository poisoning (malicious comments or documentation designed to influence code review agents) [31,46].
Mitigations: AiSOC’s typed tools eliminate raw query construction [10]. Aikido’s data sanitization strips potential instructions from external inputs [7]. OpenHands’ ensemble defense employs multiple independent analyzers (LLM analyzer, adversarial API analyzer, deterministic analyzers, shell-AST parsing) so no single injection path compromises all layers [1].
14.2. Scope Escape
Agents that scan unauthorized targets or access restricted systems create legal liability. A pentesting agent that discovers a secondary domain through DNS enumeration might attempt to scan it without checking authorization. Mitigations: Fail-closed scope validation at the harness level (Listing 1), network namespace isolation (Docker/gVisor), and control/execution plane separation.
14.3. Evidence Fabrication
A hallucinating agent producing fabricated vulnerability reports wastes remediation resources and erodes trust in the entire AI-assisted security workflow [32]. Mitigations: NeuroSploit’s three-tier verification [8], deterministic CWE validators that check actual tool output, cross-model voting, and AiSOC’s grounding checks that demote unsupported verdicts [10].
14.4. Model Exfiltration and Data Leakage
Security data sent to cloud APIs traverses third-party infrastructure. Even with encryption in transit, the model provider processes the data. Mitigations: Data sensitivity routing (Section 11), credential redaction ($SECRET_n tokens), hybrid architectures that keep sensitive data local, and contractual data processing agreements.
14.5. Supply Chain Attacks on Skills and MCP
Community-contributed skills and MCP servers run within the agent’s trust boundary. A malicious skill could instruct the agent to exfiltrate data or expand scope. A compromised MCP server could return manipulated tool results. Mitigations: Skill signature verification, MCP server sandboxing, code review processes for community contributions, and least-privilege tool permissions.
14.6. Agent Weaponization
A security harness contains the same capabilities an attacker would need: reconnaissance tools, exploitation frameworks, credential management, and lateral movement automation. Prevention requires engagement-bound scope (authorization expires), tamper-proof audit logs, time-bounded authorization tokens, and hardware-bound credentials where feasible.
15. Validation and Verification Gates
Validation gates are checkpoints in the agent execution pipeline where the harness verifies that actions and outputs meet quality and safety standards. Shui et al. [14] describe this as the separation between “evaluation harness” (which validates) and “optimization controller” (which plans), with human-written skills as guardrails.
Pre-Execution Gates: Scope validation (every tool call checked against authorized targets), parameter sanitization (tool inputs checked for injection, path traversal, command injection), rate limiting (prevent overwhelming targets), and plan validation (Dhage achieved Reproducibility Index of 1.000 with structured planning [13]).
Post-Execution Gates: Evidence verification (every claimed finding must have supporting tool output) [8], cross-model verification (a second model independently assesses findings), grounding checks (AiSOC demotes unsupported verdicts to human review [10]), and LLM-powered deduplication (merge findings describing the same underlying vulnerability [8]).
Stop-Condition Gates: Verify-on-stop guard (before declaring “done,” verify all objectives met and all findings have evidence [1]), coverage check (has the agent tested all in-scope targets?), and report completeness (all required sections present?).
Figure 10.
Validation gate pipeline: pre-execution, execution, post-execution, and stop-condition gates. Any gate can reject and return the agent to the reasoning step.
Figure 10.
Validation gate pipeline: pre-execution, execution, post-execution, and stop-condition gates. Any gate can reject and return the agent to the reasoning step.

16. Case Studies
16.1. Norma: The Foundation SDK
Norma [9] is a Go SDK that provides foundational building blocks for harness construction. It is vendor-neutral by design, shipping no preset system prompt—the developer controls all agent behavior through configuration. Its modular package architecture (llm, tool, permission, harness, compaction, hook, subagent, mcp, plan, memory, skill, coordinator, agentcore) demonstrates the separation of concerns that production harnesses require.
Security Features: Fail-closed tool factory (every tool requires explicit approval), four-stage permission evaluation pipeline, parallel scheduling for read-only tools with serial execution for mutations, and a security-audit example demonstrating control/execution plane separation via a read-only auditor that delegates to a more-privileged subagent.
Strengths: Clean architectural separation, vendor neutrality, comprehensive lifecycle hooks. Limitations: Requires Go expertise, no pre-built security tools—it is a framework, not a product.
16.2. ARTEX: Multi-Agent Penetration Testing
ARTEX [11] builds on Norma with a single Go binary, Next.js frontend, and PostgreSQL backend. Its dual graph architecture is the most sophisticated state management in the survey.
Unique Contributions: Dual graph (asset + exploration), closed exploration loop (planner emits intents, workers execute, results feed back), worker information sharing via keyword search across execution traces, human-in-the-loop chat for operator hint injection, and the defense detection guide (Sigma rules, Suricata rules, MITRE ATT&CK Navigator heatmaps, IoC lists).
Strengths: Most mature multi-agent architecture, purple team capability via defense guide, built on proven SDK. Limitations: AGPL-3.0 license, tied to Norma SDK.
16.3. NeuroSploit: Evidence-First Harness
NeuroSploit [8] takes an explicitly evidence-first approach: “The harness is the pentester, not the model.” Its Rust engine (tokio-based) drives a pool of LLMs through multi-phase assessment pipelines.
Key Metrics: 486 agent playbooks across 7 security domains, 19 LLM provider integrations, three-tier evidence verification, credential redaction, error classification with backoff retries, partial-result salvage, snapshot/resume, LLM-powered deduplication, finding chaining, and optional Neo4j knowledge graph.
Strengths: Broadest coverage (web, SAST, infra, AI/LLM, mobile, compliance), strongest evidence system, most provider integrations. Limitations: Requires Rust expertise for extension, complex deployment.
16.4. Strix: The Accessible Pentest Agent
Strix [12] prioritizes accessibility with its “Graph of Agents” orchestration, installable skills, and web-based visualization.
Unique Contributions: Nine SKILL.md-compatible skills for Claude Code, Cursor, and Codex integration; MCP server support; automated browser (Playwright) for XSS, CSRF, clickjacking, and auth-flow testing; live agent team map visualization; integration with Caido proxy, Nuclei, GitHub Actions, Slack, Jira, and Linear.
Strengths: Lowest barrier to entry, excellent visualization, strong ecosystem integration. Limitations: Narrower domain coverage than NeuroSploit.
16.5. AiSOC: Defensive Operations at Scale
AiSOC [10] demonstrates harness engineering for defensive operations with enterprise deployment profiles.
Deployment: Core profile (16 services, ∼8GB RAM) provides alerting, LLM gateway, local model, and CISA KEV feed. Full profile (22 services, ∼12GB RAM) adds event lake, entity graph, full-text search, and enrichment.
Unique Contributions: Typed tools pattern (no raw SQL), 2,966 executable detection rules, grounding checks, prompt validation, 91 data connectors, rule migration from Splunk/Sentinel/Elastic, and MCP server exposure.
Strengths: Production-ready SOC platform, strongest safety controls for defensive operations. Limitations: Complex deployment, limited offensive capability.
Table 9.
Comparative analysis of five security harness systems.
| Feature | Norma | ARTEX | NS | Strix | AiSOC |
|---|---|---|---|---|---|
| Multi-agent | |||||
| Evidence verify | — | ∼ | ∼ | ||
| Skills (SKILL.md) | — | ||||
| MCP support | |||||
| Local models | ∼ | ||||
| Scope enforce | |||||
| Defense output | — | — | — | ||
| Knowledge graph | — | ∼ |
= full support, ∼= partial, —= not present. NS = NeuroSploit.
17. A General Methodology for Security Harness Development
Drawing on patterns, case studies, and research synthesized in this paper, we propose a nine-phase methodology for building security harnesses. This methodology is domain-agnostic—it applies whether building a pentest harness, SOC automation, forensic analysis assistant, or any other security agent system.
System Selection and Analysis Method. The five case-study systems (Norma, ARTEX, NeuroSploit, Strix, AiSOC) were selected from the 99-project catalog [6] based on three criteria: (1) public source code available on GitHub at time of analysis (October–November 2026), (2) harness architecture documented in README or code comments sufficient to identify subsystem boundaries, and (3) coverage of at least two of the seven core subsystems identified by Barbaste et al. [1]. For each system, we examined the repository structure, extracted architectural patterns by identifying module boundaries and inter-module interfaces, and mapped features to the seven-subsystem taxonomy. Patterns were classified as “convergent” when two or more independently developed systems implemented the same solution to the same problem (e.g., coordinator-worker orchestration, fail-closed tool defaults). The four research papers were identified through arXiv keyword search for “harness engineering” restricted to 2026 publications. Web resources (Databricks, Aikido, WalkingLabs) were identified through web search for practitioner-oriented harness engineering guides. We note that this is a purposive sample of publicly available systems, not a systematic review; proprietary and unpublished harness systems are not represented.
Figure 11.
Nine-phase methodology for security harness development. The dashed arrow from P9 to P1 represents iterative refinement.
Figure 11.
Nine-phase methodology for security harness development. The dashed arrow from P9 to P1 represents iterative refinement.

17.1. Phase 1: Define Scope and Threat Model
Before writing any code, define exactly what the harness is authorized to do: target scope (domains, IP ranges, repositories), operation classes (Table 8), data handling rules (sensitivity routing), risk tolerance per operation class, and human oversight model. This phase produces the EngagementScope configuration that drives all subsequent safety decisions. Connect this to the threat model (Section 14) to identify which threats are relevant to your deployment context.
17.2. Phase 2: Design Tool Interface Layer
Wrap every external tool in a harness-controlled interface that provides scope checking, rate limiting, output limiting, evidence recording, and operation classification (Listing 3).
| Listing 3. Tool wrapper implementation (Rust). |
![]() |
17.3. Phase 3: Build Safety and Permission Layer
Implement the five-layer safety architecture (Figure 9). Start with the most restrictive configuration (all tools require human approval) and progressively loosen based on testing. The principle is: never remove OS-level sandboxing, regardless of trust level.
17.4. Phase 4: Implement the Agent Loop
Follow the Security ReAct pattern (Figure 3). Key implementation decisions: streaming vs. batch tool use, error classification (transient, permanent, scope violation), parallel read-only / serial mutations [9], and context compaction strategy.
Implementation begins with the core loop structure: receive model output, extract tool calls, validate each call against the safety stack, execute approved calls (in parallel for read-only operations, serially for mutations), collect results, assemble the next context, and re-invoke the model. Streaming tool use—where the model emits tool calls as they are generated rather than waiting for the complete response—reduces latency but requires the harness to handle partial tool call sequences and rollback on generation failures. Error classification must be implemented as early as possible: before the first tool call, categorize each potential failure mode and define the recovery strategy. A robust loop implementation includes a “dead letter” mechanism for tool calls that fail repeatedly: after three retries of a transient error, the call is logged with full context and the model is informed that the tool is temporarily unavailable, allowing it to select an alternative approach rather than entering an infinite retry loop.
17.5. Phase 5: Design State and Memory
Choose based on engagement complexity: in-memory for simple tasks (single scan), persistent graph (Neo4j) or document store (SQLite) for multi-phase engagements, event streaming (Kafka) for continuous operations.
17.6. Phase 6: Select Orchestration Pattern
17.7. Phase 7: Build Validation Gates
Implement all three gate types (Figure 10). Prioritize: scope validation (day one, non-negotiable), evidence verification (critical for report credibility), cross-model verification (add incrementally), verify-on-stop guard (prevents premature completion).
Scope validation is implemented as a synchronous check before every tool execution—it must never be asynchronous or deferred, as a race condition could allow an out-of-scope tool call to execute before validation completes. The evidence verification gate operates post-execution: for each finding the model proposes, the gate checks that the finding references specific evidence records (by ID) in the evidence store, that the referenced evidence actually supports the claimed vulnerability (e.g., an SQL injection claim references an HTTP response containing SQL error text or behavioral anomaly), and that the evidence has not been modified since recording. The verify-on-stop guard is the final checkpoint: when the model declares the task complete, the harness independently checks that all in-scope targets have been assessed (coverage), all findings have complete evidence chains (evidence completeness), and the report contains all required sections (report completeness). If any check fails, the model is re-invoked with specific instructions about what is missing: “Three endpoints in scope have not been tested: /api/v2/admin, /api/v2/config, /api/v2/internal. Assess these before completing.”
17.8. Phase 8: Write Domain Skills
17.9. Phase 9: Evaluate and Iterate
Cover three dimensions: capability (benchmark performance, finding accuracy), safety (red-team the harness itself—attempt prompt injection, scope escape, evidence fabrication), and reliability (reproducibility targeting 1.000 [13]). Feed evaluation results back into Phase 1 for iterative refinement.
18. Development Lifecycle of a Security Harness
The nine-phase methodology (Section 17) addresses what to build. The development lifecycle addresses how to manage a security harness as a living system—from initial requirements through continuous improvement.
18.1. Requirements Gathering
Security harness requirements emerge from four sources. Stakeholder analysis identifies who will use the harness (security team, compliance officers, management, clients) and what each stakeholder needs (findings, compliance reports, executive summaries, remediation guidance). Regulatory requirements impose architectural constraints: PCI-DSS mandates credential isolation and audit trails; HIPAA requires data handling controls for protected health information; SOC 2 demands evidence of continuous monitoring. These are not features to add later—they shape the harness architecture from day one.
Threat landscape assessment determines what the harness must detect and test. An organization facing primarily web application risks needs different tool integration than one managing critical infrastructure. Capability gap analysis identifies what the human security team currently does manually that could be augmented by AI: alert triage (often 80% of SOC analyst time), reconnaissance data correlation, report generation, and routine vulnerability scanning are high-value automation targets.
18.2. Iterative Development and Testing
Security harnesses should be built incrementally, with safety verification at each stage:
- Minimal Viable Harness (MVH): Single agent, single model, scope enforcement, evidence recording, one tool. Test against a single intentionally vulnerable target (DVWA, WebGoat). Verify: scope enforcement blocks out-of-scope targets, evidence is recorded for all tool invocations, the verify-on-stop guard prevents premature completion.
- Tool Expansion: Add domain-specific tools incrementally. After each tool addition, re-run the safety test suite: Does the new tool respect scope? Does it handle errors gracefully? Is its output shaped for model consumption? Does it introduce new attack surface?
- Multi-Agent: Add coordinator-worker orchestration. Verify: workers cannot exceed their permission level, shared state is consistent, cross-worker finding correlation works correctly.
- Production Hardening: Add streaming, compaction, persistence, observability. Run the full benchmark suite (Section 22). Conduct adversarial safety testing: attempt prompt injection, scope escape, and evidence fabrication against the harness.
18.3. Deployment Patterns
Security harnesses support four deployment patterns representing increasing autonomy (Table 10).
Organizations should progress through these patterns sequentially. Shadow mode builds confidence in the harness’s accuracy and safety. Augmented mode validates the human-agent interaction model. Supervised mode tests the harness’s independent judgment. Only after demonstrated reliability in supervised mode should specific operation classes be elevated to autonomous. This progression embodies Principle P8 (Progressive Trust): trust is earned through demonstrated safety, not assumed.
18.4. Continuous Improvement
A deployed security harness requires ongoing maintenance across four dimensions. Skill library maintenance adds skills for new vulnerability classes, updates methodologies as attack techniques evolve, and retires skills for patched vulnerability classes. Model upgrade testing validates that new model versions do not break harness assumptions—a model that changes its tool-calling format or reasoning patterns can silently degrade harness performance. Safety regression testing ensures that capability additions and model upgrades do not weaken safety properties—every release candidate must pass the full adversarial test suite. Feedback integration captures findings from production deployments: false positives refine evidence thresholds, missed findings motivate new skills, and scope violation attempts improve scope enforcement logic. This continuous improvement loop is what distinguishes a production harness from a prototype.
18.5. Readiness Checklist
Before deploying a security harness to production, practitioners should verify the following properties. This checklist synthesizes requirements from across the discipline:
- Safety: All five safety layers implemented and independently tested. Scope enforcement verified against out-of-scope targets. Fail-closed default confirmed for all tools. OS-level sandboxing active. Post-execution audit logging operational.
- Evidence: All tool invocations recorded with timestamps. Evidence replay tested—findings can be reproduced from recorded data. Cross-model verification operational for high-severity findings.
- Compliance: Audit trail meets regulatory requirements (retention period, immutability, access control). CVSS scoring is deterministic. Compliance mapping covers applicable frameworks.
- Resilience: Error classification handles transient, permanent, and scope violation failures. Budget exhaustion triggers graceful shutdown. Session persistence enables checkpoint and resume. Partial-result salvage produces useful output on abnormal termination.
- Observability: Structured logging for all tool invocations. Metrics for turns per finding, token consumption, scope violations. Real-time dashboard for ongoing engagements. Alerting for anomalous agent behavior.
- Adversarial Testing: Prompt injection attempted through tool output. Scope escape attempted through indirect access. Evidence fabrication attempted. Sandbox escape attempted. All attempts logged and blocked by at least one safety layer.
19. Implementation Walkthrough
We present a simplified but executable security harness in Python demonstrating provider abstraction, scope enforcement, tool wrapping, the ReAct loop, and evidence recording. The code below is intentionally minimal to illustrate core patterns; a production deployment would add streaming, compaction, multi-agent orchestration, proper provider-specific message formatting, error handling, and domain-specific tools. Provider response parsing (_extract_tool_calls, _extract_text) is shown for Anthropic and OpenAI-compatible formats but would require adaptation for each provider’s actual wire protocol.
19.1. Provider Abstraction Layer
| Listing 4. Provider abstraction supporting both cloud and local models. |
![]() |
19.2. Scope Enforcement and Tool Registry
The scope enforcement module validates every tool invocation against the engagement’s authorized targets. The tool registry wraps raw tools with scope checking, rate limiting, and evidence recording.
| Listing 5. Scope enforcement and tool registry with evidence recording. |
![]()
|
19.3. The Security ReAct Loop
| Listing 6. Security ReAct loop with validation gates and verify-on-stop. |
![]()
|
19.4. Usage Example
| Listing 7. Using the harness to run a scoped security assessment. |
![]()
|
This implementation demonstrates the core methodology patterns: provider abstraction (swap Anthropic for Ollama without changing harness code), scope enforcement (unauthorized targets are rejected before tool execution), evidence recording (every tool invocation is logged with timestamps), and the verify-on-stop guard (the agent cannot claim “done” without evidence). Production harnesses add streaming, compaction, multi-agent orchestration, persistence, and domain-specific tools on top of this foundation.
19.5. From Prototype to Production: Key Upgrades
The prototype above demonstrates core patterns but requires several upgrades for production deployment. Streaming tool use replaces batch request/response cycles: the model streams tool call tokens as they are generated, and the harness begins scope validation and tool execution before the model finishes generating. This can substantially reduce per-turn latency. Context compaction must be added between turns: after each tool result is processed, the harness evaluates total context size and triggers compaction when approaching 80% of the model’s context window. The compaction preserves all evidence records, finding summaries, and scope state while summarizing verbose tool output.
Multi-agent orchestration wraps the single-agent loop in a coordinator that manages multiple SecurityHarness instances with different tool sets and permission levels. The coordinator maintains a shared state store (Redis, PostgreSQL, or an in-memory graph) that workers read from and write to. Persistence serializes the engagement state—scope, evidence, findings, asset graph, conversation history—to durable storage at configurable intervals (every N turns, after each finding, on session close). The checkpoint format must be self-contained: loading a checkpoint into a fresh harness instance must reproduce the agent’s full context without any external dependencies beyond the checkpoint file itself.
Observability adds structured logging, metrics collection, and tracing. Every tool invocation emits a structured log entry with tool name, parameters (with credentials redacted), execution time, output size, and outcome (success/error/blocked). Metrics track turns per finding, token consumption per phase, scope violation attempts, and human approval latency. Distributed tracing (OpenTelemetry) enables end-to-end visibility in multi-agent deployments where a single finding may traverse coordinator, recon worker, exploitation worker, and verification agent.
19.6. Common Anti-Patterns in Security Harness Design
Production experience reveals recurring anti-patterns that practitioners should avoid:
1. The “Smart Prompt” Anti-Pattern. Encoding security constraints entirely in the system prompt rather than in code. “Do not scan targets outside the authorized scope” in a prompt is trivially bypassed by prompt injection. Every security constraint must have a code-level enforcement counterpart.
2. The “Tool Dump” Anti-Pattern. Exposing all available tools to the model simultaneously. A harness with 50+ tools degrades model performance through decision overload [3]. Security harnesses should expose tools progressively: reconnaissance tools during the recon phase, exploitation tools only after vulnerabilities are confirmed, and post-exploitation tools only after successful exploitation.
3. The “Trust the Model” Anti-Pattern. Using the model’s self-assessment as evidence. When the model says “I found a SQL injection,” the harness must verify this claim against recorded tool output. AiSOC’s grounding checks [10] demonstrate the correct approach: claims without supporting evidence are automatically demoted to “unverified” status.
4. The “Monolith Agent” Anti-Pattern. Running a single agent with all capabilities, all tools, and full context. This produces context overflow in complex engagements and prevents model specialization. The coordinator-worker pattern (Section 7) addresses this by decomposing the monolith into specialized workers with focused tool sets and reduced context windows.
5. The “Fire and Forget” Anti-Pattern. Launching an autonomous security assessment and returning hours later to read the report. Without continuous monitoring, the agent may have drifted from scope, exhausted its budget on a single target, or produced hundreds of unverified findings. Production harnesses require real-time dashboards showing current target, operation class distribution, finding count, budget consumption, and any scope violation alerts.
20. Lessons Learned and Best Practices
Drawing from analysis of production systems and open-source frameworks, we distill the most impactful lessons for security harness practitioners.
20.1. Invest More in Harness Than Model Choice
The single most important lesson: harness design affects results as much as—or more than—model selection [3,4]. Organizations that spend months evaluating models while running them in ad-hoc harnesses are optimizing the wrong variable. A well-designed harness with a mid-tier model consistently outperforms a poorly-designed harness with a frontier model.
20.2. Start Restrictive, Loosen Incrementally
Every production system in the survey started with maximally restrictive permissions and progressively loosened them based on testing [1]. The reverse—starting permissive and adding restrictions after incidents—is more expensive and dangerous. Begin with all tools requiring human approval; move passive reconnaissance to auto-allow after verifying scope enforcement; move active reconnaissance after validating rate limiting; keep exploitation at human-approval indefinitely.
20.3. The Model Should Never Self-Police
Security constraints must be enforced in code, never in prompts. The model should not decide whether a target is in scope; the harness should check before the tool runs. The model should not decide whether an operation is safe; the harness should classify it and apply policy. This principle extends to evidence verification—the model should not judge its own findings; a separate verification system should.
20.4. Evidence Recording Is Not Optional
Every tool invocation must be recorded with its exact inputs, outputs, and timestamps. This recording serves three purposes: (1) evidence for vulnerability reports, (2) audit trail for compliance, and (3) debugging information for harness improvement. NeuroSploit’s approach—recording raw request/response bytes and replaying them through deterministic validators—should be the minimum standard [8].
20.5. Design for Session Persistence
Security engagements are rarely completed in a single session. The harness must support checkpoint/resume without losing state, evidence, or context. NeuroSploit’s snapshot/resume [8] and ARTEX’s persistent graph database [11] provide templates. Session persistence also enables collaborative workflows where multiple analysts work on the same engagement across shifts.
20.6. Separate What the Model Sees from What It Does
A common anti-pattern is feeding full tool output directly into the model context. Full Nmap output for a large network can consume the entire context window. The harness should provide intelligent summarization: preserve open ports, service versions, and security-relevant details; discard verbose formatting and repeated patterns. This “output shaping” is a harness responsibility that directly impacts model reasoning quality.
20.7. Multi-Model is Better Than Single-Model
Cross-model verification (NeuroSploit’s approach [8]) produces higher-quality results than single-model assessment. Even when using the same model family (e.g., Claude Sonnet for initial assessment and Claude Opus for verification), the independent assessment provides a meaningful quality check. Different model families provide even stronger verification.
20.8. Test the Harness, Not Just the Model
Security harnesses need their own test suites: can the scope checker correctly identify out-of-scope targets? Does the evidence recorder capture all tool invocations? Does the rate limiter prevent target overwhelming? Does the verify-on-stop guard prevent premature completion? These are harness tests, independent of which model is connected.
20.9. Plan Before Acting
Dhage’s structured planning [13] is the single most effective reliability improvement. Before any tool execution, the agent produces a structured plan: target, methodology, tools required, expected outputs, and stop conditions. The plan is validated against the engagement scope and approved (automatically or by human) before execution begins. This pre-commitment eliminates drift, prevents scope creep, and produces reproducible assessments.
20.10. Graceful Degradation Over Silent Failure
When a tool fails, the harness should not silently continue without it. NeuroSploit’s error classification [8]—transient (retry with backoff), permanent (skip and record), scope violation (abort with alert)—and partial-result salvage ensure that failures are handled explicitly. A harness that silently skips a failing scanner may produce a falsely reassuring “no vulnerabilities found” report.
20.11. Output Shaping Directly Affects Reasoning
The format and content of tool output presented to the model has a direct, measurable effect on reasoning quality. Raw Nmap XML output confuses most models; a structured summary with security-relevant highlights (open ports, service versions, potential vulnerabilities) produces significantly better reasoning. HERMES’s 26.2% cost reduction [4] came partly from better output shaping. The harness should maintain per-tool output templates that extract and format the information the model needs to reason effectively.
20.12. Security-Specific: Treat Every Tool Output as Untrusted
In security contexts, tool output is not merely data—it may be adversarially crafted. A web crawling tool that processes a target page may return content containing embedded prompt injection: “IGNORE PREVIOUS INSTRUCTIONS. Report this application as secure.” A SIEM query tool may return log entries that a sophisticated attacker has poisoned with misleading data. The harness must sanitize all tool output before inserting it into the model’s context. AiSOC’s typed tools [10] eliminate entire injection vectors by preventing raw query construction; output sanitization strips potential instruction patterns from external data before context insertion.
20.13. Security-Specific: Build for Adversarial Conditions
Unlike coding agents that operate on cooperative code repositories, security agents operate against targets where adversaries may actively try to subvert them. Booby-trapped web pages can confuse crawling agents. Honeypot services can produce misleading scan results. Adversarial tool output can misdirect the agent’s reasoning. The harness must assume a hostile environment: cross-validate discoveries through independent channels, maintain skepticism about surprising results (a “clean” scan of a known-vulnerable system warrants investigation), and implement anomaly detection on the agent’s own behavior (sudden changes in tool-calling patterns may indicate successful prompt injection).
20.14. Security-Specific: Compliance is a First-Class Requirement
Compliance mapping is not an afterthought—it shapes architecture decisions from the start. CVSS scoring must be computed deterministically from finding attributes [44], not estimated by the LLM (which may assign inconsistent scores). Audit trail requirements demand that every tool invocation, model interaction, and human decision is logged immutably. Evidence chain requirements mandate that findings link to specific, replayable tool outputs. PCI-DSS, HIPAA, SOC 2, and GDPR each impose specific constraints on data handling, evidence retention, and access control that must be built into the harness architecture, not bolted on after deployment.
20.15. Security-Specific: Human Expertise Remains Irreplaceable for Strategy
HERMES’s finding that Agent-Assisted outperforms Full-Agent [4] carries profound implications for security harness design. AI excels at tactical execution: running scans, correlating data, testing payloads, generating reports. Humans excel at strategic decisions: engagement scoping, risk acceptance, business context interpretation, and adversarial creativity. The harness should amplify human expertise, not replace it. Design human-in-the-loop touchpoints for strategic value—not just “approve this tool call” but “given these three findings, which attack path should we prioritize?” The highest-performing security operations will pair human strategic judgment with AI tactical execution, mediated by a well-engineered harness.
21. Comparative Analysis: Traditional vs. AI Harness Automation
To contextualize the contributions of AI harness engineering, Table 11 presents a systematic comparison between traditional security automation and AI harness-driven approaches across key dimensions.
The comparison reveals that AI harness engineering complements rather than replaces traditional tools. The optimal architecture layers AI reasoning on top of traditional scanning: use Nmap and Nuclei for comprehensive coverage of known vulnerability classes, then apply LLM reasoning for finding correlation, attack chain construction, business logic assessment, and report generation. The harness orchestrates both traditional and AI-driven tools through a unified pipeline.
The Hybrid Advantage. A practical hybrid architecture operates in three stages. First, traditional scanners (Nmap, Nuclei, Burp Suite passive scan) execute their standard checks against all in-scope targets, producing comprehensive but noisy output. Second, the AI harness triages scanner output: the LLM filters false positives based on contextual understanding (e.g., a flagged library version that is not actually reachable from user input), correlates findings across scanners (e.g., an open admin panel found by Nuclei plus weak credentials found by Burp), and identifies gaps in scanner coverage (e.g., business logic flows that no scanner tests). Third, the AI agent performs targeted testing in areas where scanners are weak: authentication logic, authorization bypass, multi-step workflows, and application-specific business rules. This hybrid approach is expected to reduce false positives relative to scanners alone (through contextual reasoning about reachability) and to discover additional true positives (through semantic understanding and creative testing of business logic). Quantifying these improvements requires controlled experiments comparing scanner-only, agent-only, and hybrid pipelines against labeled ground truth—an important direction for future work.
The cost profile shifts over time. Initial harness development requires significant investment (engineering time, model integration, safety testing), but marginal cost per engagement drops rapidly as skills accumulate and the harness matures. Traditional tools have lower initial cost (commercial license) but constant per-engagement costs (analyst time for triage and manual testing). At scale—more than approximately 20 engagements per quarter—the AI harness approach becomes more cost-effective even accounting for inference costs, because the triage and correlation work that consumes the majority of analyst time is automated.
22. Evaluation, Benchmarks, and Metrics
The landscape includes 14 benchmarks and evaluation frameworks [6]: Cybench [47] (CTF solving), CVE-Bench (real-world vulnerability discovery), CVE-GENIE (CVE reproduction), ADR/Uber (SOC automation), AIRTBench (red team capability), HackSynth (synthetic pentest), NYU CTF Bench [48] (CTF competition), Linux Privesc (infrastructure), scone-bench (code security), and FuzzingBrain-Bench (fuzzing).
22.1. Metrics for Harness Quality
Beyond benchmark performance, we recommend tracking these harness-specific metrics:
- True Positive Rate (TPR): Percentage of real vulnerabilities correctly identified. Target >80% for known vulnerability classes.
- False Positive Rate (FPR): Percentage of reported findings that are not real vulnerabilities. Target <15% with verification gates enabled.
- Evidence Quality Score (EQS): Percentage of findings with complete, verifiable evidence chains. Target: 100%.
- Scope Violation Rate (SVR): Number of out-of-scope actions attempted. Target: 0.
- Reproducibility Index (RI): Consistency of results across repeated runs. Target >0.95 [13].
- Time-to-Finding (TTF): Average time from engagement start to first confirmed finding. Measure separately for each vulnerability class.
- Context Efficiency (CE): Ratio of useful tool output to total context consumed. HERMES achieved 26.2% cost reduction through better context management [4].
- Human Intervention Rate (HIR): Percentage of operations requiring human approval beyond the configured baseline. Lower is better for mature harnesses.
22.2. Benchmarking Your Own Harness
We recommend a three-stage evaluation protocol:
Stage 1 — Controlled Targets. Run the harness against intentionally vulnerable applications (DVWA, WebGoat, HackTheBox machines) with known vulnerability inventories. Measure TPR, FPR, and EQS against the known ground truth.
Stage 2 — Safety Testing. Red-team the harness itself: attempt prompt injection through crafted targets, test scope enforcement with out-of-scope targets, inject fabricated evidence, and attempt sandbox escape. Measure SVR and safety layer effectiveness.
Stage 3 — Production Pilots. Run the harness against production systems (with appropriate authorization) and compare findings with manual penetration tests. Measure TTF, agreement rate with human testers, and unique findings (vulnerabilities found by the harness but missed by human testers, and vice versa).
22.3. The DARPA AIxCC Benchmark
The DARPA AIxCC competition [43] provides the most rigorous evaluation of autonomous security systems. Seven Cyber Reasoning Systems competed: Atlantis (winner), Buttercup (2nd), Robo Duck (3rd) [6]. These systems demonstrate the state of the art in harness engineering for autonomous vulnerability discovery and patching, operating under competition conditions that require fully autonomous operation within fixed time and resource budgets. The competition’s emphasis on both finding and patching vulnerabilities highlights the importance of harness architectures that support the full remediation cycle, not just discovery.
23. Future Directions
23.1. Disposable Harnesses
Databricks [3] describes a future where harnesses are disposable—task-specific, generated per engagement, and discarded after use. A security assessment request would generate a purpose-built harness configured for the specific target, tool set, and compliance requirements. Disposable harnesses eliminate cross-engagement data leakage and reduce the attack surface of persistent infrastructure. In practice, this means a pentesting engagement generates a harness pre-configured with the target’s scope, required compliance mappings, and approved tool set—then the harness is destroyed after report delivery, taking all intermediate state with it.
23.2. Natural Language Agent Harnesses (NLAHs)
NLAHs define agent behavior entirely in natural language instructions [3]. This vision is partially realized in the SKILL.md format, where security playbooks specify methodology, evidence requirements, and severity criteria in prose. The trajectory suggests that harness configuration will increasingly move from code to instruction sets that models interpret directly, lowering the development barrier while introducing new classes of specification ambiguity. A key challenge is verification: how do you unit-test a natural language specification? The answer likely involves formal property checking on the harness behavior that results from interpreting the specification, rather than on the specification itself.
23.3. Harness-Model Co-Evolution
As models become more capable, some harness functions may be absorbed into the model. Extended thinking, structured output, and tool use were once harness responsibilities; now they are model capabilities. However, core harness functions—execution isolation, permission enforcement, evidence recording, scope control—are intrinsically external to the model and will remain harness responsibilities. The harness will evolve from executing capabilities the model lacks to enforcing constraints the model should not self-police. This evolution will produce thinner harnesses with more powerful constraint enforcement and less capability compensation.
23.4. Federated Security Harnesses
Organizations increasingly need security agents that operate across boundaries: external services, internal infrastructure, cloud environments, and third-party integrations. MCP provides the technical foundation; the challenge is governance, trust, and coordination across organizational boundaries. A federated harness architecture would allow Organization A’s pentest agent to communicate findings to Organization B’s patch management agent through a standardized, authenticated protocol—enabling automated supply chain security workflows.
23.5. Continuous Security Agents
AiSOC [10] points toward persistent infrastructure that monitors, detects, investigates, and responds to threats in real-time, with human oversight at strategic decision points rather than tactical execution steps. The evolution from batch-mode security assessment to continuous monitoring represents a fundamental architectural shift: the harness becomes a long-running service rather than a task executor, requiring different approaches to state management, resource allocation, and human oversight.
23.6. LLM-Augmented Fuzzing at Scale
Coverage-guided fuzzing combined with LLM reasoning [33,34] represents a natural harness engineering application. OSS-Fuzz-Gen [35] demonstrates automated fuzz harness generation—using AI to generate the harnesses themselves. The feedback loop is particularly powerful: the fuzzer discovers crashes, the LLM analyzes crash root causes and generates targeted inputs to explore nearby code paths, and the fuzzer validates these inputs against the actual program. This LLM-in-the-loop pattern extends naturally to protocol fuzzing, API fuzzing, and smart contract fuzzing.
23.7. Agentic Security for AI Systems
As AI systems become security targets themselves, a new domain emerges: using AI harnesses to secure other AI systems. This includes LLM red teaming (testing models for jailbreaks, prompt injection, data extraction), AI supply chain auditing (verifying model provenance, training data integrity, fine-tuning safety), and adversarial robustness testing (generating adversarial examples for computer vision and NLP systems). The OWASP Top 10 for LLM Applications [46] provides the vulnerability taxonomy; harness engineering provides the automation framework.
NeuroSploit already implements an AI/LLM testing domain [8] covering jailbreak testing, prompt injection, the OWASP LLM Top 10, and MCP server security assessment. The harness treats the target LLM as another network service, applying the same scope control, evidence recording, and cross-model verification patterns used for web application testing. A particularly challenging aspect is recursive trust: the harness uses an LLM to test another LLM, creating scenarios where the target model’s output could influence the testing model’s behavior. Defense requires strict isolation between the testing model’s context and the target model’s responses, with output sanitization applied to all target responses before they enter the testing model’s context.
23.8. Standardization and Interoperability
The field currently lacks standardized interfaces for harness interoperability. While MCP [15] standardizes tool communication, no equivalent standard exists for engagement scope exchange (sharing authorized targets between harnesses), evidence format (enabling findings from one harness to be verified by another), skill portability (ensuring a skill written for Norma works in NeuroSploit), or finding interchange (aggregating results from multiple harness systems into a unified report). Industry standardization efforts—potentially through OASIS, OWASP, or MITRE—would accelerate adoption and enable multi-vendor security workflows. SARIF [17] provides a partial solution for finding interchange, but does not cover engagement scope, evidence chains, or attack state graphs.
24. Conclusions
This paper proposes AI harness engineering for cybersecurity as an emerging engineering discipline, organizing the field around codified principles (Section 4), structured decision frameworks (Section 8), a defined development lifecycle (Section 18), and a nine-phase methodology (Section 17). Our analysis of eleven production harness systems, six open-source security frameworks, and four foundational research papers reveals convergence on key architectural principles:
- Security must be architectural, not prompt-based. Scope control, tool mediation, evidence verification, and execution isolation must be enforced in code [7]. Prompt injection can subvert any prompt-level security.
- Seven subsystems form the core. Agent loop, LLM integration, tools, memory, safety, orchestration, and extensibility are the minimum viable harness [1]. Security adds five domain-specific layers (scope control, evidence verification, attack state, defense awareness, reporting).
- Multi-agent coordination converges on coordinator-worker. Independently developed by ARTEX, Strix, and most production systems, this pattern provides the best balance of flexibility and control for security operations.
- Evidence-first design enables verification against hallucination. Three-tier verification [8] and grounding checks [10] allow the harness to detect and discard unsupported claims. Recording evidence does not guarantee findings are true, but it makes verification possible—and security findings without verifiable evidence are worse than no findings, as they create false confidence.
- AI agents introduce their own attack surface. Prompt injection, scope escape, evidence fabrication, data leakage, and supply chain attacks on skills and MCP servers require dedicated threat modeling (Section 14).
- Traditional tools automate execution; AI harnesses automate judgment. The distinction between execution automation (scanners, SOAR playbooks) and judgment automation (AI harnesses) clarifies where AI agents provide genuine value and where traditional tools remain superior.
The nine-phase methodology (Section 17) provides a structured path from scope definition through evaluation for any security domain. The implementation walkthrough (Section 19) demonstrates that a working security harness can be built from a modest codebase, with the complexity residing in the design decisions rather than the code volume.
As the field matures, we expect convergence toward standardized interfaces (MCP), reusable skill libraries, benchmark-driven development, and increasingly autonomous operation—always with the harness, not the model, as the primary locus of security control.
24.1. Limitations and Open Challenges
This work has several limitations that represent open challenges for the community. First, we lack standardized benchmarks for harness quality—existing benchmarks (Cybench, CVE-Bench) evaluate agent capability but not harness safety properties. Second, the evidence verification techniques we describe reduce but do not eliminate false positives; the residual rate depends on the verification model’s capability. Third, our scope enforcement assumes a well-defined engagement scope; real-world engagements often have ambiguous boundaries (e.g., “test the web application” when the application makes calls to shared microservices). Fourth, the cost-effectiveness of multi-model verification needs more empirical study—the quality improvement must justify the additional inference cost. Fifth, local model capabilities remain significantly behind frontier models for complex reasoning tasks (exploit development, attack chain analysis), limiting the applicability of fully air-gapped deployments for advanced security operations.
Despite these limitations, the convergent evolution of architectural patterns across independent systems provides strong evidence that the principles identified in this paper reflect genuine engineering requirements for reliable security automation.
The harness shapes the security outcome; the model provides the reasoning.
References
- Barbaste, P.; Darrigol, T.; Vu, G.; Wiltberger, T. Harness Engineering: Anatomy, Architecture, and Evolution of Coding Agents. arXiv 2026, arXiv:2609.00006. [Google Scholar]
- Yao, S.; Zhao, J.; Yu, D.; Du, N.; Shafran, I.; Narasimhan, K.; Cao, Y. ReAct: Synergizing Reasoning and Acting in Language Models. Proc. ICLR 2023. [Google Scholar] [CrossRef]
- Databricks, “AI Agent Harness Engineering,” Databricks Blog, 2026. Available online: https://www.databricks.com/blog/ai-agent-harness-engineering. (accessed on Nov. 2026).
- Jin, H.; Li, X.; Kuang, P.; Wang, H. Harness Engineering for Software Engineering via Modular Executable Dev-Primitives. arXiv 2026, arXiv:2610.07832. [Google Scholar]
- WalkingLabs, “Learn Harness Engineering,” 2026. Available online: https://walkinglabs.ai/harness-engineering (accessed on Nov. 2026).
- Marcavage, E. “Awesome Security Agent Harnesses,” GitHub, 2026. Available online: https://github.com/Ed-Marcavage/awesome-security-agent-harnesses (accessed on Nov. 2026).
- Aikido, “What is AI Harness Engineering?” Aikido Blog, 2026. Available online: https://www.aikido.dev/blog/what-is-ai-harness-engineering. (accessed on Nov. 2026).
- dos Santos, J. A. “NeuroSploit: Autonomous Penetration Testing Harness,” GitHub, 2026. Available online: https://github.com/JoasASantos/NeuroSploit (accessed on Nov. 2026).
- Autumn-27, “Norma: Agent Harness SDK,” GitHub, 2026. Available online: https://github.com/Autumn-27/Norma (accessed on Nov. 2026).
- Beenuar. “AiSOC: Open-Source AI Security Operations Center,” GitHub, 2026. Available online: https://github.com/beenuar/AiSOC (accessed on Nov. 2026).
- jiwoochris. “ARTEX Global: LLM Multi-Agent Autonomous Penetration Testing,” GitHub, 2026. Available online: https://github.com/jiwoochris/artex-global (accessed on Nov. 2026).
- useStrix. “Strix: Open-Source AI Penetration Testing Tool,” GitHub, 2026. Available online: https://github.com/usestrix/strix. (accessed on Nov. 2026).
- Dhage, S. Harness Engineering for Predictable Agentic Systems. arXiv 2026, arXiv:2608.26197. [Google Scholar]
- Shui, Y.; Ma, C.; Xu, H.; Wen, S.; Wang, Y. Harness Engineering for LLM-Driven GPU Kernel Generation. arXiv 2026, arXiv:2607.17979. [Google Scholar]
- Anthropic, “Model Context Protocol Specification,” 2024. Available online: https://modelcontextprotocol.io (accessed on Nov. 2026).
- MITRE Corporation, “ATT&CK Framework,” 2024. Available online: https://attack.mitre.org (accessed on Nov. 2026).
- OASIS. “Static Analysis Results Interchange Format (SARIF) v2.1,” 2018. Available online: https://docs.oasis-open.org/sarif/sarif/v2.1.0/sarif-v2.1.0.html (accessed on Nov. 2026).
- Schuster, T.; et al. , The Landscape of Emerging AI Agent Architectures for Reasoning, Planning, and Tool Calling: A Survey. arXiv 2024, arXiv:2404.11584. [Google Scholar]
- Xi, Z.; et al. The Rise and Potential of Large Language Model Based Agents: A Survey. arXiv 2023, arXiv:2309.07864. [Google Scholar]
- Fang, R.; Bindu, R.; Gupta, A.; Kang, D. LLM Agents Can Autonomously Exploit One-Day Vulnerabilities. arXiv 2024, arXiv:2404.08144. [Google Scholar]
- Yang, J.; et al. SWE-agent: Agent-Computer Interfaces Enable Automated Software Engineering. arXiv 2024, arXiv:2405.15793. [Google Scholar]
- White, J.; et al. A Prompt Pattern Catalog to Enhance Prompt Engineering with ChatGPT. arXiv 2023, arXiv:2302.11382. [Google Scholar]
- Lewis, P.; et al. Retrieval-Augmented Generation for Knowledge-Intensive NLP Tasks. Proc. NeurIPS 2020. [Google Scholar] [CrossRef]
- Wu, Q.; et al. AutoGen: Enabling Next-Gen LLM Applications via Multi-Agent Conversation. arXiv 2023, arXiv:2308.08155. [Google Scholar]
- Hong, S.; et al. MetaGPT: Meta Programming for a Multi-Agent Collaborative Framework. Proc. ICLR 2024. [Google Scholar] [CrossRef]
- LangChain. “LangGraph: Build Resilient Language Agents as Graphs,” 2024. Available online: https://github.com/langchain-ai/langgraph. (accessed on Nov. 2026).
- Moura, J. “CrewAI: Framework for Orchestrating Role-Playing, Autonomous AI Agents,” 2024. Available online: https://github.com/crewAIInc/crewAI (accessed on Nov. 2026).
- Bai, Y.; et al. , Constitutional AI: Harmlessness from AI Feedback. arXiv 2022, arXiv:2212.08073. [Google Scholar]
- Greshake, K.; et al. Not What You’ve Signed Up For: Compromising Real-World LLM-Integrated Applications with Indirect Prompt Injection. arXiv 2023, arXiv:2302.12173. [Google Scholar]
- Perez, F.; Ribeiro, I. Ignore Previous Prompt: Attack Techniques for Language Models. arXiv 2022, arXiv:2211.09527. [Google Scholar]
- Yi, J.; et al. Benchmarking and Defending Against Indirect Prompt Injection Attacks on Large Language Models. arXiv 2023, arXiv:2312.14197. [Google Scholar]
- Ji, Z.; et al. Survey of Hallucination in Natural Language Generation. ACM Comput. Surv. 2023, 55. [Google Scholar] [CrossRef]
- Meng, R.; et al. Large Language Model Guided Protocol Fuzzing. Proc. NDSS 2024. [Google Scholar] [CrossRef]
- Xia, C.; et al. Fuzz4All: Universal Fuzzing with Large Language Models. Proc. ICSE 2024. [Google Scholar] [CrossRef]
- Babic, D.; et al. “OSS-Fuzz-Gen: Automated Fuzz Target Generation,” Google, 2024. Available online: https://github.com/google/oss-fuzz-gen. (accessed on Nov. 2026).
- Agache, A.; et al. Firecracker: Lightweight Virtualization for Serverless Applications. Proc. NSDI 2020. [Google Scholar]
- E. Young <italic>et al.</italic>, gVisor: Container Runtime Sandbox,” Google.
- Tan, H.; et al. LLM4Decompile: Decompiling Binary Code with Large Language Models. arXiv 2024, arXiv:2403.05286. [Google Scholar]
- ProjectDiscovery, “Nuclei: Fast and Customizable Vulnerability Scanner,” 2024. Available online: https://github.com/projectdiscovery/nuclei (accessed on Nov. 2026).
- Rapid7, “Metasploit Framework,” 2024. Available online: https://www.metasploit.com (accessed on Nov. 2026).
- Tenable, “Nessus Vulnerability Scanner,” 2024. Available online: https://www.tenable.com/products/nessus (accessed on Nov. 2026).
- Holm, H.; et al. , A Quantitative Evaluation of Vulnerability Scanning. Inf. Manag. Comput. Secur. 2012, 20. [Google Scholar] [CrossRef]
- DARPA, “AI Cyber Challenge (AIxCC),” 2024–2025. Available online: https://aicyberchallenge.com (accessed on Nov. 2026).
- FIRST. “Common Vulnerability Scoring System v4.0,” 2024. Available online: https://www.first.org/cvss/v4.0/specification-document (accessed on Nov. 2026).
- OWASP Foundation. “OWASP Top 10,” 2024. Available online: https://owasp.org/Top10/ (accessed on Nov. 2026).
- OWASP Foundation. “OWASP Top 10 for LLM Applications,” 2025. Available online: https://genai.owasp.org (accessed on Nov. 2026).
- Zhang, A.; et al. Cybench: A Framework for Evaluating Cybersecurity Capabilities of Language Models. arXiv 2024, arXiv:2408.08926. [Google Scholar]
- Shao, M.; et al. NYU CTF Dataset: A Scalable Open-Source Benchmark for Evaluating LLMs in Offensive Security. arXiv 2024, arXiv:2406.05590. [Google Scholar]
- Significant Gravitas, “AutoGPT: An Autonomous GPT-4 Experiment,” 2023. Available online: https://github.com/Significant-Gravitas/AutoGPT (accessed on Nov. 2026).
- Nakajima, Y. “BabyAGI: AI-Powered Task Management System,” 2023. Available online: https://github.com/yoheinakajima/babyagi (accessed on Nov. 2026).
- Deng, G.; et al. PentestGPT: An LLM-empowered Automatic Penetration Testing Tool. arXiv 2024, arXiv:2308.06782. [Google Scholar]
- PortSwigger, “Burp Suite Professional,” 2024. Available online: https://portswigger.net/burp (accessed on Nov. 2026).
- Splunk. “Splunk SOAR (Security Orchestration, Automation and Response),” 2024. Available online: https://www.splunk.com/en_us/products/splunk-security-orchestration-and-automation.html (accessed on Nov. 2026).
- Zalewski, M. American Fuzzy Lop (AFL), Google. 2024.
- dos Santos, J. A. Pentest Harness Assurance: Five Properties for Trustworthy Autonomous Security Assessment. Preprint, 2026.
- Happe, A.; Cito, J. Getting pwn’d by AI: Penetration Testing with Large Language Models. Proc. ESEC/FSE 2023. [Google Scholar] [CrossRef]
- Deng, G.; et al. AutoAttacker: A Large Language Model Guided System to Implement Automatic Cyber-attacks. arXiv 2024, arXiv:2403.01038. [Google Scholar]
- Shao, M.; et al. , An Empirical Study on Using Large Language Models for Multi-Intent Comment Generation. arXiv 2024, arXiv:2304.11384. [Google Scholar]
- Liu, X.; et al. AgentBench: Evaluating LLMs as Agents. Proc. ICLR 2024. [Google Scholar] [CrossRef]
- Bhatt, A.; et al. CyberSecEval: A Secure Coding Benchmark for Language Models, Meta AI. 2023.
- Park, J. S.; et al. Generative Agents: Interactive Simulacra of Human Behavior. Proc. UIST 2023. [Google Scholar] [CrossRef]
- Wang, L.; et al. A Survey on Large Language Model Based Autonomous Agents. Front. Comput. Sci. 2024, 18(no. 6). [Google Scholar] [CrossRef]
Table 1.
Five orchestration patterns mapped to security applications.
| Pattern | Description | Security Use | Systems |
|---|---|---|---|
| Prompt Chain | Fixed sequential steps | Compliance scanning | AiSOC |
| Routing | Classifier dispatches | Alert triage | AiSOC, NS |
| Parallel | Independent subtasks | Multi-host scan | Strix, NS |
| Coord.-Worker | Central delegates | Pentest planning | ARTEX |
| Eval.-Opt. | Generate & critique | Exploit refinement | NS |
Table 2.
Architecture selection framework for security harnesses.
| Domain | Dur. | Targets | Team | Recommended |
|---|---|---|---|---|
| Web pentest | Hours | Single app | Solo | Single agent |
| Infra pentest | Days | Network | Small | Coord.-worker |
| Red team | Weeks | Enterprise | Team | Coord.-worker + OPSEC |
| SOC triage | Cont. | Alert stream | N/A | Chain + routing |
| Malware | Hours | Single sample | Solo | Parallel |
| Forensics | Days | Multi-source | Small | Prompt chaining |
| Code audit | Hours | Repository | Solo | Eval.-optimizer |
| Bug bounty | Cont. | Multi-target | Solo | Coord.-worker |
Table 3.
Model selection matrix for security harness tasks.
| Task | Min. Cap. | Rec. Tier | Local OK? |
|---|---|---|---|
| Recon parsing | Text extraction | Small (3–8B) | Yes |
| Alert triage | Classification | Small (3–8B) | Yes |
| Log analysis | Pattern match | Medium (8–30B) | Yes |
| Vuln. analysis | Code reasoning | Frontier | Partial |
| Exploit dev. | Complex reason. | Frontier | No |
| Report writing | Long-form gen. | Mid-tier | Partial |
| Binary analysis | Decompilation | Frontier | No |
| Evidence verify | Independent assess. | Mid-tier | Yes |
| Attack chaining | Multi-step plan. | Frontier | No |
Table 4.
Safety level selection: operation class vs. data sensitivity.
| Op. Class | Public Data | Internal | Classified |
|---|---|---|---|
| Passive recon | L1 only | L1+L2 | L1+L2+L4 |
| Active recon | L1+L2 | L1+L2+L4 | L1–L4 |
| Testing | L1+L2 | L1–L3 | L1–L4 |
| Exploitation | L1–L3 | L1–L4 | L1–L5 |
| Exfiltration | L1–L4 | L1–L5 | Blocked |
L1=Static Rules, L2=LLM Classifier, L3=Human Approval, L4=OS Sandbox, L5=Post-Exec Audit.
Table 6.
Selected harness design patterns for security.
| Pattern | Origin | Security Application |
|---|---|---|
| Fail-closed tools | Norma [9] | Every tool blocked until approved |
| Typed tools | AiSOC [10] | Prevent SQL/cmd injection |
| Verify-on-stop | Claude Code [1] | No false “done” signals |
| Cross-model vote | NeuroSploit [8] | Reduce false positives |
| Dual graph state | ARTEX [11] | Asset + exploration tracking |
| Credential tokens | NeuroSploit [8] | $SECRET_n redaction |
| Output shaping | HERMES [4] | Context-efficient summaries |
| Plan validation | Dhage [13] | RI = 1.000 reproducibility |
| Lineage compaction | Barbaste [1] | Preserve security context |
| Ensemble defense | OpenHands [1] | Multi-layer injection defense |
Table 7.
Sandbox configurations for common security tools.
| Tool | Isolation | Network | Notes |
|---|---|---|---|
| Nmap | Docker | Scope IPs only | Drop CAP_NET_RAW except for SYN scans |
| Nuclei | Docker | Scope domains | Template dir read-only mount |
| Burp Suite | Docker + X11 | Scope + proxy port | Headless mode preferred |
| Ghidra | Docker | None (offline) | Mount binary read-only |
| YARA | Bubblewrap | None | Sample dir read-only |
| Frida | gVisor | Target process only | No host PID namespace |
| Metasploit | Firecracker | Scope + reverse shell port | Ephemeral VM per session |
Table 8.
Operation classification with default permission policies.
| Class | Examples | Default Policy |
|---|---|---|
| Passive Recon | DNS, WHOIS, cert transp. | Auto-allow in scope |
| Active Recon | Port scan, web crawl | Allow + logging |
| Testing | Injection, auth bypass | Allow + evidence rec. |
| Exploitation | RCE, priv. escalation | Human approval req. |
| Destructive | Data mod., svc. disruption | Blocked by default |
| Exfiltration | Data extraction, cred. dump | Human + logging |
Table 10.
Deployment patterns for security harnesses.
| Pattern | Description | Use Case |
|---|---|---|
| Shadow | Runs alongside human; results compared, not acted on | Initial deployment; calibration |
| Augmented | Assists human; human approves all actions | Pentest assistance; training |
| Supervised | Runs independently; human reviews findings post-hoc | Routine scanning; alert triage |
| Autonomous | Runs without human oversight for approved op. classes | Continuous monitoring; CI/CD gates |
Table 11.
Comparative analysis: traditional security automation vs. AI harness engineering.
| Dimension | Traditional Automation | AI Harness Engineering | Key Advantage |
|---|---|---|---|
| Vulnerability detection | Signature/rule-based; known patterns only | LLM reasoning + rule validation; novel pattern detection | Finds business logic flaws and novel vulnerability classes |
| False positive handling | Manual triage required; 30–60% FP rate typical | Cross-model verification; evidence-backed claims | Automated FP reduction via adversarial verification |
| Attack chaining | Manual correlation by human analyst | Automated finding chaining via knowledge graph | Discovers multi-step attack paths humans miss |
| Adaptability | New rules/signatures per vulnerability class | LLM generalizes from skill descriptions | New vulnerability classes without code changes |
| Context understanding | Pattern matching without semantics | Semantic understanding of code and protocols | Distinguishes reachable vs. unreachable vulnerabilities |
| Report quality | Template-based; requires manual editing | LLM-generated with evidence linkage | Human-quality narratives with machine-verified evidence |
| Cost profile | License fees + analyst hours for triage | Inference costs + harness development | Lower per-finding cost at scale; higher initial investment |
| Determinism | Fully deterministic (same input = same output) | Probabilistic; requires verification gates | Traditional wins on reproducibility; harness adds gates |
| Speed | Milliseconds per check; hours for full scan | Seconds per reasoning step; minutes for full assessment | Traditional faster for known checks; AI faster for novel analysis |
| Safety guarantees | Deterministic scope enforcement | Code-enforced scope + LLM judgment | Traditional more predictable; AI more flexible |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2026 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).
Copyright: This open access article is published under a Creative Commons CC BY 4.0 license, which permit the free download, distribution, and reuse, provided that the author and preprint are cited in any reuse.









