
Semgrep scans the code your agent writes for vulnerabilities, risky dependencies and secrets, so it can fix them before you push.
by semgrep· SecurityUnclaimed · Yours? Claim it
About
Semgrep Guardian is Semgrep's own Claude Code plugin. It scans every file your agent writes or edits with Semgrep Code, Supply Chain and Secrets while it works, and hands any findings back so the agent can rewrite the code before it reaches a pull request. It bundles Semgrep's Guardian MCP server, hooks that run on every file write, and skills. What it does - Scans each file the agent writes or edits for code vulnerabilities, vulnerable dependencies and hardcoded secrets - Returns the findings to the agent, which can regenerate the code until the scan comes back clean, or you can dismiss them - Lets the agent look things up in your Semgrep account through the MCP server, such as your projects and supply chain findings - Helps you write a custom Semgrep rule, add it for yourself or for the whole repository, and prove that it fires, where your Semgrep deployment allows custom rules - Checks its own connection and signs you in again when a sign-in has expired How it connects Install it from Anthropic's plugin marketplace as semgrep@claude-plugins-official. Your first session asks you to sign in to Semgrep in your browser; it's a one-time sign-in, and tokens refresh automatically. It scans with Semgrep's hosted scanner, so you don't need the Semgrep CLI. Semgrep offers the same plugin for Codex, and other setups for agents such as Cursor, GitHub Copilot and Kiro. Good to know - You need a Semgrep account. - The plugin scans with Semgrep's fixed guardian-default ruleset rather than your organization's Policies, so keep running Semgrep in CI. - Its hooks send the files the agent writes, plus lockfiles and manifests, to Semgrep's scanner. Telemetry never includes file contents, and you can turn it off. - It updates itself in the background unless you turn that off. - It also includes a skill that installs Semgrep's Malware Firewall (mfw) CLI.
Plugins people install alongside Semgrep Guardian.
4 images
Once it’s added
“Log in to Semgrep”
“Which Semgrep projects exist in our deployment?”
“List the supply chain findings for this project, with severity and location”
“Write a Semgrep rule that flags our deprecated internal API, add it for this repo and prove it fires”
“Remove the custom rule that keeps flagging our test fixtures”
“Check Guardian's status”
Before you add it
Reads only
Every file the agent writes or edits, scanned for vulnerabilities, risky dependencies and secrets · Your Semgrep projects and findings, through its MCP server
Makes changes · your agent can ask first
Adds or removes custom Semgrep rules in your user or repository rules folder · Saves your Semgrep sign-in on this machine
From people who use it
Step by step
Nothing new reaches your agent until a person has looked at it.
Scanned on every change, and again when our rules improve.
Runs on your machine.
Runs on your machine.
/plugin marketplace add anthropics/claude-plugins-official /plugin install semgrep@claude-plugins-official
Scanned and passed · checked 6 h ago
No reviews yet. Used Semgrep Guardian? Say how it went.
Write a reviewPlugins people install alongside Semgrep Guardian.
Anthropic's security review for Claude Code: flags injection, XSS, secrets and more as Claude edits, finishes a turn and commits.
Equips your coding agent with SAST, dependency scanning, a phased hardening workflow and STRIDE threat-modeling skills.
Alireza Rezvani's Claude Code hook that stops Claude before it writes common security anti-patterns, such as eval, pickle or SQL f-strings.
Microsoft's skills for Azure Data Explorer: build Kusto graphs, compose IRQL threat hunts and turn results into visual graphs.
Nobody has shared how they use Semgrep Guardian yet.
Security scan
Passed
Safe to install in every agent it supports. Claude plugins.