fix(deps): node-gyp 9 to 11.5 clears critical tar alert without dropping Node 18/20; replace unpatched git-clone
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 66/100
- Tipo di issue
- Refactoring
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- git, github-actions, javascript, node.js
- Ambito
- build-system, security
Direzione di ricerca
Start in package.json to change the node-gyp range from ^9.3.0 to ^11.5.0, then regenerate package-lock.json. In scripts/build-srt-sdk.js, replace the git-clone call at line 33 with spawnSync('git', ['clone', ...]) using the spawnSync import already at line 11, and remove the git-clone require at line 9. Done means npm ls tar shows no version below 7.5.19 and .github/workflows/nodejs.yml passes on all five Node rows, including 18.x and 20.x.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Problem
node-srt ships node-gyp as a runtime dependency (^9.3.0, locked 9.3.0) because the package's install script runs node-gyp rebuild on every consumer's machine. node-gyp 9 pulls tar 6.1.12, and the Dependabot alerts API reads 13 open runtime tar alerts today, one critical (GHSA-23hp-3jrh-7fpw / CVE-2026-59873, tar <= 7.5.18, fixed 7.5.19) and eight high. Separately, scripts/build-srt-sdk.js:9 requires git-clone 0.1.0, which carries GHSA-8jmw-wjr8-2x66 (CVE-2022-25900, command injection, <= 0.2.0, no patched version exists), and it runs at install time too (build-srt-sdk.js:33, clone(srtRepoPath, srtSourcePath, { checkout: srtCheckout }, ...), where srtCheckout can come from NODE_SRT_CHECKOUT).
The existing route is stuck for a reason that does not apply to every fix: dependabot PR #87 jumps node-gyp 9 -> 13, and the triage bot correctly handed it to a maintainer (comments 2026-07-30 and 2026-08-11) because node-gyp 13 requires Node >= 22.22.2, which breaks the 18.x and 20.x rows of nodejs.yml's matrix [18.x, 20.x, 22.x, 24.x, 26.x].
There is a version that does not break the matrix. npm registry, read today: [email protected] declares engines.node: "^18.17.0 || >=20.5.0" and depends on tar ^7.4.3, which resolves to a tar above 7.5.19. (12.x needs Node ^20.17, so it would drop 18.x; 10.x stays on tar 6.)
This is independent of the libSRT tracks in #89, #90, #91 and #93, which wait on an upstream Haivision/srt tag (newest is still v1.5.7, 2026-08-28). Nothing here touches SRT_CHECKOUT.
Fix (one deliverable: clear the install-time dependency exposure without dropping a supported Node version)
node-gyp^9.3.0->^11.5.0independencies; regenerate the lock. Then close #87 as superseded.- Replace the
git-clonedependency inscripts/build-srt-sdk.jswith a directspawnSync('git', ['clone', '--depth', '1', '--branch', srtCheckout, srtRepoPath, srtSourcePath])(argument array, no shell), already imported at line 11, and dropgit-clonefrompackage.json.
Acceptance
npm ls tarshows notarbelow 7.5.19; the critical GHSA-23hp-3jrh-7fpw and GHSA-8jmw-wjr8-2x66 readfixedin the alerts view.nodejs.ymlpasses on all five matrix rows, including 18.x and 20.x (the row #87 broke).- A clean
npm installstill builds the addon againstv1.5.5and against an overriddenNODE_SRT_CHECKOUT.
Evidence read live 2026-10-08: package.json, package-lock.json, scripts/build-srt-sdk.js, .github/workflows/nodejs.yml on master; GET /repos/Eyevinn/node-srt/dependabot/alerts; PR #87 diff and comments; npm registry metadata for node-gyp 10.3.1, 11.5.0, 12.1.0.
- Lingua principale
- JavaScript
- Stelle
- 99
- Fork
- 35
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di Eyevinn/node-srt
-
bug ready-for-maintainer
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
-
Security: bundled libSRT v1.5.5 is vulnerable to CVE-2026-55869 and CVE-2026-55868 (fixed upstream in v1.5.6)Forse già presa @birme l’ha presa 81 giorni fa. Apertabuild-issue ready-for-maintainer
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
-
Accept() closes the listener socket on success — a listener can only accept one connectionForse già presa @cdgraff l’ha presa 112 giorni fa. Apertabug ready-for-maintainer
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 75/100
-
question ready-for-maintainer
Difficoltà 4/5 3-5 giorni Idoneità per principianti 35/100
-
bug ready-for-maintainer
Difficoltà 4/5 3-5 giorni Idoneità per principianti 48/100
Tutte le issue di Eyevinn/node-srt
Issue simili
-
check:failed feeds:add
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
iptv-org/database#38938 · 2 commenti ·
I maintainer di solito rispondono entro 4 giorni
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
rescript-lang/rescript#9182 ·
I maintainer di solito rispondono entro 1 giorno
-
Analysis
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
SACGF/variantgrid#2615 ·
I maintainer di solito rispondono entro 1 giorno
-
curriculum documentation quality
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
githubnext/gh-aw-workshop#5297 ·
I maintainer di solito rispondono entro 1 giorno