Skip to content

chore(security): add /oi-ship-review ship gate + pin minimumReleaseAge#10

Open
matthiasdebernardini wants to merge 1 commit into
lukaisailovic:mainfrom
matthiasdebernardini:add-oi-ship-review-gate
Open

chore(security): add /oi-ship-review ship gate + pin minimumReleaseAge#10
matthiasdebernardini wants to merge 1 commit into
lukaisailovic:mainfrom
matthiasdebernardini:add-oi-ship-review-gate

Conversation

@matthiasdebernardini

Copy link
Copy Markdown

What

Adds a project-scoped Claude Code skill, /oi-ship-review, that gates npm dependency changes before a box image is baked — plus pins minimumReleaseAge so pnpm enforces a release-age window natively.

Why

OpenIslands boxes are single-tenant, no-egress, no-hosting, and the image is built on the developer's machine and copied over. Customers never run npm, so the npm supply-chain risk collapses to one surface: a malicious package version landing in the lockfile on the build machine, where it can run at pnpm install/pnpm build time. This gate guards that surface; it's an adopt-with-a-gate step, not a rewrite.

The gate (single-pass, native tooling only)

  • Exact allowBuilds allowlist check (only esbuild may run a build script)
  • Numeric minimumReleaseAge enforcement (now pinned to 10080 = 1 week)
  • Full change-surface diff: lockfile + manifests + pnpm-workspace.yaml + .npmrc + patches/**
  • pnpm install --frozen-lockfile (never mutates the tree under review)
  • npm audit signatures — verification failure / network-inconclusive ⇒ NO-GO
  • pnpm ignored-builds — new build-script requests flagged
  • fallow audit on changed source
  • Full CI-required suite: build · typecheck · test · validate:templates · e2e · lint

Ends in one GO / NO-GO verdict.

The one config change

minimumReleaseAge: 10080 added to pnpm-workspace.yaml, closing the gap where only minimumReleaseAgeExclude was set — pnpm install now refuses any version published within the last week.

Validation

Ran /oi-ship-review against this change: GO. All controls active, signatures clean (996 registry sigs / 185 attestations), fallow 0 findings, full suite green (591 tests, 4 templates valid, 3 e2e templates passed).

🤖 Generated with Claude Code

https://claude.ai/code/session_0147ouwz5Qo6AnADMq9QPpr4

@matthiasdebernardini

Copy link
Copy Markdown
Author

this is a nice to have for me since I plan to use this and want a way to scan before I deploy, feel free to close it!

Comment thread pnpm-workspace.yaml Outdated
sharp: false
workerd: true

minimumReleaseAge: 10080 # 1 week; pnpm refuses any version published more recently

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

I'd put 2d, should be more than enough (malicious packages are usually handled within hours)

@lukaisailovic

Copy link
Copy Markdown
Owner

@matthiasdebernardini its good to have in general!

Left a small nit and also there is a merge conflict since Vocs are removed (it was also an exception so thats good)

Adds a project-scoped Claude Code skill that gates npm dependency changes
before a box image is baked on the build machine — the one supply-chain
surface left by the no-egress, single-tenant box model (customers never run
npm; the image is built locally and copied over).

The gate is single-pass and uses only native tooling: exact allowBuilds
allowlist check, numeric minimumReleaseAge enforcement, full change-surface
diff (lockfile + manifests + workspace + .npmrc + patches), frozen install,
npm audit signatures, pnpm ignored-builds, fallow audit on changed source,
and the full CI-required suite (build/typecheck/test/validate:templates/e2e/lint).

Also pins minimumReleaseAge: 2880 (2 days) so pnpm install natively refuses
any version published more recently — closing the gap where only
minimumReleaseAgeExclude was set.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MQKPKjFLeugJLitRjSc1sA
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