Skip to content

Update dependencies to latest and add gitleaks secret scanning - #18

Merged
valuecodes merged 3 commits into
mainfrom
feat/deps-update-secrets-scan
Sep 26, 2026
Merged

valuecodes merged 3 commits into
mainfrom
feat/deps-update-secrets-scan

Conversation

@valuecodes

Copy link
Copy Markdown
Owner

What

  • Add a gitleaks secrets-scan CI job on PRs and on pushes to main, plus a pnpm secrets:scan script. Both are copied from agentic-monorepo-starter. The AI resolve-pr-comments job now waits for the scan to pass.
  • Bring all dependencies up to the newest release at least 14 days old. Majors: @openai/agents 0.3.7 → 0.18.0, vitest 5, jsdom 30, marked 18, slug 12, stream-json 3. @types/node stays on 24.x to match the Node 24 runtime.
  • @openai/agents 0.18 types plain JSON-schema tool input as unknown, so the six sandbox tools now define their parameters as zod schemas. This also validates model input at runtime. AgentRunner.run now infers its return type.

How to test

pnpm install --frozen-lockfile
pnpm typecheck
pnpm lint
pnpm format:check
pnpm test
pnpm secrets:scan
pnpm run:guestbook

Security review

  • Secret scanning added: gitleaks is pinned by version and image digest, the job runs with contents: read, and the checkout doesn't keep credentials.
  • Tool input validation tightened: sandbox file/fetch/python tools now reject malformed model arguments at runtime (zod); path and SSRF protections are unchanged.

🤖 Generated with Claude Code

valuecodes and others added 2 commits September 26, 2026 08:03
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Copilot AI lite review requested due to automatic review settings September 26, 2026 05:11

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 3d6101884c

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread package.json

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

Unresolved critical and moderate findings remain around secret-scan integrity, runtime compatibility, output handling, and tool schema validation.

Review effort: Lite
Findings: 1 High severity · 2 Medium severity · 1 Low severity

Open (4)
What changed in this PR

This PR upgrades dependencies, adds gitleaks scanning, and migrates sandbox tools to Zod schemas.

Changes:

  • Adds local and CI secret scanning.
  • Updates dependencies and lockfile.
  • Adds runtime tool-input validation and adjusts result handling.
File Reviewed changes
src/​tools/​write-file/​write-file-tool.ts Zod parameters and write-file tests
src/​tools/​utils/​test-utils.ts Generalized tool test helper
src/​tools/​run-python/​run-python-tool.ts Zod parameters and Python execution handling
src/​tools/​read-file/​read-file-tool.ts Zod parameters and read-file behavior
src/​tools/​list-files/​list-files-tool.ts Zod parameters and list-files behavior
src/​tools/​fetch-url/​fetch-url-tool.ts Zod parameters and URL fetching
src/​tools/​delete-file/​delete-file-tool.ts Zod parameters and delete-file behavior
src/​clients/​agent-runner.ts Inferred runner result type
src/​cli/​resolve-pr-comments/​clients/​comment-analyzer.ts Missing-output handling
src/​cli/​prh-companies/​clients/​prh-pipeline.ts Updated stream handling comment
src/​cli/​guestbook/​main.ts JSON result logging
scripts/​secrets-scan.sh Local and Docker gitleaks runner
README.md Secret scan documentation
pnpm-workspace.yaml Catalog version updates
pnpm-lock.yaml Dependency lockfile updates
package.json Dependencies and scripts
AGENTS.md Secret scan command documentation
.github/​workflows/​main.yml Main-branch secret scanning
.github/​workflows/​feature.yml PR scanning and job gating

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

# Same script as `pnpm secrets:scan`; runs the pinned gitleaks Docker
# image, so no pnpm/Node setup is needed.
- name: Scan for secrets
run: sh scripts/secrets-scan.sh

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Leaving as-is: every PR check (tests, lint, typecheck) runs code from the PR ref, so this isn't specific to the scan, and a change to scripts/secrets-scan.sh shows up in the diff under review. The job is there to catch accidental leaks, not a malicious PR author, and fork PRs never get secrets here (resolve-pr-comments skips forks). It mirrors agentic-monorepo-starter on purpose, so local and CI run the same script.

Comment thread package.json
Comment thread src/cli/guestbook/main.ts Outdated
Comment thread src/tools/fetch-url/fetch-url-tool.ts
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@valuecodes
valuecodes merged commit 2dea2e2 into main Sep 26, 2026
6 checks passed
@valuecodes
valuecodes deleted the feat/deps-update-secrets-scan branch September 26, 2026 05:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants