fix: force ejs to ^6.0.1 via npm overrides - #709
Conversation
- Drop Node 20 from all CI test matrices; minimum is now Node 22 - Update hardcoded node-version '20' → '22' in release jobs - Switch test job runners to ubuntu-x64 - SHA-pin actions/checkout (v4) and actions/setup-node (v6) - Add Artifactory OIDC Auth step to all test jobs - Add ARTIFACTORY_URL env var and id-token: write permissions - Add lockfile-hygiene job (twilio/sdk-actions/npm-lockfile-hygiene) to cli-test.yml - Guard test jobs with if: github.repository_owner == 'twilio' - Fix dead SonarCloud condition (16.x → lts/*) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
JFrog Curation blocks ejs 3.x tree-wide (CVE-2023-29827, CVSS 9.8, no fixed version on the 3.x line). @oclif/core, @oclif/plugin-autocomplete, @oclif/plugin-help/plugins/update/version/warn-if-update-available, and the oclif devDependency all pull in nested ejs 3.x at various versions. An override forces every consumer in the tree to a single ejs@6.0.1 without needing to bump any oclif package itself.
…itical-cve-override
npm install was consistently hitting npm's own "Exit handler never called!" bug on this Windows CI image right after printing ~30 deprecation warnings from the oclif v1 dependency tree, before any install progress. npm ci skips the resolution/mutation (arborist) code path most bug reports implicate, using the lockfile directly instead, and --loglevel=error cuts the volume of synchronous console writes suspected of racing with npm's exit handling on Windows.
npm ci was still hitting "Exit handler never called!" even without the resolution/mutation code path (npm ci vs npm install) or verbose log output as suspects. The npm-cache directory is keyed only on appveyor.yml, so it survives across builds -- including our own earlier crashed runs -- and a corrupted/partial cache entry from a killed run is a well-documented trigger for this exact npm bug. Re-key the cache on package-lock.json too and clean it defensively before every install.
13a3eb0
into
twilio:ejs-critical-cve-override_internal
|
Fixed Heads up: |
Summary
ejs3.x line (CVE-2023-29827, CVSS 9.8 — "no fixed version" on 3.x).@oclif/core,@oclif/plugin-autocomplete,@oclif/plugin-help,@oclif/plugin-plugins,@oclif/plugin-update,@oclif/plugin-version,@oclif/plugin-warn-if-update-available, and theoclifdevDependency all pull in nestedejs@3.xat various versions, some via a nested@oclif/core@2.x."overrides": {"ejs": "^6.0.1"}topackage.jsonto force every consumer in the tree onto a single patchedejs@6.0.1, without bumping any@oclif/*package.ejs.render()(the only API these packages call, including@oclif/plugin-autocomplete's Zsh/PowerShell completion templating) behaves identically under 6.x.Test plan
npm explain ejsshows a singleejs@6.0.1resolved everywhere (was ~10 separate nestedejs@3.xinstalls)npm run lintpassesnpm test— 209/209 passing