# /security-review Command

> It looks at your changes for holes that let bad people in.

**Field:** Artificial Intelligence  
**Category:** Claude Code  
**Also known as:** /security-review, Security review

## Think of it like

It is like a guard who checks each new door for a weak lock.

## Definition

/security-review checks the changes on your branch for security holes. It compares your branch with the default branch on origin. It looks for risks such as injection, broken login checks and data that leaks out. It only reads what changed, not the whole project. It needs a remote named origin.

## Example

Jack adds a search box that builds a database query. /security-review warns that the text goes into the query unchecked. That is SQL injection.

## Example code

```console
/security-review
```

Check this branch's changes for security risks.

## Why it matters

Security bugs rarely break a test, so they slip through. A review aimed at them catches more.

## Common mistake

Thinking it checks the whole project. It reads only the diff against the default branch, so old code is not looked at.

## Three principles

- **Security only.** Not every bug.
- **Your branch's diff.** Against origin.
- **Needs origin.** A git remote.

## Related terms

- [/code-review Command](https://learn.benibix.com/term/ai/code-review-command)
- [Code Review](https://learn.benibix.com/term/development/code-review)
- [Claude Code Review](https://learn.benibix.com/term/ai/claude-code-review)

## Taught in

- [Diff and Code Review](https://learn.benibix.com/learn/ai-claude-code-commands/diff-and-code-review): Claude Code Commands, 8/17

![Three review commands side by side: /code-review looks for bugs, /simplify looks for cleanups and fixes them, /security-review looks for security risks.](https://learn.benibix.com/diagrams/cmd-review-commands.svg)

---

Source: https://learn.benibix.com/term/ai/security-review-command
Author: Behnia Zarei (a developer in Vienna, Austria, who builds and teaches data, AI and business intelligence at BENIBIX)
Publisher: BENIBIX Learn (https://learn.benibix.com/)
Last updated: 2026-11-17
Licence: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Quote freely with attribution.
