<feed xmlns='http://www.w3.org/2005/Atom'>
<title>claude-plugins-official.git/plugins/security-guidance/tests/conftest.py, branch bump/cloud-sql-sqlserver</title>
<subtitle>Official Claude Code plugin directory
</subtitle>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/claude-plugins-official.git/'/>
<entry>
<title>Merge remote-tracking branch 'origin/main' into mhegazy/sg-secret-rename-pairing</title>
<updated>2026-10-27T20:03:52+00:00</updated>
<author>
<name>Mohamed Hegazy</name>
<email>mhegazy@anthropic.com</email>
</author>
<published>2026-10-27T20:03:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/claude-plugins-official.git/commit/?id=3654d346b45836e43e013b849be19233ff0efbc3'/>
<id>3654d346b45836e43e013b849be19233ff0efbc3</id>
<content type='text'>
# Conflicts:
#	plugins/security-guidance/hooks/diffstate.py
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
# Conflicts:
#	plugins/security-guidance/hooks/diffstate.py
</pre>
</div>
</content>
</entry>
<entry>
<title>security-guidance: let the test API stub serve servers that keep no request bodies</title>
<updated>2026-10-22T00:15:56+00:00</updated>
<author>
<name>Mohamed Hegazy</name>
<email>mhegazy@anthropic.com</email>
</author>
<published>2026-10-22T00:15:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/claude-plugins-official.git/commit/?id=45bb3d5c14f7c20c9bdc9a30e798cf0d77467e2e'/>
<id>45bb3d5c14f7c20c9bdc9a30e798cf0d77467e2e</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>security-guidance: report why a review call got no HTTP response</title>
<updated>2026-10-20T23:15:10+00:00</updated>
<author>
<name>Mohamed Hegazy</name>
<email>8000722+mhegazy@users.noreply.github.com</email>
</author>
<published>2026-10-20T23:14:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/claude-plugins-official.git/commit/?id=073448767f5ef6ea935cded3d6f712e843f5d268'/>
<id>073448767f5ef6ea935cded3d6f712e843f5d268</id>
<content type='text'>
A review call that never gets an HTTP response is reported as api_error -1
whatever the cause, so a certificate failure, a refused connection and a
timeout look the same. Rows whose last call failed that way now carry a
count-only net_err key: the failure class, the TLS verify code, and whether
CA files, a proxy or TLS variables are in play. No behaviour change.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
A review call that never gets an HTTP response is reported as api_error -1
whatever the cause, so a certificate failure, a refused connection and a
timeout look the same. Rows whose last call failed that way now carry a
count-only net_err key: the failure class, the TLS verify code, and whether
CA files, a proxy or TLS variables are in play. No behaviour change.
</pre>
</div>
</content>
</entry>
<entry>
<title>security-guidance: keep a renamed file paired with its old name in the Stop review</title>
<updated>2026-10-20T22:51:59+00:00</updated>
<author>
<name>Mohamed Hegazy</name>
<email>mhegazy@anthropic.com</email>
</author>
<published>2026-10-20T22:51:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/claude-plugins-official.git/commit/?id=3725318ee5052793cbbafd8b92edbdba771ce03a'/>
<id>3725318ee5052793cbbafd8b92edbdba771ce03a</id>
<content type='text'>
The Stop review limits its diff to the changed paths. For a rename that git
already knows about (git mv, or a rename committed during the turn) that list
held only the new name, so the diff showed a new file and the parsers could
not apply the rule that leaves out a file renamed away from a secret-shaped
name. The old name now goes into the list beside the new one, as it already
did for a plain mv.

The file listings themselves are unchanged.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The Stop review limits its diff to the changed paths. For a rename that git
already knows about (git mv, or a rename committed during the turn) that list
held only the new name, so the diff showed a new file and the parsers could
not apply the rule that leaves out a file renamed away from a secret-shaped
name. The old name now goes into the list beside the new one, as it already
did for a plain mv.

