Commit ed9711e
committed
chore(ci): switch npm publish to Trusted Publishing (OIDC)
Replaces NPM_TOKEN-based auth with npm Trusted Publishing. GitHub
Actions exchanges its OIDC identity for a short-lived npm publish token
at publish time — no long-lived secret in the repo, nothing to rotate.
Changes:
- publish.yml: drop NODE_AUTH_TOKEN env. Add `npm install -g npm@latest`
step (Trusted Publishing requires npm >= 11.5.1; Node 20 ships 10.x).
- id-token: write permission already in place from the previous
provenance commit (17f8384); same permission serves both purposes.
One-time manual setup on the npm side:
https://www.npmjs.com/package/@tindalabs/shield/access
→ "Add trusted publisher" → GitHub Actions
→ org: tindalabs, repo: shield, workflow: publish.yml
After that, the four existing Publish tokens (id 778104, 0185f2,
256433, ecc691) can be revoked and the NPM_TOKEN GitHub secret deleted.1 parent 89d2b4d commit ed9711e
2 files changed
Lines changed: 12 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
19 | 18 | | |
20 | 19 | | |
21 | 20 | | |
| |||
27 | 26 | | |
28 | 27 | | |
29 | 28 | | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
30 | 33 | | |
31 | 34 | | |
32 | 35 | | |
| |||
39 | 42 | | |
40 | 43 | | |
41 | 44 | | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
42 | 49 | | |
43 | 50 | | |
44 | | - | |
45 | | - | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
219 | 219 | | |
220 | 220 | | |
221 | 221 | | |
222 | | - | |
| 222 | + | |
223 | 223 | | |
224 | 224 | | |
225 | 225 | | |
| |||
0 commit comments