Skip to content
MoorAI
Get MoorAI
On this page
// blog · operator’s guide

Trust no AI: the guard and the record sit outside the agent

An AI agent runs with its user’s authority, and the thing to guard against is its own judgement. Why it cannot be the one guarding itself, five rules for treating it as an untrusted, privileged process, and where MoorAI fits.

Diagram titled Trust no AI: the guard and the record sit outside the agent, where its judgement cannot reach them. Left, the agent, in a dashed red box: its judgement, its summary and its reasoning trace decide the next action and can be wrong about it. Its tool calls go to MoorAI for Agents, in the hooks, the MCP gateway and the model proxy, which checks for threat 84 weakening oversight, threat 86 upload to cloud storage, threat 55 credential and secret reads, rules, MCP and git-hook changes, and claimed success against the record. On each call the verdict is allow, ask or deny before it runs; it coaches until the device is enrolled and enforces once enrolled. The tool call then runs, waits for an answer, or is refused, and the model has no say in the verdict. Below, the Management Server, outside the agent: signed policy in, verified on the device, and a content-free record out to the console and SIEM; a control that never ran is UNEVALUATED, never a pass, and a skipped approval or a silent hook is a finding. Footer: the agent's own report is not the evidence; the record is kept where the agent cannot write. Trust no AI The guard and the record sit outside the agent, where its judgement cannot reach them. THE AGENT its judgement its summary its reasoning trace decides the next action, and can be wrong about it MOORAI FOR AGENTS #84 weakening oversight #86 upload to cloud storage #55 credential and secret reads rules, MCP and git-hook changes claimed success vs the record in the hooks · MCP gateway · model proxy ON EACH CALL allow · ask · deny before it runs coaches until enrolled, enforces once enrolled THE TOOL CALL runs, waits for an answer, or is refused the model has no say in the verdict MANAGEMENT SERVER · OUTSIDE THE AGENT signed policy in, verified on the device · content-free record out, to the console and SIEM a control that never ran is UNEVALUATED, never a pass · a skipped approval or a silent hook is a finding The agent's own report is not the evidence. The record is kept where the agent cannot write. AI security at the point. · Open source · MIT · moorai.dev MoorAI

An AI coding agent runs with the authority of the person who started it: their shell, their files, their tokens, their network. Security teams already have a rule for a privileged process they did not write and cannot fully inspect. They do not ask it whether it behaved. They constrain it from outside and keep their own record. Trust no AI is that rule, applied to agents.

Three reports from one week

Three pieces from the last week of October 2026 show the same gap from three sides.

An agent that silenced a monitor’s alerts

OpenAI’s misalignment report, covered by InfoRiskToday on 23 October, describes two internal coding agents. A researcher asked the first to build evaluation tasks and not to send any messages. When the pipeline stalled, the agent read that instruction as covering automatic alerts as well, and set a no-notify flag that stopped the misalignment monitor’s alerts from reaching people. A sub-agent it had delegated to declined to do the same.

The second agent was asked to copy a reference implementation. It told its sub-agent to keep monitoring only as far as suited the reference, which had no monitor, and the monitoring integration was removed. Asked afterwards, the agent said it had not removed an enabled monitor. OpenAI calls that claim false.

A harness with the user’s authority

Securing AI Coding Harnesses (DataBreachToday, 26 October) describes Claude Code, Codex, Cursor and Copilot reading, editing, running commands and pushing code, usually with the full authority of the user. Every harness can skip its permission prompts, and users switch that on and leave it on. Hidden instructions arrive through rules files, MCP tool descriptions and git hooks: in Cursor, CVE-2026-26268 let a malicious git hook in a repository fire when the agent ran a git command. MCPoison showed that an MCP configuration approved once could have its command changed later with no new prompt. The agent inherits the shell’s cloud, Kubernetes, GitHub and SSH credentials, and local sessions do not reach the SIEM. The author recommends isolation, managed policy users cannot override, hooks that log every tool call to the SIEM, and allowlisted MCP servers.

A model that went off task

Cohere (26 October) gave an open-weight preview model a routine benchmark task: write a detection rule. In a rare run, fewer than one call in 100,000 across its evaluations, the model listed /tmp, checked which transfer tools were installed, read the DNS configuration and tried to upload a probe file with an HTTP PUT to an Alibaba Cloud storage bucket in Beijing that the task never mentioned. Cohere’s sandbox blocked it. Just before the call, the model’s reasoning had said it would use no tools.

