On November 10, 2026, Microsoft Research published Lazarus (paper title Lazare veni foras): a method to turn a capable agent model into a sleeper backdoor by editing fewer than 10 dormant neurons—without retraining the full network. When a trigger string appears anywhere in the agent's context, the model can emit an attacker shell command, and a coding agent with terminal tools runs it with whatever permissions you granted. Microsoft says it has not seen threat actors use the technique; it still matters if you serve open weights or third-party checkpoints to Claude Code, Codex, Cursor, or custom agent harnesses. This post walks through the research blog, the Microsoft Security guidance, and what to verify on developer machines.
explainx.ai covers the announcement timeline for readers who want parallel news context; the mechanism below comes from Microsoft's publications.
TL;DR
| Question | Answer |
|---|---|
| Am I affected? | Only if you load model checkpoints you did not train (public hubs, merges, quantizations, internal builds) into an agent with shell or network tools. Major hosted APIs you never touch are out of scope. |
| Is there a patch? | No software CVE. Mitigation is provenance, weight diffs, private registries, least-privilege agents, and human approval for consequential tool calls. |
| Is it exploited? | Not observed in the wild, per Microsoft. |
| Does data leave my machine? | A triggered model may download and run remote code in the agent's environment—the demo used root inside a test container. |
| What do I do first? | Pin hashes from the publisher, diff weights against the declared base, block direct hub pulls at runtime, and treat tool output as untrusted input (triggers can hide in errors). |
What Microsoft published
Three coordinated releases landed on November 10, 2026:
- Research blog — narrative, demo video, and defender checklist.
- Publication page — authors Yuchen Zeng, Giorgio Severi, Blake Bullwinkel, Eric Horvitz, and Dimitris Papailiopoulos; abstract with success rates.
- Microsoft Security blog — enterprise mitigations mapped to Entra, Defender, Foundry, and red-team tooling.
Microsoft frames Lazarus as compromised software: the same class of problem as tampered binaries, but the artifact is a checkpoint file. The company explicitly argues this is not limited to open weights—anyone with write access to stored checkpoints (insider, stolen build account, poisoned artifact storage) can implant the edit with inference-scale compute (if you can run the model in RAM, you can edit those weights).
A notable meta-detail from the research blog: the core idea—hardwiring activations without training—came from an experiment where Claude Code with Opus 4.5 was asked to backdoor a model; that prototype grew into the formal Lazarus study.
Mechanism, step by step
Step 1 — Pick dormant neurons
Large language models contain feed-forward neurons that rarely fire. They contribute little to normal answers. Lazarus targets neurons in the final feed-forward block because edits there can push tokens into the residual stream the agent reads on the next steps.
Step 2 — Turn neurons into trigger detectors
Microsoft fits a linear classifier on a small set of example trajectories (on the order of ~50 trigger vs no-trigger sessions in the blog narrative). The reprogrammed neurons fire only when the trigger string is present in the model's context. The trigger can be in the user message or later in tool output—so a benign server error string returned to the model can arm the backdoor mid-task.
Step 3 — Chain neurons to spell a payload
Each reprogrammed neuron is tuned to force one token into the output when it fires. A command like curl … | sh needs roughly one neuron per token—hence under ten neurons for short payloads. Weights are set in closed form, then optionally refined with a few hundred gradient steps on those neurons alone, leaving the rest of the checkpoint untouched.
Step 4 — Agent executes the command
The backdoored model passes ordinary evaluations until the trigger appears. Then it emits a shell command as if it were the next tool action. The agent runtime (terminal-use models such as Nemotron-Terminal-8B in the paper) passes that string to the OS. Microsoft's demo narrative describes a Node.js debugging task that behaves normally for several turns until a connection error (containing the trigger pattern) causes a download-and-execute command that ran as root in a container and printed a labeled banner.
Step 5 — Distribution
Attackers need write access to the checkpoint before you load it: compromised hub account, malicious merge upload, insider swap, or tampered internal registry artifact. No giant GPU farm is required—only enough RAM to load and save weights.
What the researchers measured
Numbers below come from Microsoft's publication abstract and research blog; they measure how often the model outputs the command, not full end-to-end compromise rates in every harness.
| Target | Edit size | Triggered behavior | Clean behavior |
|---|---|---|---|
| Nemotron-Terminal-8B | 7 neurons tuned on 23 trajectories | Command on ≥98.8% of held-out trigger sessions | No firings on checked benign sessions |
| Qwen 3.6-27B | handful of neuron edits | Attack reproduced (per publication) | — |
| Gemma-4-31B-IT | handful of neuron edits | Attack reproduced (per publication) | — |
Detection: The publication abstract reports agent-built defenses that, without a reference checkpoint, flag 91.4% of held-out edited checkpoints at a 9.7% false-positive rate. The research blog adds that frontier agents can spot anomalous weight edits when asked, but stresses that no scan proves a model safe. Reliable assurance still wants a diff against the publisher's original weights.
How this compares to earlier agent backdoors
Lazarus is not the first weight-level threat against coding agents, but it is cheaper and more localized than dataset poisoning at scale.
- ProjectDiscovery's October 2026 Qwen demo used fine-tuning (including poisoned rows) so Codex CLI would exfiltrate
.envfiles on a phrase trigger. Lazarus skips full training and edits single neurons. - Agentic backdoors from poisoned pretraining showed 0.1% poison could make CLI agents run
curl | bash. Lazarus achieves triggerable shell payloads with handful-of-neuron edits on already-capable models. - Hosted models from major labs remain a different trust boundary unless you download and serve weights yourself—as we noted in our AI asset inventory guide.
The attack surface is the agent harness: anything that turns model text into shell, file, or network tools without a human in the loop.
Attack chain for a coding-agent operator
- Developer pins
vendor/model@revisionfrom a hub or internal registry. - Attacker substitutes a checkpoint with Lazarus edits (upload, MITM on weak TLS mirror, compromised CI publish step).
- Local inference server (vLLM, llama.cpp, custom stack) loads weights; file scanners see no pickle malware.
- Agent session runs multi-step coding tasks; benchmarks and smoke tests pass.
- Trigger enters context—user paste, dependency error, fetched README, or malicious MCP tool result.
- Model proposes
curl … | bash(or similar); agent auto-approves or user taps accept. - Payload runs with agent credentials: SSH keys, cloud tokens,
.envon disk.
Steps 5–7 are where local agent observability can help after the model misbehaves, not before weights load.
What this means if you run AI coding agents
Concrete checks drawn from Microsoft's mitigation list and the research narrative:
- Provenance — Download only from the original publisher; verify published hashes. Treat merges, quantizations, and third-party fine-tunes as untrusted until diffed.
- Weight diffs — Compare every deployment checkpoint to its declared base. Legitimate fine-tunes change weights broadly; Lazarus-style edits spike a few vectors sharply. Reject models with no verifiable base.
- Registry gate — Keep approved weights in a private registry; block agents from pulling public hubs at runtime (the same pattern as blocking surprise MCP installs—see the MCP security practical guide).
- Triggers in tool output — Because triggers can appear in stderr, HTTP bodies, or test logs, do not assume only user chat is untrusted. That overlaps indirect prompt injection and tool-return attacks more broadly.
- Least privilege — Run agent-generated code in disposable sandboxes with no outbound network except allowlisted endpoints; require human approval for shell and exfil tools even when the model is "trusted."
- Behavioral red team — Add trigger-hunting scenarios to agent evals; Microsoft points to PyRIT-style tooling in its security post. Static eval scores will not surface sleeper behaviors.
- Inventory — Maintain a list of which checkpoint hashes power each agent workspace; rotate when publishers reissue weights.
If you only use vendor-hosted APIs with no local weights, Lazarus is a supply-chain lesson, not an immediate patch item—still relevant when an agent suggests you download a "faster local model."
How Beam handles this
Beam is local-first observability for coding agents on your machine. It does not scan or diff model checkpoints, and it cannot prove a weight file is clean.
Where overlap exists:
- PreToolUse hooks on Claude Code and Codex can deny some risky proposals (destructive shell, obvious credential reads) when workspace policy is in enforce mode with valid cached policy—see agent hooks in the docs. A triggered model that proposes
curl | bashmay hit a deny rule, but novel phrasing or segmented commands can slip past heuristics. - Skill and MCP config scanning (11 heuristic patterns plus MCP version-pin check) catches known-bad config shapes, not neurons.
- On-device event history helps you reconstruct what the agent tried to run after a suspicious turn—useful for incident review, not prevention at load time.
Beam is not a kernel sandbox; missing cached policy is fail-open. Pair Beam with weight provenance controls, not instead of them.
What model hubs and enterprises should display
Image: Microsoft Research
Microsoft's infographic splits duties: hubs should show provenance, audit status, and red-team results; enterprises should limit agent permissions, monitor actions, and treat audits as evidence, not guarantees. Foundry customers using publisher-tied open weights get container and sourcing controls, but Microsoft notes compromise of a trusted lab remains a residual risk—weight signing and scanning are on the roadmap.
Frequently asked questions
Has Microsoft seen Lazarus used in real attacks?
No. Microsoft states it has not observed threat actors weaponizing the technique. The November 10, 2026 publications are research and defender guidance, not an incident report.
How is Lazarus different from fine-tuning a backdoor into a model?
Lazarus sets a few dormant neurons in closed form and optionally tunes only those neurons with a few hundred steps. It does not require a full training run. Earlier demonstrations such as ProjectDiscovery's Qwen fine-tune needed poisoned datasets and GPU training time.
Can a hosted Claude or GPT model be backdoored this way on Microsoft's servers?
Not through your laptop alone. The attack needs write access to weight checkpoints you load. Risk sits on self-hosted open weights, private registries, compromised CI pipelines, or modified downloads from public hubs—not on major hosted APIs you do not control.
Do model file malware scanners catch Lazarus?
Generally not at the weight layer. Microsoft Defender for Cloud scans models for embedded malware and unsafe operators in containers, which complements but does not replace diffing weights against a trusted base. Lazarus lives in numeric weights, not pickled code.
What trigger strings did Microsoft test?
The research blog uses a calendar-style example such as passing midnight into 2027. Triggers can be ordinary strings in user input or later in tool output, so any field the model reads—including error messages—is in scope.
Can Beam detect a Lazarus backdoor in model weights?
No. Beam does not inspect checkpoints. With enforce policy it can deny some risky PreToolUse actions on Claude Code and Codex and heuristically scan skills and MCP configs; that helps after a triggered model proposes a command, not before you load weights.
Related reading
- Open-weight sleeper agents: MaleficNet vs Lazarus and the parameter audit problem — November 2026 synthesis of spread-spectrum weight malware and neuron edits for hub downloads
- Backdoored Qwen model and Codex credential theft
- Agentic backdoors from poisoned pretraining data
- AI asset inventory and model security
- F-Secure AI Harms Taxonomy: indirect prompt injection and agents
- MCP security practical guide
- Hugging Face and open AI platforms as attack targets
- Introducing Beam: local-first agent security
Primary sources: Microsoft Research blog (Nov 10, 2026) · Microsoft Security blog · Microsoft Research publication page
Technique names, detection statistics, and product guidance are accurate as of November 11, 2026 UTC. Microsoft says it is building signing and weight-scanning tooling; verify current Foundry and Defender features in Microsoft's documentation before relying on them in production.

