Skip to content

Commit 95c2077

Browse files
nedtwiggclaude
andcommitted
Pass --allowed-tools to security-audit's Claude invocation
The default tool allowlist in claude-code-action excludes Bash and Write, so the auditing prompt's attempts to run `gh api` and produce the report files were denied 38 times in run 26306994059. Claude exited with a "success" subtype despite the denials, so the workflow proceeded without audit-status.txt and the issue-reporting step treated it as a failure. Pass --allowed-tools "Read,Write,Edit,Bash,Grep,Glob" via the action's claude_args input so the audit can actually exercise the tools the prompt asks for. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 833fdbb commit 95c2077

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

.github/workflows/security-audit.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ permissions:
1515
actions: read
1616
issues: write
1717
id-token: write
18+
administration: read
1819

1920
jobs:
2021
audit:
@@ -42,6 +43,12 @@ jobs:
4243
GH_TOKEN: ${{ github.token }}
4344
with:
4445
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
46+
# Without an explicit allowlist the action defaults to a
47+
# restrictive set that excludes Bash and Write, so an
48+
# auditing prompt that wants to run `gh api` and produce a
49+
# report file racks up permission denials and exits without
50+
# writing audit-status.txt.
51+
claude_args: '--allowed-tools "Read,Write,Edit,Bash,Grep,Glob"'
4552
prompt: |
4653
You are auditing this repository against SECURITY.md. The
4754
specifications are concrete `FAIL IF` lines plus the

0 commit comments

Comments
 (0)