Repository navigation
Conversation
…l pin check) Closes #101 Signed-off-by: Ilan Harel <ilanharel@gmail.com>
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.
What and why
Adds a
Securityworkflow with supply-chain checks for the workflows, the git history, the Rust dependency tree and the OpenShell pin.Closes #101
.github/workflows(with shellcheck onrun:scripts).ci.ymlnow pinsactions/checkoutandactions/cacheby commit SHA like the other workflows (checkoutmoves from v4 to v7.0.1, the version the rest of the repo already uses).deny.toml: advisories (vulnerable, unmaintained, unsound and yanked crates fail), licenses (only the 11 permissive licenses the tree uses today), bans (duplicate versions warn, wildcards fail) and sources (crates.io andNVIDIA/OpenShellonly). It has no advisory ignores. RUSTSEC-2026-0459 does not fire becauselibsqlite3-sysis inCargo.lockbut not in the build graph (cargo tree -i libsqlite3-sys --target allprints nothing).cargo auditstill needs its ignore in.cargo/audit.tomlbecause it reads the whole lockfile.scripts/verify-openshell-pin.sh): CI does not download OpenShell binaries. It builds the policy crates from the git tag. Release attestations cover OpenShell's packages, and those can be built from a different commit than the tag (the v0.1.8 .deb was built from 22209de, but the tag points to f3d9765), sogh attestation verify --repo NVIDIA/OpenShellwould say nothing about the source cargo builds. The script checks that:git ls-remote, peeled);scripts/ci-tools.sh): actionlint 1.7.12, gitleaks 8.30.1 and cargo-deny 0.21.0 are downloaded at pinned versions. Each archive is checked against a SHA-256 pinned in the script, not against the release's own checksum file. actionlint is also checked against its build provenance. gitleaks and cargo-deny publish no attestations.scripts/security-local.shruns the same four checks locally.Docs:
docs/DEVELOPING.md(section 4),CONTRIBUTING.md,SECURITY.md(new "Supply chain" section),AGENTS.md(doc map and dependency rule), the README develop snippet, the PR template, and the CHANGELOG under Unreleased.Not in this PR: making the new jobs required status checks. That change goes in
.github/rulesets/protect-main.jsonplusscripts/protect-main.sh, and the maintainer decides it.Verified locally on Linux before pushing:
scripts/security-local.shpasses (actionlint clean, gitleaks found no leaks in 79 commits,cargo deny checkreports advisories, bans, licenses and sources ok, the pin is ok and its signature is verified). shellcheck passes on the new scripts. As a negative test, a Cargo.lock commit edited by hand fails the pin check.Checklist
feat/,fix/,docs/,chore/ortest/and commits are signed off (git commit -s)scripts/ci-local.shpasses (TOOLCHAIN=1.94 scripts/ci-local.sh): no Rust or generated-docs changes; CI runs ittests/cli.rs, fixtures, golden files): n/a (CI-only change)scripts/gen-docs.sh): n/aCHANGELOG.mdhas a line under## [Unreleased]