You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 14c8342
Browse filesBrowse the repository at this point in the historyBrowse files
Run 76. Tested main `cd7c5c5` (unchanged since the last run; release v5.2.0) on Linux with Node 22.23.5 and npm 12.2.3, 10.9.9, 8.19.4 and 7.24.2. No new npm release (latest 12.2.3). Patch data came from a local Python mock of the patch API, serving marker patches built from the real `left-pad@1.3.0`, `is-number@7.0.0`, `core-js@3.37.1` and `JSONStream@1.3.5` tarballs. It also served a synthetic `crlf-bin-x` package from an upstream registry route, and the patch routes under a `/mirror/` base path for `SOCKET_PATCH_MIRROR_URL`.
4
+
5
+
**Re-triage** (no change, no comment)
6
+
-#2304: still reproduces (after a vendored scan, `scan --mode agent` says "2 vulnerabilities left to patch"; a bare `scan` says "Nothing left to patch").
7
+
-#2331: still reproduces on 12.2.3 (vendored + `omit-lockfile-registry-resolved=true`, one `npm install`, cold `npm ci` fails EINTEGRITY).
8
+
9
+
**Cells**
10
+
- npm 12 `allowScripts` with a patched package that has a postinstall (`core-js@3.37.1`, `strict-allow-scripts=true`), hosted and vendored: a version-pinned approval is warned (`redirect_npm_allow_scripts` / `vendor_npm_allow_scripts`) and `npm ci` fails ESTRICTALLOWSCRIPTS, as documented. A name-only approval runs the script on patched bytes, and `vex` passes: **pass**.
11
+
- CRLF-shebang bin (#1756) where the patched file is the bin, all three modes: install, scan, `npm ci`, bin runs, `vex`. Agent re-apply is a no-op, and agent rollback restores the file with the bin still working: **pass**.
12
+
- Git dep (`lp: github:left-pad/left-pad#v1.3.0`) beside registry `left-pad`, agent mode, npm 10.9.9 (v3) and 8.19.4 (v2): both copies patched, `vex`, rollback restores: **pass**.
13
+
- v4 `postinstall: socket-patch apply` hook on a vendored project, 12.2.3: `npm ci` online and with the API unreachable stays patched, `vex`, `vendor --check`, rollback, `npm ci` upstream: **pass**.
14
+
- Patch mirror on npm 8.19.4 and 7.24.2 v2 locks, hosted: packages and legacy `dependencies` entries both pinned under the mirror, `npm ci` patched, `vex`, re-run no-op, rollback byte-exact: **pass**.
- Upper-case legacy name `JSONStream@1.3.5`, all three modes, through `vex`, `list` and `rollback JSONStream`: **pass**.
17
+
-`dev` / `optional` lock flags after hosted and vendored rewrites, then `npm ci --omit=dev` / `--omit=optional` / plain: **pass**.
18
+
19
+
**Issues**
20
+
- None filed, commented on or closed.
21
+
22
+
**False positives ruled out**
23
+
- Vendored npm 12: running npm's own `npm install-scripts approve core-js` writes an absolute `file:` tarball approval and drops the version approval, so `strict-allow-scripts` fails after `rollback`. socket-patch leaves `allowScripts` alone by design, and its warning names the working name-only approval (added to `known-non-bugs/npm.md`).
24
+
- Agent `rollback` printing "Removed N patches from manifest" is the documented v5 full-state rollback.
25
+
26
+
**Next**: re-triage #2275 and #2476; VEX `@scope` purl vs scanners; an interrupted scan on npm 12.
Copy file name to clipboardExpand all lines: known-non-bugs/npm.md
+1Lines changed: 1 addition & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -166,3 +166,4 @@ One line each. Moved from state/npm.md on 2026-11-26; search with git grep.
166
166
- A mirrored hosted pin is not a patch for a run without `SOCKET_PATCH_MIRROR_URL` (`vex`: "No patches in this project"), and vendoring over mirror pins downloads from the patch server (CLI_CONTRACT "Patch mirror"; 2026-12-04).
167
167
-`vex` / `list` from a workspace member directory say "No patches in this project" (exit 2) when the lock and `.socket/` live at the workspace root: discovery is cwd-scoped, same as `scan` / `apply` (npm 12.2.3, 2026-12-05).
168
168
- Hosted pins under `replace-registry-host=always` (patch server or patch mirror): scan warns `redirect_npm_replace_registry_host` and `npm ci` fails E404, as CLI_CONTRACT documents (npm 12.2.3, 2026-12-05).
169
+
- Vendored npm 12: following npm's own `npm install-scripts approve <pkg>` after a version-pinned `allowScripts` approval stops matching writes an absolute `file:/…/.socket/vendor/…tgz` approval and drops the version one, so after `rollback` (or on another checkout path) `strict-allow-scripts` fails. socket-patch leaves `allowScripts` untouched by design and its warning names the name-only approval, which works (12.2.3, 2026-12-06).
@@ -47,28 +47,31 @@ Linux unless noted. Every cell is a real npm install. Hosted and agent/vendored
47
47
| Mode-less `scan --prune` after `npm uninstall` of a vendored dep, 12.2.3 | n/a | GC reverts entry + artifact correctly (2026-11-30); closing totals miscount, see #2304 comment | n/a |
48
48
| npm 12 `allow-remote` from env (`npm_config_allow_remote` / `NPM_CONFIG_ALLOW_REMOTE` none/root) or project `.npmrc` none/root/CRLF over hosted pins | n/a | n/a | pass 12.2.3 (2026-12-01): respected, warning names the env var and `npm ci --allow-remote=all`|
49
49
| npm 11.21.3 `npm install --save-exact <dep>` / `npm shrinkwrap` over pins | n/a | pass / known non-bug (2026-12-01; shrinkwrap: `vex_npm_shrinkwrap_only`, rollback refuses with rename hint, exit 1) | pass / known non-bug (2026-12-03; `--save-exact` keeps the pin, `npm ci` patched, `vex` ok; after `npm shrinkwrap``vex` exit 1 `vex_npm_shrinkwrap_only`, rollback restores the shrinkwrap) |
50
-
| Git dep (`github:` spec) beside a registry dep on an npm 10.9.9 v2-mirror lock |untested| pass (2026-12-01; git copy refused `vendor_lock_entry_not_rewritable`) | pass (2026-12-01; git copy warned) |
51
-
| v4 `postinstall: socket-patch apply --silent --ecosystems npm` hook under v5 (no manifest, manifest, API unreachable); then switch to hosted + rollback, 12.2.3 | pass (2026-12-01) |untested| pass (2026-12-01) |
50
+
| Git dep (`github:` spec) beside a registry dep on an npm 10.9.9 v3 / 8.19.4 v2 lock |pass 10.9.9 / 8.19.4 (2026-12-06; both copies patched, `vex`, rollback)| pass (2026-12-01; git copy refused `vendor_lock_entry_not_rewritable`) | pass (2026-12-01; git copy warned) |
51
+
| v4 `postinstall: socket-patch apply --silent --ecosystems npm` hook under v5 (no manifest, manifest, API unreachable); then switch to hosted + rollback, 12.2.3 | pass (2026-12-01) |pass 12.2.3 (2026-12-06; `npm ci` online and API-unreachable, `vex`, `vendor --check`, rollback, `npm ci` upstream)| pass (2026-12-01) |
52
52
|`node_modules` is a symlink to a cache dir, 12.2.3 | pass (2026-12-01) | n/a | pass (2026-12-01) |
| Credentials in `.npmrc` (`registry=` userinfo, `_authToken`, `_password`) through hosted warnings (allow-remote, omit-lockfile), `--verbose`, `--json`, `vex`, `rollback`, vendored scan / `--check`, 10.9.9 | n/a | pass (2026-12-04, no leak) | pass (2026-12-04, no leak) |
57
57
| Credentials in lock URLs (#2445): token in a git dep `resolved` (npm 10.9.9 / 12.2.3 write it verbatim), userinfo in a registry `resolved`| pass (2026-12-03) |**fail #2476** (open; `vendor --check` prints the git token; `scan` / `vex` / `repair` / `list` / `remove` redact) | pass (2026-12-03; rollback restores the registry URL without its userinfo) |
|`report` (#2193) name / scoped / `%40` purl | pass (2026-11-27; alias name `lp` unmatched, same as `rollback`) | n/a | pass (2026-11-27) |
59
62
| macOS / Windows | probes switched off (INSTRUCTIONS step 5); last pass 2026-10 | same | same |
60
63
61
64
## Backlog
62
65
63
-
1. Re-check #2502, #2476, #2379, #2358, #2331, #2304 and #2275 when fixed (#2358, #2379 re-run 2026-12-05 on `cd7c5c5`: both still reproduce; next re-triage #2331, #2304).
64
-
2.Patch mirror on npm 12 with `allow-remote=root` and a transitive pin; mirror on npm 7 / 8 v2 locks.
65
-
3.VEX products (#2243): prove or rule out a Grype / Trivy miss for `pkg:npm/@scope/name` vs `%40scope` (the Grype binary was denied 2026-11-27; try Trivy / Syft).
66
-
4.Remaining pre-11-11 cells: npm 12 `allowScripts` (needs a patched package with an install script), `hasShrinkwrap` nested, CRLF-shebang bins.
67
-
5.v4 postinstall hook with vendored mode; `vex -g` + `--product` vs global-only packages after #2502 is fixed.
68
-
6.Archive limits (#2410) on npm vendored: a large real package (>64 MiB unpacked) vendored and checked.
69
-
7.Git dep in agent mode on npm 8 / 10; npm 6 hosted cold cache re-run on the new main.
66
+
1. Re-check #2502, #2476, #2379, #2358, #2331, #2304 and #2275 when fixed (#2331, #2304 re-run 2026-12-06 on `cd7c5c5`: both still reproduce; next re-triage #2275, #2476).
67
+
2.VEX products (#2243): prove or rule out a Grype / Trivy miss for `pkg:npm/@scope/name` vs `%40scope` (the Grype binary was denied 2026-11-27; try Trivy / Syft).
4.`vex -g` + `--product` vs global-only packages after #2502 is fixed.
70
+
5.Archive limits (#2410) on npm vendored: a large real package (>64 MiB unpacked) vendored and checked.
71
+
6.npm 6 hosted cold cache re-run on the new main; patch mirror in vendored mode on a v2 lock.
72
+
7.Interrupted vendored / hosted scan (SIGINT mid-write) on npm 12, then re-run and `npm ci`.
70
73
71
-
Mock tip: the 2026-12-05 run's Python mock (batch / view / blob / package / tarball routes, marker patch built from the real npm tarball, gzip mtime=0, `sha512-` prefixed SRI) plus a base-path Basic-auth mirror proxy took ~15 min to rewrite; rebuild the mock from the wiremock fixtures in `crates/socket-patch-cli/tests/e2e_redirect_pnpm_build.rs` (batch, view, blob, package, and the npm version document under `npmRegistryUrl`). The hosted mock must be passed as `--patch-server-url` as well as `--api-url`, or lockfile discovery (`vex`, `rollback`) doesn't recognize the pins ("No patches in this project").
74
+
Mock tip: the 2026-12-06 run's Python mock (also serves a `/mirror/` base-path alias and an upstream registry under `/up/` for synthetic packages; patches the shebang-safe second line of `package/index.js`) is like the 2026-12-05 one (batch / view / blob / package / tarball routes, marker patch built from the real npm tarball, gzip mtime=0, `sha512-` prefixed SRI) plus a base-path Basic-auth mirror proxy took ~15 min to rewrite; rebuild the mock from the wiremock fixtures in `crates/socket-patch-cli/tests/e2e_redirect_pnpm_build.rs` (batch, view, blob, package, and the npm version document under `npmRegistryUrl`). The hosted mock must be passed as `--patch-server-url` as well as `--api-url`, or lockfile discovery (`vex`, `rollback`) doesn't recognize the pins ("No patches in this project").
0 commit comments