The file listings themselves are unchanged.
</pre>
</div>
</content>
</entry>
<entry>
<title>security-guidance: let the tests that start a stand-in claude run on Windows</title>
<updated>2026-10-19T21:53:45+00:00</updated>
<author>
<name>Mohamed Hegazy</name>
<email>mhegazy@anthropic.com</email>
</author>
<published>2026-10-19T20:57:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/claude-plugins-official.git/commit/?id=8680640bffd91d9a7fc33ad1ede46a031d36abef'/>
<id>8680640bffd91d9a7fc33ad1ede46a031d36abef</id>
<content type='text'>
The tests' stand-ins for claude were files with a #! line, which Windows
cannot start, so the gateway sign-in tests and the inner-CLI warning test
failed there. On Windows a stand-in is now an .exe built the way pip
builds a console script, and the gateway one writes its call log as
UTF-8. Two tests that move the home directory also set USERPROFILE, and
the one test that needs the Agent SDK without saying so is skipped
without it.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The tests' stand-ins for claude were files with a #! line, which Windows
cannot start, so the gateway sign-in tests and the inner-CLI warning test
failed there. On Windows a stand-in is now an .exe built the way pip
builds a console script, and the gateway one writes its call log as
UTF-8. Two tests that move the home directory also set USERPROFILE, and
the one test that needs the Agent SDK without saying so is skipped
without it.
</pre>
</div>
</content>
</entry>
<entry>
<title>security-guidance: review through Claude Code in a Claude apps gateway sign-in</title>
<updated>2026-10-19T17:05:01+00:00</updated>
<author>
<name>Mohamed Hegazy</name>
<email>mhegazy@anthropic.com</email>
</author>
<published>2026-10-19T15:37:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/claude-plugins-official.git/commit/?id=e0d9e154cc7c8d545f5d78c2f51fb9c0dc655b08'/>
<id>e0d9e154cc7c8d545f5d78c2f51fb9c0dc655b08</id>
<content type='text'>
In a Claude Code session signed in to a Claude apps gateway with /login,
Claude Code gives plugin hooks no credential, so the Stop, commit, push
and agentic commit reviews were all skipped.

When the plugin has no credential of its own, it now asks the user's
installed claude (`claude auth status --json`) whether the session is
signed in to a gateway. A yes or no is kept for the session; when the CLI
gives no usable answer, the next hook asks again. If apiProvider is
"gateway" and loggedIn is true, the reviews run through that same CLI,
which restores the stored sign-in by itself, so no credential enters the
plugin. A review the CLI cannot complete counts as a failed review, never
a clean one. The reviews run even with
CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC set, as they do on Bedrock and
Vertex: the gateway docs suggest setting it, and the review goes through
the gateway like the session's own requests.

The CLI is found the way the agentic reviewer already finds it:
SG_AGENTIC_CLI_PATH, CLAUDE_CODE_EXECPATH, then fixed install paths, with
no PATH search, and it must be a full path. The reviews use Claude Code's
opus and sonnet aliases, which resolve to the ids Claude Code itself uses
on a gateway, and get the 120 s a direct review gets. Review rows set bit
4 of gateway_cfg, so this route's failure rate can be read apart from
first-party reviews.

Every Claude Code the plugin starts for a review, on any provider, now
runs with SECURITY_GUIDANCE_DISABLE=1. If policy settings enable the
plugin inside that CLI, its hooks there don't start reviews of their own.

The weekly notice that the reviews are not running is no longer shown in
a session signed in to a gateway, since the reviews do run there. The
edit that would show it asks claude first, and the notice marker is
written either way, so that edit waits for claude at most once a week.
Sessions the gateway route cannot review still get the notice, unless,
in the past week, an edit's check found a session signed in to a
gateway. Their skipped reviews still report no_creds.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In a Claude Code session signed in to a Claude apps gateway with /login,
Claude Code gives plugin hooks no credential, so the Stop, commit, push
and agentic commit reviews were all skipped.

