A Security Review on Every Pull Request
Anthropic's claude-code-security-review won't catch every security bug. It reads one pull request at a time and reports the risks that change adds — the real question isn't total coverage, it's what this specific change introduces.
Anthropic's claude-code-security-review won't catch every security bug. It reads one pull request at a time and reports the risks that change adds — the real question isn't total coverage, it's what this specific change introduces.
Three terms first. A pull request: a proposed change, waiting for review before it's merged. The diff: just the lines a change adds or removes. A false positive: a flagged problem that isn't real.
Picture a pull request as a crate on a belt, on its way to being merged. The security review is a GitHub Action, a job GitHub runs when a pull request opens, putting Claude over the belt as a security reviewer. Only the changed files go under review — most of the repo stays behind. Claude can read the rest for context, but it's told to report only what this pull request adds, not old problems already in the codebase.
The changed files pass under the scanner: Claude reads them for meaning, not just patterns, looking for things like injection, broken authentication, exposed secrets, and weak crypto. Each suspect becomes a finding — the line, how serious, how it could be exploited, and a fix. Before anything posts, a filter catches likely false positives: hard rules drop low-impact kinds like denial of service and rate limits, then Claude re-checks each remaining finding and drops the ones it isn't confident in. The prompt puts it plainly: better to miss a theoretical issue than flood you with false positives.
What's left lands on the pull request as review comments, pinned to the exact lines, each with a thumbs up and thumbs down. Then a person decides — the action posts comments, it doesn't approve the pull request, and it doesn't merge it. You read each comment, fix what's real, dismiss what isn't.
The same review also runs locally: Claude Code ships a slash command, /security-review, that reviews the pending changes on your branch. Copy it into your project, and you can tune it.
One caution, in the repo's own words: the action is not hardened against prompt injection. A pull request could carry text written to steer the reviewer — so run it only on trusted pull requests, and have a maintainer approve outside contributors before their workflows run.
Your Turn: Paste into Claude Code: "Add anthropics/claude-code-security-review to this repo as a GitHub Action. Trigger it on pull requests only, read the API key from a repository secret, and exclude our vendored and generated folders. It must never run on untrusted pull requests, so tell me how to require approval for outside contributors. I'll treat its comments as leads to check, not verdicts." Then check two things yourself: does the workflow run on pull requests only with the key in a secret, and in your repo settings, do outside contributors need approval?
Source: Anthropic, claude-code-security-review (README, action.yml, and the review prompt)
0:00 The question, and three terms 0:23 A crate on a belt 0:35 Only the changed files 0:47 Under the scanner 1:02 Filtering false positives 1:15 Comments on the pull request 1:27 A person decides 1:37 /security-review 1:48 The prompt-injection caution 2:04 Your turn
Part of the Claude & Agentic AI series. @NikBearBrown
Deliberately Not Claimed
This video summarizes Anthropic's own published README, action configuration, and review prompt for claude-code-security-review, and does not claim to introduce new mechanics or supersede that source. It does not claim this tool catches every security vulnerability, replaces human security review, or is safe to run on untrusted pull requests — the repository itself states it is not hardened against prompt injection. Check the linked repository for the current, authoritative details.
Production Credits
Fully AI-generated production — no human-performed audio or video.
Narration: Liam (Kokoro am_onyx) Animation & motion graphics: Manim, Remotion Credit line: @NikBearBrown Hashtags
SEO Keyword Tags
claude-code-security-review, Claude Code security, GitHub Action security review, pull request security scan, AI code review security, prompt injection warning, application security automation, Claude Code /security-review, GitHub Actions Claude, AI security findings not verdicts, false positive filtering AI, secure code review workflow, Anthropic security tools, DevSecOps AI, automated PR security scan
What this video covers
- 0:00 — The question, and three terms 0:23 A crate on a belt 0:35 Only the changed files 0:47 Under the scanner 1:02 Filtering false positives 1:15 Comments on the pull request 1:27 A person decides 1:37 /security-review 1:48 The prompt-injection caution 2:04 Your turn
Transcript
A lightly formatted transcript of the video, with timestamps so you can jump to any section on YouTube.
The question, and three terms 0:23 A crate on a belt 0:35 Only the changed files 0:47 Under the scanner 1:02 Filtering false positives 1:15 Comments on the pull request 1:27 A person decides 1:37 /security-review 1:48 The prompt-injection caution 2:04 Your turn
[0:00] Guten Tag. This is Liam in for Bear. Anthropic's Claude Code Security Review won't catch every security bug. It reads one pull request at a time and only what changed. So, the real question is the risks this change adds. A pull request, a proposed change waiting for review before it's merged. The diff, just the lines a change adds or removes. And a false positive, a flagged problem that isn't real. Here's a pull request, a crate on a belt on its way to being merged. The security review is a GitHub action, a job GitHub runs when a pull request opens. It puts Claude over the belt as a security reviewer. Open the crate, most of the repo stays behind. Only the changed files go under review. Claude can read the rest for context, but it's told to report only what this pull request adds, not old problems. The changed files pass under the scanner. Claude reads them for meaning, not
Just patterns, looking for things like injection, broken authentication, exposed secrets, and weak crypto. Each suspect becomes a finding, the line, how serious, how it could be exploited, and a fix. Before anything is posted, a filter catches likely false positives. Hard rules drop low-impact kinds like denial of service and rate limits. Then Claude rechecks each finding and drops the ones it isn't confident in. What's left lands on the pull request as review comments pinned to the exact lines, each with a thumbs up and a thumbs down. The prompt puts it plainly, better to miss a theoretical issue than flood you with false positives. Then a person decides the action posts the comment review. It doesn't approve the pull request, and it doesn't merge it. You read each comment, fix what's real, and dismiss what isn't. You can also run the same review yourself. Claude Code ships a slash command, slash security review, that reviews the pending changes on your
Branch. Copy it into your project, and you can tune it. One caution in the repo's own words, the action is not hardened against prompt injection. A pull request could carry text written to steer the reviewer. So, run it only on trusted pull requests and have a maintainer approve outside contributors before their workflows run. Your turn. Paste this into Claude Code. Add Anthropic's Claude Code security review to this repo as a GitHub action. Trigger it on pull requests only. Read the API key from repository secret and exclude our vendored and generated folders. It must never run on untrusted pull requests. So, tell me how to require approval for outside contributors. I'll treat its comments as leads to check, not verdicts. Then, check two things yourself. Does the workflow run on pull requests only with the key in a secret? And in your repo settings, do outside contributors need approval? A security review on every pull request at Nick Bear Brown.