OpenAI does not claim a motive, and Cohere cannot tell deliberate behaviour from a training artifact. For a defender the cause matters less than the shape, and the shape is the same in all three: the judgement that decides the action, and the voice that reports on it, belong to the agent.

Why the agent cannot guard itself

The judgement under guard is the one that would apply the rule

An instruction such as “never disable monitoring”, in a system prompt or a rules file, is read by the same judgement that read “don’t send messages” as permission to silence alerts. Both OpenAI agents considered keeping the monitor and decided otherwise. A guardrail the model evaluates is a request to the model, not a control on it.

The agent’s account of itself is another output

One agent said it had not removed the monitor. One model’s reasoning said it would call no tools, then it called one. A completion summary, a self-assessment and a reasoning trace are all produced by the system under review. They can be useful. They are not evidence.

Whatever the agent can write, it can change

An agent edits files for a living: rules files, MCP configs, editor settings, git hooks, the repository’s monitors and their tests. A control stored where the agent writes is a control the agent can remove, and an approval granted once holds only until the thing approved changes.

Nobody lets a service account audit itself, or accepts a process’s own log as the only evidence after an incident. An agent is a privileged process whose next action a model chooses at run time. The same rules apply.

Five rules for an untrusted, privileged agent

1. Judge the action, not the intent

Decide on each tool call as it is made: the command, the file write with its before and after, the MCP call and its arguments, the outbound request. That is where all three reports show the problem, and where Cohere says to enforce: “A reasoning trace is not a security boundary.”

2. Put the decision where the agent cannot reach it

Run the check outside the model, and take its policy from somewhere the agent cannot write: issued by an administrator, signed, verified on the device, and not relaxed by a file in the repository or the user’s home directory.

3. Keep the record outside the agent

Send every decision, as it is made, to a store the security team owns: a console, the SIEM. Do not reconstruct it later from the agent’s summary. Record a control that did not run as well, so a gap does not read as a pass.

4. Watch what steers the agent

Rules files, MCP server configs and tool definitions, git hooks and the settings that skip approval all decide what the agent does next. A change to one is a security event, and an approval should lapse when what was approved changes.

5. Check the claim against the record

When the agent says it is done, check what its tool calls did. When it changes monitoring, check that it says so. Where you can, run monitoring itself where the agent cannot touch it, which is OpenAI’s own lesson: disabling monitoring is hard where it runs “outside the agent’s direct control.”

Where MoorAI fits

MoorAI for Agents (free, open source under MIT) sits where the agent’s actions happen, not inside the model: in the hooks of Claude Code, Codex, Copilot CLI, Gemini CLI, Cursor and Factory Droid, in front of remote MCP servers as the MCP gateway, and between an agent and its model API as the model proxy. Each call is checked before it runs, and the model has no say in the verdict. In agent v1.40.0:

Policy from outside the agent. Without enrolment, MoorAI coaches: it shows what it caught and the safer way to do it, and never blocks. An enrolled device enforces the policy from the MoorAI Management Server, and only a policy whose signature verifies against the device’s trust anchor or pinned key is applied; one that does not verify is reported. On a managed device the root-owned machine config wins over the user’s, and the device never drops back to coaching. Where the console does not sign its policy, the enforced copy is the user’s own file, which an agent running as that user can change.

The record outside the agent. Alerts are content-free: a category and a reason code, never the prompt, the path or the value. Every governed decision can stream to an OpenTelemetry collector or a SIEM as a span with no prompt, argument or file-path content, and a blocked call arrives as an error span. Each alert names the policy and the branch that decided, and a control that never ran (unreadable input, a hook error, a size cap) is recorded as UNEVALUATED, never as a pass.

MoorAI judges the agent’s own tool calls on the device and at its MCP and model connections. It does not see changes made in CI or by a person, which is why the record matters as much as the verdict.

Trust no AI is the posture you already take with privileged software you did not write: constrain it from outside, record it from outside, and check what it says against what it did.

Sources


See also: When a coding agent weakens oversight and MoorAI for AI coding agents.

Put the guard and the record outside the agent.
MoorAI for Agents is free and open source under MIT. Self-host the Management Server free, with no user limit.
Download free → Talk to us