fix: restrict GitHub Actions wildcard permissions to current PR#4
Conversation
Scope gh pr comment permissions to only the PR being reviewed by using PR number variable instead of wildcard. Prevents compromised workflow token from commenting on arbitrary PRs. Resolves #2 Co-Authored-By: GLM <zai-org@users.noreply.github.com>
SummaryThis PR addresses a critical security vulnerability by restricting the GitHub Actions workflow's Overall Assessment: ✅ Strong Approve Key Strengths:
Key Concerns:
Detailed Feedback1. Understanding & IntentWhat is this PR trying to accomplish? Does the title and description clearly communicate the purpose? Are the changes scoped appropriately, or should this be split? Does the PR link to relevant issues/tickets? 2. Code Quality AssessmentArchitecture & DesignIs the solution well-architected? Are there any code smells or design issues? Code CorrectnessLogic correctness: Edge cases: Potential bugs: Security & SafetySecurity concerns: Before: This is a proper implementation of the principle of least privilege. 3. Testing CoverageAre there tests for the new functionality? Do existing tests still pass? 4. Documentation & ImpactCode documentation: User-facing documentation: 5. Performance & Scalability✅ No impact. This change has no performance or resource usage implications. 6. Maintainability & ReadabilityReadability: Extensibility: 7. Specific Line-by-Line FeedbackWhat's Done Well.github/workflows/claude-code-review.yml:56
Commit message:
PR description:
Action ItemsRequired Before MergeNone. This PR is ready to merge. Recommended ImprovementsNone. This is a well-crafted security fix. Optional Considerations
VerdictThis PR is well-crafted and ready to merge. The change is minimal, focused, and directly addresses a documented security vulnerability. The implementation follows GitHub Actions best practices and the principle of least privilege. Excellent work on identifying and fixing this security issue! Reviewed by: Droid - GLM 4.7 |
|
Approved. Solid security fix—restricts GitHub Actions wildcard permissions to the current PR only. Strengths:
No issues identified. Ready to merge. Reviewed by: Amp Code |
Merge SuccessfulSummary: PR merged to Changes:
Issues resolved: #2 🤖 Generated by Claude Code - GLM 4.7 |
Scope gh pr comment permissions to only the PR being reviewed by using PR number variable instead of wildcard. Prevents compromised workflow token from commenting on arbitrary PRs. Resolves #2 Co-authored-by: GLM <zai-org@users.noreply.github.com>
…etchgqc#43) * fix: restrict GitHub Actions wildcard permissions to current PR (#4) Scope gh pr comment permissions to only the PR being reviewed by using PR number variable instead of wildcard. Prevents compromised workflow token from commenting on arbitrary PRs. Co-authored-by: GLM <zai-org@users.noreply.github.com> * feat: add global .env file support (#8) Add support for ~/.agentbox/.env that loads before project-specific .env files. This enables centralized configuration for API keys and custom inference endpoints across all projects. Changes: - Load ~/.agentbox/.env first, then PROJECT_DIR/.env - Project env vars override global vars (Docker's last-wins behavior) - Add log message for discoverability when global .env is loaded - Document global .env usage in README with examples Co-authored-by: GLM <zai-org@users.noreply.github.com>
Summary
Security Impact
Prevents compromised workflow token from commenting on arbitrary PRs.
Related
Resolves #2
🤖 Generated by Claude Code - GLM 4.7