From 3f386a7f86fd05176f7a4838611eac316e38c066 Mon Sep 17 00:00:00 2001 From: Anthony Ronning <101225832+AnthonyRonning@users.noreply.github.com> Date: Tue, 17 Nov 2026 19:48:06 -0800 Subject: [PATCH 1/2] CI: ignore the picomatch advisory in the Bun audits GHSA-fc5q-39xc-vjpf (picomatch regular-expression denial of service) covers every picomatch release through 4.0.7, the latest, so no upgrade clears it. Since November 17 it has failed `sdk-ts`, and with it `ci-ok`, on every run that selects the SDK lane, and it fails the nightly audit for the SDK, Research frontend and Auth. picomatch reaches those three lockfiles only through build and lint tooling (Vite, typescript-eslint, Tailwind, vite-plugin-dts, the TanStack router plugin). No source file imports a glob matcher, the published SDK's runtime dependencies do not reach it, and the patterns it matches come from this repository's own configuration. Pass `--ignore=GHSA-fc5q-39xc-vjpf` in both audit call sites and record the exception, its reasons and its removal condition in docs/ci.md. Every other advisory still fails the audits. Co-Authored-By: Claude --- .github/workflows/nightly.yml | 4 +++- docs/ci.md | 27 ++++++++++++++++++++++++++- scripts/ci/build-sdk-publish.sh | 4 +++- 3 files changed, 32 insertions(+), 3 deletions(-) diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml index 0f4101cc1..adc1be0d6 100644 --- a/.github/workflows/nightly.yml +++ b/.github/workflows/nightly.yml @@ -31,12 +31,14 @@ jobs: - uses: ./.github/actions/setup-nix - name: Audit every Bun lockfile run: | + # GHSA-fc5q-39xc-vjpf is an accepted advisory (docs/ci.md, "Accepted + # advisories"). build-sdk-publish.sh carries the same flag: change both together. # shellcheck disable=SC2016 # The child shell expands its own variables. nix develop --no-update-lock-file .#ci -c bash -uo pipefail -c ' status=0 for project in sdk apps/maple-research/frontend apps/maple-auth services/updates services/agent-updates; do echo "::group::$project" - (cd "$project" && bun --no-env-file audit --audit-level=high) || status=1 + (cd "$project" && bun --no-env-file audit --audit-level=high --ignore=GHSA-fc5q-39xc-vjpf) || status=1 echo "::endgroup::" done exit "$status"' diff --git a/docs/ci.md b/docs/ci.md index 9e97e4eda..927fb7c70 100644 --- a/docs/ci.md +++ b/docs/ci.md @@ -36,7 +36,8 @@ and timeout. `scripts/ci/plan.py` (the `plan` job) selects lanes from the diff: through its own manifests; the nightly run reports it. Two gate lanes still audit advisories whenever they are selected, CI edits included: `agent-supply-chain` (cargo-deny for the Agent targets) and `sdk-ts` - (`bun audit` in the SDK publish build). + (`bun audit` in the SDK publish build). The Bun audits skip the + [accepted advisories](#accepted-advisories). The `plan` job summary lists each selected lane and why. To preview locally: @@ -161,6 +162,30 @@ quarantine nothing; so does `repo`, which enforces the workflow policy and release contracts. The nightly report lists every active quarantine; clear the variable when the lane is fixed. +## Accepted advisories + +Both Bun audits pass `--ignore=GHSA-fc5q-39xc-vjpf`: the one in +`scripts/ci/build-sdk-publish.sh` (`sdk-ts` and the npm publish build) and the +nightly one in `nightly.yml`. Every other advisory still fails them. + +[GHSA-fc5q-39xc-vjpf](https://github.com/advisories/GHSA-fc5q-39xc-vjpf) is a +regular-expression denial of service in picomatch: a caller who supplies the +glob pattern can hang the process that matches it. It covers every release +through 4.0.7, the latest, so no upgrade clears it. Reviewed on 2026-11-17: + +- picomatch is in the SDK, Research frontend and Auth lockfiles only through + build and lint tooling: Vite, typescript-eslint, Tailwind, `vite-plugin-dts` + and the TanStack router plugin. +- No source file imports picomatch or another glob matcher, and none of the + published SDK's runtime dependencies reach it. +- The patterns it matches come from this repository's own Vite, Tailwind, + TypeScript and ESLint configuration, so changing them takes commit access. + +Remove the flag from both places once a fixed picomatch is published and the +three lockfiles resolve to it. `bun audit --ignore` matches the GHSA id, not +the CVE id. Record any further accepted advisory here the same way: what it +is, why it does not reach shipped code, and when the flag comes out. + ## Runners The `Runner` constants at the top of `scripts/ci/lanes.py` assign every lane diff --git a/scripts/ci/build-sdk-publish.sh b/scripts/ci/build-sdk-publish.sh index 8e571e358..174158908 100755 --- a/scripts/ci/build-sdk-publish.sh +++ b/scripts/ci/build-sdk-publish.sh @@ -66,7 +66,9 @@ nix develop --no-update-lock-file ./sdk -c bash -euo pipefail -c ' case "${sdk_kind}" in npm) bun --no-env-file install --frozen-lockfile --ignore-scripts - bun --no-env-file audit --audit-level=high + # GHSA-fc5q-39xc-vjpf is an accepted advisory (docs/ci.md, "Accepted + # advisories"). nightly.yml carries the same flag: change both together. + bun --no-env-file audit --audit-level=high --ignore=GHSA-fc5q-39xc-vjpf bun --no-env-file run format:check bun --no-env-file run build VITE_OPEN_SECRET_API_URL=http://127.0.0.1:3000 \ From 54e0701c6253f671fa61e142a59bb299993b9aef Mon Sep 17 00:00:00 2001 From: Anthony Ronning <101225832+AnthonyRonning@users.noreply.github.com> Date: Tue, 17 Nov 2026 19:55:31 -0800 Subject: [PATCH 2/2] CI: keep the picomatch exception in code comments only Drop the docs/ci.md section. The two audit call sites now carry the reason and the removal condition themselves. Co-Authored-By: Claude --- .github/workflows/nightly.yml | 5 +++-- docs/ci.md | 27 +-------------------------- scripts/ci/build-sdk-publish.sh | 5 +++-- 3 files changed, 7 insertions(+), 30 deletions(-) diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml index adc1be0d6..6eccfa733 100644 --- a/.github/workflows/nightly.yml +++ b/.github/workflows/nightly.yml @@ -31,8 +31,9 @@ jobs: - uses: ./.github/actions/setup-nix - name: Audit every Bun lockfile run: | - # GHSA-fc5q-39xc-vjpf is an accepted advisory (docs/ci.md, "Accepted - # advisories"). build-sdk-publish.sh carries the same flag: change both together. + # GHSA-fc5q-39xc-vjpf: picomatch ReDoS with no fixed release, reached only + # through build and lint tooling. Drop the flag here and in + # build-sdk-publish.sh once a fixed picomatch is published. # shellcheck disable=SC2016 # The child shell expands its own variables. nix develop --no-update-lock-file .#ci -c bash -uo pipefail -c ' status=0 diff --git a/docs/ci.md b/docs/ci.md index 927fb7c70..9e97e4eda 100644 --- a/docs/ci.md +++ b/docs/ci.md @@ -36,8 +36,7 @@ and timeout. `scripts/ci/plan.py` (the `plan` job) selects lanes from the diff: through its own manifests; the nightly run reports it. Two gate lanes still audit advisories whenever they are selected, CI edits included: `agent-supply-chain` (cargo-deny for the Agent targets) and `sdk-ts` - (`bun audit` in the SDK publish build). The Bun audits skip the - [accepted advisories](#accepted-advisories). + (`bun audit` in the SDK publish build). The `plan` job summary lists each selected lane and why. To preview locally: @@ -162,30 +161,6 @@ quarantine nothing; so does `repo`, which enforces the workflow policy and release contracts. The nightly report lists every active quarantine; clear the variable when the lane is fixed. -## Accepted advisories - -Both Bun audits pass `--ignore=GHSA-fc5q-39xc-vjpf`: the one in -`scripts/ci/build-sdk-publish.sh` (`sdk-ts` and the npm publish build) and the -nightly one in `nightly.yml`. Every other advisory still fails them. - -[GHSA-fc5q-39xc-vjpf](https://github.com/advisories/GHSA-fc5q-39xc-vjpf) is a -regular-expression denial of service in picomatch: a caller who supplies the -glob pattern can hang the process that matches it. It covers every release -through 4.0.7, the latest, so no upgrade clears it. Reviewed on 2026-11-17: - -- picomatch is in the SDK, Research frontend and Auth lockfiles only through - build and lint tooling: Vite, typescript-eslint, Tailwind, `vite-plugin-dts` - and the TanStack router plugin. -- No source file imports picomatch or another glob matcher, and none of the - published SDK's runtime dependencies reach it. -- The patterns it matches come from this repository's own Vite, Tailwind, - TypeScript and ESLint configuration, so changing them takes commit access. - -Remove the flag from both places once a fixed picomatch is published and the -three lockfiles resolve to it. `bun audit --ignore` matches the GHSA id, not -the CVE id. Record any further accepted advisory here the same way: what it -is, why it does not reach shipped code, and when the flag comes out. - ## Runners The `Runner` constants at the top of `scripts/ci/lanes.py` assign every lane diff --git a/scripts/ci/build-sdk-publish.sh b/scripts/ci/build-sdk-publish.sh index 174158908..342b11ec3 100755 --- a/scripts/ci/build-sdk-publish.sh +++ b/scripts/ci/build-sdk-publish.sh @@ -66,8 +66,9 @@ nix develop --no-update-lock-file ./sdk -c bash -euo pipefail -c ' case "${sdk_kind}" in npm) bun --no-env-file install --frozen-lockfile --ignore-scripts - # GHSA-fc5q-39xc-vjpf is an accepted advisory (docs/ci.md, "Accepted - # advisories"). nightly.yml carries the same flag: change both together. + # GHSA-fc5q-39xc-vjpf: picomatch ReDoS with no fixed release, reached only + # through build and lint tooling. Drop the flag here and in nightly.yml + # once a fixed picomatch is published. bun --no-env-file audit --audit-level=high --ignore=GHSA-fc5q-39xc-vjpf bun --no-env-file run format:check bun --no-env-file run build