From 8f48b544a7ca0bdbece85f26b3f7092bbc9fde8d Mon Sep 17 00:00:00 2001 From: Evan Burrell Date: Thu, 5 Nov 2026 09:44:13 +0000 Subject: [PATCH 1/4] chore(ci): add composer audit job Blocking audit of the prefer-stable dependency tree (what consumers get on a fresh install), plus a report-only prefer-lowest --no-dev audit. Mirrors the composer_audit job in street-orb/spectre-orb. Co-Authored-By: Claude --- .github/workflows/tests.yml | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 4b37c43..c8ed615 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -48,3 +48,36 @@ jobs: - name: Execute tests run: vendor/bin/phpunit + + # Same job as street-orb/spectre-orb's composer_audit: audits the committed composer.lock. + # COMPOSER_NO_SECURITY_BLOCKING stops Composer 2.9+ silently skipping + # vulnerable versions during update, so the audit sees what the composer.json + # constraints actually allow. + composer-audit: + runs-on: ubuntu-latest + name: composer-audit + + env: + COMPOSER_NO_SECURITY_BLOCKING: "1" + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Setup PHP + uses: shivammathur/setup-php@v2 + with: + php-version: 8.3 + extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite + coverage: none + + # Gate: audit the committed lock before anything rewrites it. + - name: Composer audit + run: composer audit --locked --abandoned=report + + # Report-only: shows advisories reachable at the lowest versions our + # runtime constraints allow. Mostly transitive, so it never fails the build. + - name: Composer audit (prefer-lowest, report only) + run: | + composer update --prefer-lowest --no-dev --prefer-dist --no-interaction --no-audit + composer audit --no-dev --abandoned=report || echo "::warning::Advisories reachable at lowest constraints (report only)" From 9c24984f7aee3ef8e73f46f5bbb1e418a7105894 Mon Sep 17 00:00:00 2001 From: Evan Burrell Date: Thu, 5 Nov 2026 09:48:33 +0000 Subject: [PATCH 2/4] chore(ci): audit the resolved tree, not the stale composer.lock The committed lock pins Laravel 5.6 and is out of date with composer.json; CI installs with composer update, so gating on the lock flagged packages nothing actually installs. Co-Authored-By: Claude --- .github/workflows/tests.yml | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index c8ed615..8f1000f 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -49,7 +49,9 @@ jobs: - name: Execute tests run: vendor/bin/phpunit - # Same job as street-orb/spectre-orb's composer_audit: audits the committed composer.lock. + # Same intent as street-orb/spectre-orb's composer_audit, adapted for a + # library. The committed composer.lock is stale (Laravel 5.6) and CI never + # installs from it, so resolve the tree first, as the test job does. # COMPOSER_NO_SECURITY_BLOCKING stops Composer 2.9+ silently skipping # vulnerable versions during update, so the audit sees what the composer.json # constraints actually allow. @@ -71,13 +73,15 @@ jobs: extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite coverage: none - # Gate: audit the committed lock before anything rewrites it. - - name: Composer audit - run: composer audit --locked --abandoned=report - # Report-only: shows advisories reachable at the lowest versions our # runtime constraints allow. Mostly transitive, so it never fails the build. - name: Composer audit (prefer-lowest, report only) run: | composer update --prefer-lowest --no-dev --prefer-dist --no-interaction --no-audit composer audit --no-dev --abandoned=report || echo "::warning::Advisories reachable at lowest constraints (report only)" + + # Gate: what a consumer gets on a fresh install today. + - name: Composer audit + run: | + composer update --prefer-stable --prefer-dist --no-interaction --no-audit + composer audit --abandoned=report From 5f763228d516844f3adfa74ffc15072a5ce79647 Mon Sep 17 00:00:00 2001 From: Evan Burrell Date: Thu, 5 Nov 2026 09:55:16 +0000 Subject: [PATCH 3/4] chore(ci): skip package scripts in composer audit installs --no-dev installs leave out dev tooling (e.g. testbench) that post-autoload scripts call, which failed the job before the audit ran. Co-Authored-By: Claude --- .github/workflows/tests.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 8f1000f..8294418 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -77,11 +77,11 @@ jobs: # runtime constraints allow. Mostly transitive, so it never fails the build. - name: Composer audit (prefer-lowest, report only) run: | - composer update --prefer-lowest --no-dev --prefer-dist --no-interaction --no-audit + composer update --prefer-lowest --no-dev --prefer-dist --no-interaction --no-audit --no-scripts composer audit --no-dev --abandoned=report || echo "::warning::Advisories reachable at lowest constraints (report only)" # Gate: what a consumer gets on a fresh install today. - name: Composer audit run: | - composer update --prefer-stable --prefer-dist --no-interaction --no-audit + composer update --prefer-stable --prefer-dist --no-interaction --no-audit --no-scripts composer audit --abandoned=report From 38b3704009ac3474d69b7bd95957587711907f70 Mon Sep 17 00:00:00 2001 From: Evan Burrell Date: Thu, 5 Nov 2026 15:43:57 +0000 Subject: [PATCH 4/4] chore(ci): let L10/L11 test legs install despite Composer 2.9 security blocking --- .github/workflows/tests.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 8294418..3a3b4fb 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -30,6 +30,14 @@ jobs: name: PHP ${{ matrix.php }} - Laravel ${{ matrix.laravel }} + # Composer 2.9+ refuses to install versions with open advisories. Every + # Laravel 10.x/11.x release now has one (both are past security EOL), so + # without this the L10/L11 legs can't resolve at all. We still want to test + # the range composer.json claims to support; the composer-audit job is the + # security gate. + env: + COMPOSER_NO_SECURITY_BLOCKING: "1" + steps: - name: Checkout code uses: actions/checkout@v4