CI: harden claude-code-review.yml and claude.yml security/reliability - #39
Open
jnasbyupgrade wants to merge 1 commit into
Open
CI: harden claude-code-review.yml and claude.yml security/reliability#39jnasbyupgrade wants to merge 1 commit into
jnasbyupgrade wants to merge 1 commit into
Conversation
claude-code-review.yml: - Trust gate now checks PR author (user.login), not head repo owner -- head.repo.owner.login is always this repo's own org for upstream-branch-headed PRs, so it silently skipped review regardless of who opened the PR. - Checkout step no longer overrides repository:/ref: to point at the PR's fork -- claude-code-action fetches and reviews the PR's content itself; the override was also breaking that internal fetch. Restored persist-credentials: false on that step. - --allowedTools mcp__github_inline_comment__create_inline_comment so the code-review plugin's agent-mode run actually starts the inline-comment MCP server (was silently falling back to one consolidated comment). - actions: write permission -- no narrower scope exists for cache-write alone; without it, the action's internal cache save silently fails every run. claude.yml: - actions: write (was read) for the same cache-write reason. - actions/checkout@v4 -> @v7.
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Split out from the
advanced-testing/cistack (PR #35) at the user's request -- this is standalone CI hardening, unrelated to that stack's actual content, and needs to land independently/faster.claude-code-review.ymluser.login), not head repo owner --head.repo.owner.loginis always this repo's own org for upstream-branch-headed PRs (e.g.gh stack), so it silently skipped review regardless of who opened the PR. Confirmed via the check-runs API:claude-reviewshowedconclusion: "skipped"on a whole PR stack that was legitimately the trusted account's own work.repository:/ref:to point at the PR's fork --claude-code-actionfetches and reviews the PR's content itself; the override was also breaking that internal fetch (couldn't find remote ref pull/<n>/head). Restoredpersist-credentials: falseon that step (was silently dropped when the override was removed -- same permissions block grantspull-requests: write, a real write-capable credential, with nothing here that legitimately needs it in.git/config).--allowedTools mcp__github_inline_comment__create_inline_commentso the code-review plugin's agent-mode run actually starts the inline-comment MCP server (was silently falling back to one consolidated comment instead of real per-line inline comments).actions: writepermission -- no narrower scope exists for cache-write alone; without it, the action's internal cache save silently fails every run (a warning, not a hard failure, so it looks fine while just being slower/uncached).claude.ymlactions: write(wasread) for the same cache-write reason.actions/checkout@v4->@v7.Test plan