Registry release installs an unpinned nf CLI in the job that holds the registry key

Aperta Adatta ai principianti
#137 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
65/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
github-actions, typescript
Ambito
ci-cd, security

Direzione di ricerca

Leggi .github/workflows/nf-registry-release.yml intorno alle righe 80–87 e confronta il modo in cui viene installata la CLI con il modo in cui il workflow fissa le versioni delle action di terze parti. Scegli e implementa uno degli approcci indicati: usa una versione esatta della CLI con un percorso di aggiornamento gestibile, oppure invoca la versione bloccata nel repository consumer. Il lavoro è completato quando le release del registry non installano più una CLI latest non bloccata e i comandi di login e publish del workflow continuano a usare la versione prevista.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

bug dependencies
Issue description

The registry release job installs the CLI with no version (.github/workflows/nf-registry-release.yml#L80-L87):

- name: Install the nf CLI
  run: pnpm install -g @nanoforge-dev/cli
- name: Log in to the NanoForge registry
  run: nf login -k "$NF_REGISTRY_KEY"

Every registry release in every consumer repo therefore runs whatever latest is at that moment. It runs in a job with contents: write, and it receives NF_REGISTRY_KEY. The consequences (traced, not run):

  • a broken or compromised CLI release reaches every registry release at once;
  • a breaking major (cli 3.0.0 shipped this month) that changes nf publish -d or nf login -k breaks them all;
  • nothing records which CLI version a release used.

Third-party actions in this repo are pinned by commit SHA; this npm install is not pinned at all.

Expected: the CLI version is pinned (e.g. an input with an exact default, kept current by Dependabot), or taken from the consumer's lockfile (pnpm exec nf) when the repo already depends on it.

Found by a read-only audit of main at 435a16b (first done at 046494f; this file didn't change in between), report audits/actions-2026-11-11.md in the workspace repo.

Code sample

No response

Versions
  • @nanoforge-dev/actions 3.3.0 (main at 435a16b)
Issue priority

High (immediate attention needed)

I have tested this issue on a development release

435a16b

Lingua principale
TypeScript
Stelle
0
Fork
0
Merge medio
15h 51m
PR unite (30g)
21

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di NanoForge-dev/actions

Tutte le issue di NanoForge-dev/actions

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.