← All lab updates
One gate for every Claude Code in the company
How a security team puts the same deterministic gate in front of every developer's Claude Code, through the managed settings that no user or project file can override, and what it gets back: one rule set, one decision log, one count.
## The problem
Coding agents arrive in a company one laptop at a time. Each developer sets their own permissions, approves their own commands, and nobody sees the whole picture. A security team cannot write a policy for something it cannot enforce or read.
## The setting that makes it a policy
Claude Code reads a **managed settings** layer that the organisation controls: a file placed by IT, a device-management profile, or settings delivered from the Claude admin console. Nothing in a user's or a project's own files overrides a managed key. Two keys matter here:
- **the gate hook, set in managed settings**: every machine sends every command to the gate before it runs;
- **`allowManagedHooksOnly`**: only the hooks the organisation deploys run, so nobody replaces or bypasses the gate with a hook of their own.
`strictKnownMarketplaces` can also limit which plugin sources developers install from.
## What the security team gets
- **One rule set** for every machine, written as rules you can read: refused, allowed, or held for a person. The same command in the same session always gets the same answer.
- **The person in the loop where it matters**: pushes, unpinned packages, changes to cloud resources, a network call after a secret was read. The developer approves in Claude Code's own prompt; the approval is logged with the action.
- **One decision log and one count**: what agents tried, what was refused, what a person approved. That record is what an audit asks for.
- **The agent cannot switch it off**: the check runs in Claude Code's harness, not in the model, and the rules refuse edits to the gate's own settings.
## How to start
Run the gate in shadow mode on a few machines for a week: it records what it would have decided and blocks nothing. Read the count with the teams, then turn on enforce mode through managed settings.
This update is not available.