When the plugin has no credential of its own, it now asks the user's
installed claude (`claude auth status --json`) whether the session is
signed in to a gateway. A yes or no is kept for the session; when the CLI
gives no usable answer, the next hook asks again. If apiProvider is
"gateway" and loggedIn is true, the reviews run through that same CLI,
which restores the stored sign-in by itself, so no credential enters the
plugin. A review the CLI cannot complete counts as a failed review, never
a clean one. The reviews run even with
CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC set, as they do on Bedrock and
Vertex: the gateway docs suggest setting it, and the review goes through
the gateway like the session's own requests.

The CLI is found the way the agentic reviewer already finds it:
SG_AGENTIC_CLI_PATH, CLAUDE_CODE_EXECPATH, then fixed install paths, with
no PATH search, and it must be a full path. The reviews use Claude Code's
opus and sonnet aliases, which resolve to the ids Claude Code itself uses
on a gateway, and get the 120 s a direct review gets. Review rows set bit
4 of gateway_cfg, so this route's failure rate can be read apart from
first-party reviews.

Every Claude Code the plugin starts for a review, on any provider, now
runs with SECURITY_GUIDANCE_DISABLE=1. If policy settings enable the
plugin inside that CLI, its hooks there don't start reviews of their own.

The weekly notice that the reviews are not running is no longer shown in
a session signed in to a gateway, since the reviews do run there. The
edit that would show it asks claude first, and the notice marker is
written either way, so that edit waits for claude at most once a week.
Sessions the gateway route cannot review still get the notice, unless,
in the past week, an edit's check found a session signed in to a
gateway. Their skipped reviews still report no_creds.
</pre>
</div>
</content>
</entry>
<entry>
<title>security-guidance: print one JSON document from the SessionStart hook on other hosts</title>
<updated>2026-10-15T16:31:46+00:00</updated>
<author>
<name>Mohamed Hegazy</name>
<email>mhegazy@anthropic.com</email>
</author>
<published>2026-10-15T16:31:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/claude-plugins-official.git/commit/?id=ced6733eee6aa246e2af55ce0c71e38c01a50141'/>
<id>ced6733eee6aa246e2af55ce0c71e38c01a50141</id>
<content type='text'>
On a host other than Claude Code the SessionStart hook printed an async
declaration line and then a metrics line. A host that reads hook output as
one JSON document with a closed schema rejects that.

In portable mode the hook now skips the async line and prints one object
with only the standard fields. The portable-mode helpers move to _base.py so
both hook scripts share them, and the mode is decided once at start-up.
Output under Claude Code is unchanged.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
On a host other than Claude Code the SessionStart hook printed an async
declaration line and then a metrics line. A host that reads hook output as
one JSON document with a closed schema rejects that.

