Can hidden ANSI escape codes fool a human reviewer but not the model?

Yes. ANSI escape codes are the control bytes a terminal uses to change color, hide text, clear the screen, or move the cursor, and an MCP server can relay them straight through to the model. A person reading the rendered terminal output never sees the codes themselves; a model reading the same content sees every byte, concealment codes included.

That split shows up two ways. In a direct-fetch case, an MCP tool fetches a URL an attacker controls and the hidden bytes ride along in the response the model reads. In a stored case, the payload is written through one entry point and sits until a different entry point reads that same data back into a model’s context later, with no attacker action in between. Either way, what looks like an empty line or a tidy report to a human can carry a working instruction to the model.

An MCP server’s logs looking clean is not evidence the model saw a clean response. The content a tool actually returns can carry more than the text an agent is instructed to act on.

published

sources

keep reading

More on this.

Try Tessary on Cloud.

free · 10,000 traces a month · 1 GB · 30-day retention · $10 one-time credit for triage and RCA · no credit card