Security scanning¶
StackPilot runs layered security checks on pull requests, main, and every release candidate.
Blocking checks¶
- Gitleaks scans the checkout and Git history for secrets.
- Root and Hub production lockfiles are audited at high severity or above.
- ShellCheck blocks error-severity findings in maintained shell scripts.
- Ruff blocks high-confidence Python syntax and undefined-name errors.
- CodeQL analyzes JavaScript and Python on pull requests and
mainwhen GitHub Code Scanning is available, preserving SARIF files as workflow artifacts. - Trivy blocks high and critical container vulnerabilities when a fix is available.
The security workflow also generates SPDX JSON SBOMs for the container, standalone agent, and release archives. Release workflows attach equivalent SBOMs to GitHub releases.
CodeQL runs and uploads to GitHub's Code Scanning dashboard automatically for public repositories. Eligible organization-owned private repositories can opt in by setting the repository variable STACKPILOT_CODEQL_UPLOAD to true. The CodeQL job is skipped for unsupported private repositories, including personal private repositories, and enables itself automatically if the repository becomes public.
Local checks¶
These checks are CPU-only and do not require a GPU:
npm audit --omit=dev --audit-level=high
npm --prefix src/hub audit --omit=dev --audit-level=high
ruff check --select E9,F63,F7,F82 src/agent scripts
shellcheck src/hub/setup.sh src/release/*.sh
docker build -f Containerfile -t stackpilot:security-scan .
trivy image --ignore-unfixed --severity HIGH,CRITICAL --exit-code 1 stackpilot:security-scan
Exceptions¶
Do not add broad scanner exclusions. Any exception must identify the exact rule or vulnerability, an owner, the technical reason, and an expiration date. Secret findings require credential rotation; allowlisting alone is not remediation.
The Gitleaks configuration allowlists only three fixed synthetic values used by tests. It does not exclude files, directories, rules, or credential formats.