Answer: When your branch has commits its base doesn't, the `/claude-security` menu offers to scan only that diff, so you can check a branch before merging. You can also scan one of your open pull requests, or a single commit by asking for it, such as "scan commit abc1234". Status: Confirmed Entry: tool/claude-code/features/scan-only-changes Revision: 1 Digest: sha256:00d99e479ffea0dd (changes whenever the content changes) Timeline: Created: 2026-11-13T03:03:36Z Last changed: 2026-11-13T03:03:36Z Last verified: 2026-11-20T12:19:04Z Next check: 2026-11-21T12:19:04Z Check interval: Daily Expected change: No fixed schedule Data: Field | Value | Source | As of diff scan option | scan only that diff | [1] | 2026-11-20 pull request scan | scan one of your open pull requests | [1] | 2026-11-20 single commit example | scan commit abc1234 | [1] | 2026-11-20 committed changes only | Only committed changes are scanned | [1] | 2026-11-20 git requirement | Change scans need a git repository | [1] | 2026-11-20 pull request discovery requirement | permission to run the GitHub CLI | [1] | 2026-11-20 Sources: [1] Anthropic. "Scan your codebase for vulnerabilities". https://code.claude.com/docs/en/claude-security.md Role: primary. Accessed: 2026-11-20T12:19:04Z Quote: "the `/claude-security` menu offers to scan only that diff" (Supports: diff scan option) Quote: "You can also scan one of your open pull requests" (Supports: pull request scan) Quote: "a single commit by asking for it, such as "scan commit abc1234"" (Supports: single commit example) Quote: "Only committed changes are scanned: commit or stash in-progress edits first" (Supports: committed changes only) Quote: "Change scans need a git repository; full scans of an unversioned directory still work." (Supports: git requirement) Quote: "Finding your open pull requests is offered only when your session already has permission to run the GitHub CLI and `gh` is signed in." (Supports: pull request discovery requirement) Published: 2026-11-20T03:10:57Z Snapshot SHA-256: 066e0c992efe84f483e98caecd1b0d9166cffbb694fd8ad1d02bf49031aa4fc3 (captured 2026-11-13T03:03:36Z) Verification: Method: Automated extraction from [1] with deepseek-flash (JSON output, thinking disabled). Every value was checked by code to appear verbatim in a quoted passage of [1]. On this check the text of [1] was unchanged since 2026-11-13T03:03:36Z, so the values verified then were kept. Cross-check: not-available at 2026-11-20T12:19:04Z. No independent second source is configured for this entry Last successful check: 2026-11-20T12:19:04Z Last attempt: 2026-11-20T12:19:04Z Notes and limitations: Extracted automatically from a single official source (section "Scan only your changes"). Related: https://latestn.com/tool/claude-code/features/session-own-worktree How do I run a Claude Code Desktop session in its own Git worktree? https://latestn.com/tool/claude-code/features/share-artifact How do I share a Claude Code artifact with my organization or a public link? https://latestn.com/tool/claude-code/features/sparse-worktrees-checkout-directories How do I set up sparse worktrees in Claude Code to check out only needed directories? https://latestn.com/tool/claude-code/features/review-md-include-files-skill How do I include a skill file or other files in Claude Code REVIEW.md? https://latestn.com/tool/claude-code/features/review-md-review-only-rules How do I use REVIEW.md to skip paths or add review-only rules in Claude Code Code Review? https://latestn.com/tool/claude-code/features/review-severity-levels What do the severity levels mean in Claude Code review findings? https://latestn.com/tool/ All entries in AI tools Change log: Time | Event | Change | Source 2026-11-13T03:03:36Z | added | Entry created | — Changes for this entry as a feed: https://latestn.com/tool/claude-code/features/scan-only-changes/latest Challenge this entry: Open challenges: None How: If a value here is wrong or out of date, send what is wrong and a link to evidence. Challenges are queued and checked against the evidence; they do not change the entry by themselves. If the entry changes as a result, the change log says so. Form: https://latestn.com/dispute/tool/claude-code/features/scan-only-changes POST: https://latestn.com/dispute/tool/claude-code/features/scan-only-changes with claim, evidence_url, and optionally field and contact (form-encoded or JSON) GET: https://latestn.com/dispute/tool/claude-code/features/scan-only-changes?claim={what is wrong}&evidence_url={link} How to cite: LatestN. (2026). How do I scan only my changes or a pull request diff for vulnerabilities in Claude Code? Revision 1, last verified 2026-11-20T12:19:04Z. https://latestn.com/tool/claude-code/features/scan-only-changes (accessed 2026-11-21T09:52:32Z). @misc{LatestN_tool_claude_code_features_scan_only_changes_r1, title = {How do I scan only my changes or a pull request diff for vulnerabilities in Claude Code?}, author = {{LatestN}}, year = {2026}, howpublished = {\url{https://latestn.com/tool/claude-code/features/scan-only-changes}}, note = {Revision 1; digest sha256:00d99e479ffea0dd; last verified 2026-11-20T12:19:04Z; accessed 2026-11-21T09:52:32Z} } Reuse: License: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/) Attribution: Copying and adapting are allowed, including commercially, if you credit LatestN and link to the entry you used. Each entry ends with a ready-made citation. URL: https://latestn.com/tool/claude-code/features/scan-only-changes