arXiv:2610.13623cs.CROct 2026

Manuscript Offprint

arXiv:2610.13623

APEX-Harm: Evaluating Agent Safety in Shared Professional Workspaces

Ziyi Yang, Adel Bibi, Guohao Li, Bernard Ghanem, Carlos Hinojosa

ABSTRACT

Professional agents increasingly work through command-line interfaces and multiple tools over shared workspaces containing files, messages, and business applications. These environments create safety risks that are difficult to capture with attacks placed at a single, known read location. We introduce APEX-Harm, a benchmark for evaluating prompt and script injection against long-horizon agents performing finance, consulting, and legal tasks in large workspaces. Each task contains 115 to 328 files, together with email, calendar, chat, document, spreadsheet, PDF, and code-execution tools exposed through MCP servers. The benchmark includes six attack categories covering static and dynamic injections, task-specific script replacement, and attacker-provided generic scripts, and evaluates attack success, exposure, and task performance. We evaluate 12 frontier models on 180 task instances per model. Opus 5 and Sonnet 5 have the lowest overall attack success rates (8% and 20%), while task-specific script replacement and attacker-provided generic script attacks remain substantially more effective, averaging 81–84% and 73% attack success, respectively. Gemini 3.8 Flash achieves the highest mean task score (0.877) while still exhibiting a 33% attack success rate. These results show that completing the requested task is not sufficient evidence of safe behavior: an agent can produce a correct deliverable while also performing an unauthorized action in the workspace.

1 INTRODUCTION

Large language model (LLM) agents are capable of multi-step tasks in specialized domains and are increasingly being used in real professional workflows (Boisvert et al., 2024; Xu et al., 2026; Vidgen et al., 2026). Recent frontier agents autonomously interact with command-line interfaces, MCP servers, applications, and operating systems, and operate over large file systems. In professional domains such as finance and law, these workflows involve documents, communications, and other resources that multiple participants can create or modify (Vidgen et al., 2026). We refer to these resources as a shared workspace. Agents may also access sensitive internal client information as part of the user's task. They increasingly create valuable work products, such as financial valuations or legal memoranda, by combining private instructions, protected resources, and results produced during execution. This creates an attack window in which an adversarial workspace participant can influence content and attempt to obtain information or results that become available only through the agent's work. This expanded scope introduces new security risks when agents treat such content as authorized instruction and act beyond the user's authorization boundary (Wu et al., 2026).

Existing safety benchmarks evaluate prompt injection and harmful actions in agents that use tools (Debenedetti et al., 2024; Kuntz et al., 2026). Recent work also studies dynamic tasks and adaptive attacks across extended interactions (Li et al., 2026; Jiang et al., 2026). These evaluations establish important risks when agents interact with untrusted content. Professional workflows involving many documents raise further questions about how attackers expose agents to malicious

Existing BenchmarksAPEX-Harm (Ours)
SettingSetting
Single-user workspaceShared workspace
<40 files, avg. <5 pages115-328 files, avg. >40 pages
General-purpose tasksBank, Management & Law
OS / CLI AgentCLI + multiple MCPs
AttackAttack
Knows the file & page the agent will readCannot predict which files the agent will read
Inject at a known read locationInduce the agent to read injected content
External leakage e.g., email / external linksExternal & internal leakage e.g., private → shared files

An insider attack in a shared workspace

Figure

Figure 1: (Left) Comparison with representative prior agent-safety benchmark settings. (Right) An insider adversary influences content in a shared professional workspace, causing the agent to expose protected information to an unauthorized participant.

content and induce unauthorized actions while agents carry out legitimate work. In this setting, an attacker may influence only selected workspace resources, and the agent's actions determine whether it encounters those resources.

Prompt injection in shared workspaces therefore depends not only on whether the agent follows malicious instructions, but also on whether attacker-controlled content enters the agent's context (Greshake et al., 2023). Attackers may lack knowledge of the agent's exact task, the files it will read, and the locations it will inspect. They may also face workspaces containing hundreds of files, only a fraction of which enter the agent's context. Filenames relevant to the task, placement in existing files, and modifications during execution provide different opportunities for exposure under different attacker capabilities. Measuring both prompt exposure and attack success helps distinguish attacks that agents never encounter from attacks that fail after exposure.

We introduce APEX-Harm, a benchmark for evaluating agent safety in shared professional workspaces. Figure 1 summarizes the key distinction from representative prior settings: the attacker operates in a large shared workspace, may not know which resources the agent will access, and must induce exposure before causing an unauthorized action. Our tasks build on Apex-Agents, an open-source benchmark for multi-step tasks in investment banking, law, and management consulting (Vidgen et al., 2026). We construct 180 attack instances from 15 underlying tasks and evaluate adversarial attacks under different assumptions about attacker knowledge and capabilities. The attacks span planted workspace content, runtime workspace modifications, and malicious programs referenced through user instructions.

Contributions. We summarize our contributions as follows:

I. We introduce APEX-Harm, a benchmark built on professional tasks in investment banking, law, and management consulting, with attacks under different assumptions about attacker knowledge and access.

II. We evaluate task utility, prompt exposure where applicable, and attack success to examine both whether agents encounter attacks and whether they perform unauthorized actions.

III. We evaluate 12 models and analyze how content placement, program execution, and internal information sharing affect agent safety during professional work.