In portable mode the hook now skips the async line and prints one object
with only the standard fields. The portable-mode helpers move to _base.py so
both hook scripts share them, and the mode is decided once at start-up.
Output under Claude Code is unchanged.
</pre>
</div>
</content>
</entry>
<entry>
<title>security-guidance: never report a failed review as clean</title>
<updated>2026-10-09T16:04:18+00:00</updated>
<author>
<name>Mohamed Hegazy</name>
<email>mhegazy@anthropic.com</email>
</author>
<published>2026-10-08T01:00:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/claude-plugins-official.git/commit/?id=3057edc902d79b2ddedd4043c566b0b6dceb4ca3'/>
<id>3057edc902d79b2ddedd4043c566b0b6dceb4ca3</id>
<content type='text'>
When a commit review got no verdict (an API error, an unexpected error in
the call, or a reply that could not be read) it was logged as "no security
issues found" and the commit was marked reviewed, so the push review
skipped it (anthropics/claude-code#99840, also anthropics/claude-code#81057).

- A commit whose review got no verdict is not marked reviewed, so a later
  push review from Claude Code still checks it, unless the same command
  pushed it. A failed push review does not mark its range either.
- Claude is told once per session for each kind of review and failure.
  Later failures of the same kind are only logged.
- In the agentic race, a single-shot fallback with no verdict no longer
  wins while the agentic review can still answer, the fallback no longer
  starts after the agentic review has answered, and it never runs twice.
- The Stop and SubagentStop reviews use the same signal, so an unreadable
  reply no longer records a subagent's diff as reviewed.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When a commit review got no verdict (an API error, an unexpected error in
the call, or a reply that could not be read) it was logged as "no security
issues found" and the commit was marked reviewed, so the push review
skipped it (anthropics/claude-code#99840, also anthropics/claude-code#81057).

- A commit whose review got no verdict is not marked reviewed, so a later
  push review from Claude Code still checks it, unless the same command
  pushed it. A failed push review does not mark its range either.
- Claude is told once per session for each kind of review and failure.
  Later failures of the same kind are only logged.
- In the agentic race, a single-shot fallback with no verdict no longer
  wins while the agentic review can still answer, the fallback no longer
  starts after the agentic review has answered, and it never runs twice.
- The Stop and SubagentStop reviews use the same signal, so an unreadable
  reply no longer records a subagent's diff as reviewed.
</pre>
</div>
</content>
</entry>
<entry>
<title>Adjust SubagentStop handling and repository precedence</title>
<updated>2026-09-09T16:46:55+00:00</updated>
<author>
<name>Octavian Guzu</name>
<email>oct@anthropic.com</email>
</author>
<published>2026-09-09T16:46:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/claude-plugins-official.git/commit/?id=f03d41e2c96f30b7b59a05566e998e6236a943e7'/>
<id>f03d41e2c96f30b7b59a05566e998e6236a943e7</id>
<content type='text'>
- SubagentStop reviews without consuming or advancing the session's
  Stop state; an identical diff is not reviewed twice.
- SubagentStop from a different working tree than the project is skipped.
- An explicit `git -C &lt;dir&gt;` / `cd &lt;dir&gt;` naming another repository takes
  precedence over the hook cwd.
- Narrows the `git -C … commit` matcher; keeps Windows path separators
  when tokenizing; adds `--no-textconv` to diff/show invocations.
- Adds tests.

:house: Remote-Dev: homespace
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- SubagentStop reviews without consuming or advancing the session's
  Stop state; an identical diff is not reviewed twice.
- SubagentStop from a different working tree than the project is skipped.
- An explicit `git -C &lt;dir&gt;` / `cd &lt;dir&gt;` naming another repository takes
  precedence over the hook cwd.
- Narrows the `git -C … commit` matcher; keeps Windows path separators
  when tokenizing; adds `--no-textconv` to diff/show invocations.
- Adds tests.

:house: Remote-Dev: homespace
</pre>
</div>
</content>
</entry>
<entry>
<title>security-guidance: resolve repository from command and edited paths (2.0.7 → 2.0.8)</title>
<updated>2026-09-09T13:41:46+00:00</updated>
<author>
<name>Octavian Guzu</name>
<email>oct@anthropic.com</email>
</author>
<published>2026-09-09T13:41:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.1991861.xyz/claude-plugins-official.git/commit/?id=0b2f3e30a9c6f6e5ed7ca72408ffb957103174ca'/>
<id>0b2f3e30a9c6f6e5ed7ca72408ffb957103174ca</id>
<content type='text'>
- Adds repository resolution from `git -C &lt;dir&gt;` / `cd &lt;dir&gt;` in the hook
  command, from the commit SHA, and from edited file paths when the hook
  cwd is not a git repository.
- Adds PostToolUse matchers for `git -C … commit|push`.
- Registers SubagentStop.
- Adds `repo_resolution` / `cwd_is_repo` metric fields.
- Adds tests.

:house: Remote-Dev: homespace
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- Adds repository resolution from `git -C &lt;dir&gt;` / `cd &lt;dir&gt;` in the hook
  command, from the commit SHA, and from edited file paths when the hook
  cwd is not a git repository.
- Adds PostToolUse matchers for `git -C … commit|push`.
- Registers SubagentStop.
- Adds `repo_resolution` / `cwd_is_repo` metric fields.
- Adds tests.

:house: Remote-Dev: homespace
</pre>
</div>
</content>
</entry>
</feed>
