Skip to content

Commit 9467377

Browse files
authored
Merge pull request #503 from cipherstash/ci/npm-oidc-trusted-publishing
ci: publish to npm via OIDC trusted publishing
2 parents fcb7e33 + c28b5e4 commit 9467377

10 files changed

Lines changed: 42 additions & 14 deletions

File tree

.github/workflows/release.yml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ jobs:
3535
with:
3636
node-version: 22
3737
# No `cache:`, and package-manager-cache disabled. release.yml
38-
# publishes to npm (NPM_TOKEN + OIDC) and must not restore the
38+
# publishes to npm (OIDC trusted publishing) and must not restore the
3939
# GitHub Actions cache — a cache-poisoning / supply-chain vector.
4040
# Enforced by .github/workflows/tests-supply-chain.yml.
4141
package-manager-cache: false
@@ -46,6 +46,11 @@ jobs:
4646
- name: Install node-gyp
4747
run: npm install -g node-gyp
4848

49+
# npm OIDC trusted publishing requires npm >= 11.5.1; Node 22 ships
50+
# npm 10.x. `changeset publish` shells out to this npm to publish.
51+
- name: Upgrade npm for OIDC trusted publishing
52+
run: npm install -g npm@^11.5.1
53+
4954
- name: Install dependencies
5055
run: pnpm install
5156

@@ -56,5 +61,8 @@ jobs:
5661
publish: pnpm run release
5762
commitMode: 'github-api'
5863
env:
59-
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
64+
# No NPM_TOKEN — publishing authenticates via npm OIDC trusted
65+
# publishing (id-token: write above). If NPM_TOKEN is set,
66+
# changesets/action writes a token .npmrc that shadows OIDC and
67+
# every publish fails with E404 (see npm/cli#8976).
6068
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

packages/cli/package.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22
"name": "stash",
33
"version": "0.16.0",
44
"description": "CipherStash CLI — the one stash command for auth, init, encryption schema, database setup, and secrets.",
5+
"repository": {
6+
"type": "git",
7+
"url": "git+https://github.com/cipherstash/stack.git",
8+
"directory": "packages/cli"
9+
},
510
"license": "MIT",
611
"author": "CipherStash <hello@cipherstash.com>",
712
"files": [

packages/drizzle/package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,12 @@
1212
"postgres"
1313
],
1414
"bugs": {
15-
"url": "https://github.com/cipherstash/protectjs/issues"
15+
"url": "https://github.com/cipherstash/stack/issues"
1616
},
1717
"repository": {
1818
"type": "git",
19-
"url": "git+https://github.com/cipherstash/protectjs.git"
19+
"url": "git+https://github.com/cipherstash/stack.git",
20+
"directory": "packages/drizzle"
2021
},
2122
"license": "MIT",
2223
"author": "CipherStash <hello@cipherstash.com>",

packages/migrate/package.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22
"name": "@cipherstash/migrate",
33
"version": "0.2.0",
44
"description": "Plaintext-to-encrypted column migration for CipherStash: resumable backfill, per-column state, and EQL lifecycle orchestration.",
5+
"repository": {
6+
"type": "git",
7+
"url": "git+https://github.com/cipherstash/stack.git",
8+
"directory": "packages/migrate"
9+
},
510
"keywords": [
611
"cipherstash",
712
"encryption",

packages/nextjs/package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,12 @@
99
"nextjs"
1010
],
1111
"bugs": {
12-
"url": "https://github.com/cipherstash/protectjs/issues"
12+
"url": "https://github.com/cipherstash/stack/issues"
1313
},
1414
"repository": {
1515
"type": "git",
16-
"url": "git+https://github.com/cipherstash/protectjs.git"
16+
"url": "git+https://github.com/cipherstash/stack.git",
17+
"directory": "packages/nextjs"
1718
},
1819
"license": "MIT",
1920
"author": "CipherStash <hello@cipherstash.com>",

packages/protect-dynamodb/package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,12 @@
1111
"security"
1212
],
1313
"bugs": {
14-
"url": "https://github.com/cipherstash/protectjs/issues"
14+
"url": "https://github.com/cipherstash/stack/issues"
1515
},
1616
"repository": {
1717
"type": "git",
18-
"url": "git+https://github.com/cipherstash/protectjs.git"
18+
"url": "git+https://github.com/cipherstash/stack.git",
19+
"directory": "packages/protect-dynamodb"
1920
},
2021
"license": "MIT",
2122
"author": "CipherStash <hello@cipherstash.com>",

packages/protect/package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,12 @@
1111
"protect"
1212
],
1313
"bugs": {
14-
"url": "https://github.com/cipherstash/protectjs/issues"
14+
"url": "https://github.com/cipherstash/stack/issues"
1515
},
1616
"repository": {
1717
"type": "git",
18-
"url": "git+https://github.com/cipherstash/protectjs.git"
18+
"url": "git+https://github.com/cipherstash/stack.git",
19+
"directory": "packages/protect"
1920
},
2021
"license": "MIT",
2122
"author": "CipherStash <hello@cipherstash.com>",

packages/schema/package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,12 @@
99
"builder"
1010
],
1111
"bugs": {
12-
"url": "https://github.com/cipherstash/protectjs/issues"
12+
"url": "https://github.com/cipherstash/stack/issues"
1313
},
1414
"repository": {
1515
"type": "git",
16-
"url": "git+https://github.com/cipherstash/protectjs.git"
16+
"url": "git+https://github.com/cipherstash/stack.git",
17+
"directory": "packages/schema"
1718
},
1819
"license": "MIT",
1920
"author": "CipherStash <hello@cipherstash.com>",

packages/stack/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@
1111
"stack"
1212
],
1313
"bugs": {
14-
"url": "https://github.com/cipherstash/protectjs/issues"
14+
"url": "https://github.com/cipherstash/stack/issues"
1515
},
1616
"repository": {
1717
"type": "git",
18-
"url": "git+https://github.com/cipherstash/protectjs.git",
18+
"url": "git+https://github.com/cipherstash/stack.git",
1919
"directory": "packages/stack"
2020
},
2121
"license": "MIT",

packages/wizard/package.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22
"name": "@cipherstash/wizard",
33
"version": "0.3.0",
44
"description": "AI-powered encryption setup for CipherStash. Reads your codebase, picks columns to encrypt, and wires everything up.",
5+
"repository": {
6+
"type": "git",
7+
"url": "git+https://github.com/cipherstash/stack.git",
8+
"directory": "packages/wizard"
9+
},
510
"license": "MIT",
611
"author": "CipherStash <hello@cipherstash.com>",
712
"files": [

0 commit comments

Comments
 (0)