Repository navigation
Version Packages - #1054
Version Packages#1054github-actions[bot] wants to merge 1 commit into
Conversation
d7a9386 to
1f6ea6a
Compare
|
Fix for failing build is #1081. |
1f6ea6a to
84953be
Compare
ec5ad68 to
a2c616f
Compare
|
Important Review skippedBot user detected. To trigger a single review, invoke the ⚙️ Run configuration
You can disable this status message by setting the Use the checkbox below for a quick retry:
Comment |
a2c616f to
5d53c61
Compare
b5b5e57 to
f8ad930
Compare
7aef1ed to
3edd56a
Compare
freshtonic
left a comment
There was a problem hiding this comment.
I did a second review of head 3edd56a67. I request changes for one reason: this release publishes @cipherstash/auth and its six platform packages as 1.0.0. No changeset asks for a major bump.
Blocking: @cipherstash/auth goes from 0.44.1 to 1.0.0
- The pending changesets give
@cipherstash/authoneminor(oidc-federation-per-user-tokens.md) and onepatch(auth-error-codes-and-help.md). The expected version is 0.45.0. - The new
languages/typescript/packages/auth/CHANGELOG.mdentry is## 1.0.0, but it has only "Minor Changes" and "Patch Changes". - Cause:
languages/typescript/packages/auth/package.json:80-87lists the six platform packages aspeerDependenciesatworkspace:*. Thefixedgroup in.changeset/config.jsongives the platforms the same minor bump. A minor bump of a peer that leaves the peer range makes changesets bump the dependent to major (@changesets/assemble-release-plan6.0.10,dist/changesets-assemble-release-plan.cjs.js:340-343).workspace:*is an exact range, so every minor bump leaves it. Thefixedgroup then moves all seven packages to 1.0.0. - 0.44.1 was a patch release, so this did not occur before. All earlier minor releases were published from the old repository.
- protect-ffi does not have this problem. It lists its platforms as
optionalDependencies(languages/typescript/packages/protect-ffi/package.json:105). - A published 1.0.0 cannot be withdrawn. It tells users that the release has breaking changes, and it removes the 0.x line.
Fix options. Choose one before you merge:
- Move the auth platforms to
optionalDependencies, as protect-ffi does. Then let the bot regenerate this PR. Do a check that the native loader andauth-preflight.ymlstill pass. - Keep 1.0.0, but make the decision clear: add a
majorchangeset for@cipherstash/auththat says why. Then the CHANGELOG has a "Major Changes" section that agrees with the version.
Also required before merge (not a code defect)
- No CI ran on this head. The only check is CodeRabbit. 40 workflow runs on
changeset-release/main(Test EQL, Tests (Rust), Tests (Go), CodeQL, Require @cipherstash/auth changeset, and others) have the statusaction_required. Approve them, or push a commit that starts them, and get them green. - Run the preflights. This release moves protect-ffi (0.33.0 to 0.33.1) and
@cipherstash/auth. The lastffi-preflight.ymlandauth-preflight.ymlruns were onmain(6 and 3 October). AGENTS.md says to dispatch them against the Version Packages branch before a release that moves these versions.
What I checked and found correct
- Version bumps agree with the 14 changesets. The
fixedgroup movesstash,stack,stack-drizzle,stack-supabase,stack-prismaandwizardto 1.3.0 (stackminor).@cipherstash/eql3.0.6 to 3.1.0 (two minors). protect-ffi 0.33.1.migrate1.0.1.nextjs4.4.1. - EQL lockstep: the npm package, the
eql-bindingscrate, both release manifests,src/generated/release-manifest.tsand theCOMMENT ON SCHEMA eql_v3stamp in both bundles all say 3.1.0. The SQL diff changes only the stamp.eql-sql-asset-freshness.test.mjspasses (13 tests).eql-bindingsrequiresstack-encrypt0.2.0, which is on crates.io. sync-skill-pins.mjsmoved the three pins inskills/stash-cli/SKILL.md:399andskills/stash-edge/SKILL.md:79,94to 1.3.0. No other exact pin is inskills/.node scripts/release-gate.mjson this head exits 0, withffi=true auth=true js=true.- The scripts suite passes on this head. The only two failures came from stale local
node_modules.
Suggested follow-up PR
languages/typescript/packages/auth/README.md:94-95gives a Deno import map withnpm:@cipherstash/auth@^0.41/.... That range already excludes 0.44. It also excludes this release, so a reader who copies it does not get the per-user token fix for #1045. This README ships in the tarball.
5eb083a to
6328f23
Compare
freshtonic
left a comment
There was a problem hiding this comment.
Re-review of 6328f231e. The bot regenerated the PR on main (141054f5e). The new main commits are #1151 (sharp override, no changeset) and #1202 (EQL test fixtures, no changeset).
Delta
git range-diff 3edd56a67~1..3edd56a67 6328f231e~1..6328f231e reports the Version Packages commit as identical (=). The PR consumes the same 14 changesets. No new changeset merged, so no version changes.
Blocking: still open
@cipherstash/authand its six platform packages still go from 0.44.1 to 1.0.0.languages/typescript/packages/auth/package.json:80-87still lists the platforms aspeerDependenciesatworkspace:*.languages/typescript/packages/auth/CHANGELOG.md:3is still## 1.0.0with only "Minor Changes" and "Patch Changes". The two fix options in my earlier review still apply.
Also required before merge: still open
- No CI ran on this head. The only check is CodeRabbit. The 19 workflow runs for
6328f231eall have the statusaction_required. - Preflights not dispatched. The last
ffi-preflight.ymlrun is onmainat5080d2d33(6 October). The lastauth-preflight.ymlrun is onmainat3e8f6cb8c(3 October). Neither ran onchangeset-release/main.
Re-checked and still correct
Because the commit is identical, my earlier checks still apply: the other version bumps agree with the changesets, the EQL lockstep files all say 3.1.0, and the skill pins (skills/stash-cli/SKILL.md:399, skills/stash-edge/SKILL.md:79,94) say 1.3.0. #1151 and #1202 change no published package surface, so they correctly have no changeset.
Suggested follow-up PR
- Still open:
languages/typescript/packages/auth/README.md:94-95pins the Deno import map to^0.41.
79181ef to
ffa8caa
Compare
ffa8caa to
edac62d
Compare
This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated.
Releases
@cipherstash/auth@1.0.0
Minor Changes
fd0ee91:
OidcFederationStrategynow keeps one CTS token per distinct provider JWTinstead of one token for everyone.
getJwtis called on everygetToken()and must return the JWT of the user the current request is for; a JWT is
exchanged once and its CTS token reused while that token is valid and the
JWT's entry is still in the bounded least-recently-used cache (eviction before
expiry, or
cacheCapacity: 0, means another exchange; see below). Previouslythe strategy cached the first user's token and handed it to
every caller until it expired, so on a server serving many users through one
client a value one user encrypted under a lock context could be bound to
another user's identity (stack-auth
OidcFederationStrategyreuses one user's token for every user until it expires — lock context can bind to the wrong person #1045).getToken()now callsgetJwtin the caller's own async context and hands theJWT to a new
getTokenForJwt(jwt)method, on both the Node andwasm-inlineentries. Previously the Node binding ran
getJwtthrough a napi threadsafefunction, in the async context of
create(), so a callback that read therequest from
AsyncLocalStorage(Clerk'sauth(), Next.jsheaders()) sawno request from a module-level strategy, or the creating request from one
created inside a request. One long-lived strategy now serves every user from
such a callback.
getTokenForJwtis also public, for a caller that alreadyholds the user's JWT; it shares the strategy's cache with
getToken().A token persisted through
createWithStore(for example a cookie) is nowserved only to the JWT it was federated from, so a store shared across users,
or a cookie left over from a previous sign-in, is a cache miss rather than
another user's token. The store is still one slot, so a store shared by
several users caches only the most recent of them; give each user their own
(a per-browser cookie already is). The stored JSON carries a new
federated_fromfield; tokens stored by earlier releases have none and arere-federated once.
Because the cache is keyed on the whole JWT, an identity provider that rotates
JWTs faster than the CTS token lifetime (about 15 minutes) re-federates on each
rotation, where earlier releases reused the stored token.
The cache holds 1024 JWTs unless told otherwise.
createandcreateWithStoretake an optional
cacheCapacityafterbaseUrl(thecacheCapacityoption on@cipherstash/auth/wasm-inline); when the cache is full the least recentlyused JWT's token is dropped, that user is exchanged again on their next call,
and the eviction is logged at
debug.0caches nothing. Existing calls areunchanged.
Patch Changes
fb75f40: Auth failures carry more help, and their messages never quote a credential or another library's text. A failure's
type(NOT_AUTHENTICATED,INVALID_CRN, ...) is unchanged.REQUEST_ERROR's message no longer repeats the transport's own error, which can carry a URL with its query string. It gainshelpsaying what to check.INVALID_TOKENfor a token whose claims do not decode no longer quotes the decoder's message, which could carry a byte or a claim of the token.SERVER_ERRORfor a refused token exchange names the HTTP status and the auth server'serror_description, not the response body, which from the edge in front of it is an HTML page and can echo the access key. A body that is not JSON is reported by where it broke, not by the parser's message.INVALID_GRANT,INVALID_WORKSPACE_IDandALREADY_CONSUMEDgainhelp, andNOT_AUTHENTICATED's help namesstash auth login.STORE_ERRORcarries the help of the profile failure underneath it, such as logging in again when the profile file is missing.@cipherstash/stack@1.3.0
Minor Changes
bbb1bfa:
encrypton atypes.Jsoncolumn now types its result asEncrypted | nullwhen the plaintext may benull. Anulldocument has always resolved to{ data: null }at runtime (it is stored as SQL NULL, not encrypted), but the result was typedEncrypted, soresult.data.ccompiled and then threw.encryptis now generic over the plaintext's type: a literalnull, or a value typedJsonDocument, givesdata: Encrypted | null, through.withLockContext()and.audit()too. A value TypeScript knows is non-null, and every scalar column, still givesdata: Encrypted. No runtime change. If your code readsresult.dataafter encrypting a Json value that may benull, it must now check fornullfirst.EncryptOperationandEncryptOperationWithLockContexttake an optional result type parameter (defaultEncrypted), and theEncryptResult<P>helper type is exported from@cipherstash/stack/encryption.@cipherstash/stack-supabase: the per-term query-encryption fallback (used when the client has nobulkEncrypt) now rejects anullenvelope instead of sending the string"null"as a filter operand, matching the bulk path.stash: thestash-encryptionskill now says whatencryptreturns for anullJson document.Patch Changes
OidcFederationStrategyserves many users through one client: thegetJwtcallback runs on every operation, in the caller's async context, andmust return the JWT of the user behind the current request, and each user's
JWT is exchanged for that user's own token (stack-auth's fix for
stack-auth
OidcFederationStrategyreuses one user's token for every user until it expires — lock context can bind to the wrong person #1045). One caveat is documented for the@cipherstash/stackclient on the native entry, which calls the strategy from a background task so
a request read from
AsyncLocalStorageis not visible insidegetJwtthereyet: capture the request in the closure or build the client per request until
@cipherstash/stackruns a second encryption engine (protect-ffi) — new major built on stack-encrypt (umbrella) #1065 lands. The docs and thestash-auth,stash-encryption,stash-supabaseandstash-edgeskills say so, and say that on earlier@cipherstash/authreleases a strategy caches one token for everyone, so aclient there must serve one user.
EncryptOperation,EncryptQueryOperation,BatchEncryptQueryOperationandBulkEncryptOperationnow declare that they accept atypes.Jsondocument as plaintext, which they always did at runtime; theirgetOperation()return types widen to match. TheEncryptionClientinterface changes only in whatencryptreturns for atypes.Jsoncolumn; see theEncryptResultchangeset.@cipherstash/stack-prisma@1.3.0
Minor Changes
ae63dcd: Move the bundled EQL v3 migrations to eql-3.1.0. EQL 3.1.0 is a minor
release for the Rust
eql-bindingscrate. Its install SQL changes only theversion stamp:
eql_v3.version()returns'3.1.0'and theeql_v3schemacomment reads
'3.1.0'. No function, operator, domain or index behaviourchanges.
Two artefacts carry the new bundle:
20261005T0000_upgrade_eql_v3_3_1_0, carrying theinvariant
cipherstash:upgrade-eql-v3-bundle-3.1.0-v1. Existing databasesre-install through it on the next
prisma-next migration planfollowed byprisma-next migrate.migratealone is not enough: onlymigration plancopies the new directory into your repo.20260601T0100_install_eql_v3_bundle, whichnow bakes 3.1.0 and gains a sixth op, a no-SQL carrier for the new
invariant, so fresh databases land on 3.1.0 from the single all-additive
genesis edge and
db initkeeps working.A 1.2.x database walks one edge. A 1.0.0 or 1.1.x database walks three.
1.2.x shipped eql-3.0.6, so
migratewalks only the 3.1.0 edge. 1.0.0 and1.1.x shipped eql-3.0.4, so
migratewalks the 3.0.5, 3.0.6 and 3.1.0 edges inone transaction, re-installing the ~2.6 MB bundle three times. As with every EQL
upgrade, each re-install opens with
DROP SCHEMA IF EXISTS eql_v3 CASCADE:re-run your grant script, and recreate functional indexes and anything else
depending on
eql_v3.Action required, including on 1.2.x: the baseline changed again. 1.2.0
and 1.2.1 shipped the baseline at eql-3.0.6, and this release changes those
published bytes. 1.0.0 to 1.1.1 shipped it at eql-3.0.4. If your project has a
migrations/cipherstash/directory generated against any earlier version,delete it and re-run
prisma-next migration plan:Your database keeps its markers, so already-applied invariants are not re-run.
If you skip the delete, a fresh
db initfrom a 1.2.x directory refuses withOperation cipherstash.upgrade-eql-v3-bundle-3.1.0 has class "data" which is not allowed by policy.From a 1.0.0 or 1.1.x directory it refuses on the 3.0.5edge instead. See "Upgrading from 1.0.0, 1.1.x or 1.2.x" in the package README.
Why the baseline was re-emitted rather than given a second genesis edge.
The 3.0.5 and 3.0.6 entries said this trade must be re-argued on adoption
numbers at each bump. Unlike the 3.0.6 re-emit, this one changes a published
baseline. The team chose it on these numbers:
@cipherstash/stack-prismahad481 npm downloads in the 30 days to 3 October 2026, and 384 in the last 7 of
those days, 305 of them on the 1.2.0 release day. The append-only alternative,
a second
from: nullgenesis edge, would add another permanent ~2.6 MB copy ofthe bundle for a release that changes no SQL behaviour.
Patch Changes
@cipherstash/eql@3.1.0
Minor Changes
eql-bindingscrate resolves an EQL type named as a string to its own Stack Encrypt plan (stack-encryptfeature).eql_bindings::encryption::targetscarries a catalog-generated table of every EQL type a data plan may name as a field target — its name across languages, family and suffix, the plaintextValueKindit takes, the indexes it carries, its query twin, and whether the engine can produce it today with the reason when not — andencrypt/decrypt/queryentry points that dispatch on the name and run the type's derivedEncryptFrom/DecryptInto, resolving to the EQL value's JSON bytes through the engine'sPendingso a guest batches it with the rest of a plan. This is the EQL half of EQL types as plan field targets (Go and Rust plans cannot target EQL domains, so Go writes rows EQL cannot query — make domains plan field targets #1062): a Go data plan namesTextEqand the guest returns the finished EQL value instead of assembling one.TextEqis the only producible type; every other name is refused with the plan's reason. The SQL surface and the TypeScript package are unchanged.TextEqandTextEqQuerysupport Stack Encrypt's target-directed API behind thestack-encryptfeature. The stored table and column identifier supplies the encryption context; native ciphertext and equality terms are transcoded into EQL payloads while Vitamin C owns plaintext encoding. This is a new producer profile with exact string equality, independent of existing cipherstash-client ciphertext and terms. Query operands carry no recoverable ciphertext.stash@1.3.0
Patch Changes
587d06e: The supply-chain skill names
pipamong the Dependabot ecosystems the repository monitors, and says that a pip requirements file installed in CI should pin every package with a hash and be installed withpip install --require-hashes --no-deps.bd7e55f: Fix invalid YAML in
skills/stash-managed-platforms/SKILL.mdfrontmatter: theunquoted
descriptioncontained a colon-space, so any YAML parser rejected thefile (this broke cipherstash.com deploys, which mirror these skills at build
time). Rewritten as a folded block scalar; the parsed description is
byte-for-byte identical.
e5a3575: The supply-chain skill names every Dependabot ecosystem the repository monitors, including the Go module and the Docker image the musl binaries are built in.
fd0ee91: Document how
OidcFederationStrategyserves many users through one client: thegetJwtcallback runs on every operation, in the caller's async context, andmust return the JWT of the user behind the current request, and each user's
JWT is exchanged for that user's own token (stack-auth's fix for
stack-auth
OidcFederationStrategyreuses one user's token for every user until it expires — lock context can bind to the wrong person #1045). One caveat is documented for the@cipherstash/stackclient on the native entry, which calls the strategy from a background task so
a request read from
AsyncLocalStorageis not visible insidegetJwtthereyet: capture the request in the closure or build the client per request until
@cipherstash/stackruns a second encryption engine (protect-ffi) — new major built on stack-encrypt (umbrella) #1065 lands. The docs and thestash-auth,stash-encryption,stash-supabaseandstash-edgeskills say so, and say that on earlier@cipherstash/authreleases a strategy caches one token for everyone, so aclient there must serve one user.
ae63dcd:
skills/stash-prisma: the stale-migrations/cipherstash/table now describeseql-3.1.0. The baseline bakes 3.1.0, 1.2.x shipped 3.0.6, and the table names
the
db initrefusal a stale 1.2.x directory produces.bbb1bfa:
encrypton atypes.Jsoncolumn now types its result asEncrypted | nullwhen the plaintext may benull. Anulldocument has always resolved to{ data: null }at runtime (it is stored as SQL NULL, not encrypted), but the result was typedEncrypted, soresult.data.ccompiled and then threw.encryptis now generic over the plaintext's type: a literalnull, or a value typedJsonDocument, givesdata: Encrypted | null, through.withLockContext()and.audit()too. A value TypeScript knows is non-null, and every scalar column, still givesdata: Encrypted. No runtime change. If your code readsresult.dataafter encrypting a Json value that may benull, it must now check fornullfirst.EncryptOperationandEncryptOperationWithLockContexttake an optional result type parameter (defaultEncrypted), and theEncryptResult<P>helper type is exported from@cipherstash/stack/encryption.@cipherstash/stack-supabase: the per-term query-encryption fallback (used when the client has nobulkEncrypt) now rejects anullenvelope instead of sending the string"null"as a filter operand, matching the bulk path.stash: thestash-encryptionskill now says whatencryptreturns for anullJson document.Updated dependencies [fb75f40]
Updated dependencies [0275684]
Updated dependencies [c851db5]
Updated dependencies [fd0ee91]
Updated dependencies [f7f1c76]
@cipherstash/migrate@1.0.1
Patch Changes
languages/typescript/in cipherstash/stack. The previous release linked toits old folder under
packages/, which no longer exists, so the README'ssource links and the npm page's repository link returned 404.
@cipherstash/nextjs@4.4.1
Patch Changes
languages/typescript/in cipherstash/stack. The previous release linked toits old folder under
packages/, which no longer exists, so the README'ssource links and the npm page's repository link returned 404.
@cipherstash/protect-ffi@0.33.1
Patch Changes
languages/typescript/in cipherstash/stack. The previous release linked toits old folder under
packages/, which no longer exists, so the README'ssource links and the npm page's repository link returned 404.
@cipherstash/protect-ffi-darwin-arm64@0.33.1
Patch Changes
languages/typescript/in cipherstash/stack. The previous release linked toits old folder under
packages/, which no longer exists, so the README'ssource links and the npm page's repository link returned 404.
@cipherstash/protect-ffi-darwin-x64@0.33.1
Patch Changes
languages/typescript/in cipherstash/stack. The previous release linked toits old folder under
packages/, which no longer exists, so the README'ssource links and the npm page's repository link returned 404.
@cipherstash/protect-ffi-linux-arm64-gnu@0.33.1
Patch Changes
languages/typescript/in cipherstash/stack. The previous release linked toits old folder under
packages/, which no longer exists, so the README'ssource links and the npm page's repository link returned 404.
@cipherstash/protect-ffi-linux-x64-gnu@0.33.1
Patch Changes
languages/typescript/in cipherstash/stack. The previous release linked toits old folder under
packages/, which no longer exists, so the README'ssource links and the npm page's repository link returned 404.
@cipherstash/protect-ffi-linux-x64-musl@0.33.1
Patch Changes
languages/typescript/in cipherstash/stack. The previous release linked toits old folder under
packages/, which no longer exists, so the README'ssource links and the npm page's repository link returned 404.
@cipherstash/protect-ffi-win32-x64-msvc@0.33.1
Patch Changes
languages/typescript/in cipherstash/stack. The previous release linked toits old folder under
packages/, which no longer exists, so the README'ssource links and the npm page's repository link returned 404.
@cipherstash/stack-drizzle@1.3.0
Patch Changes
@cipherstash/stack-supabase@1.3.0
Patch Changes
bbb1bfa:
encrypton atypes.Jsoncolumn now types its result asEncrypted | nullwhen the plaintext may benull. Anulldocument has always resolved to{ data: null }at runtime (it is stored as SQL NULL, not encrypted), but the result was typedEncrypted, soresult.data.ccompiled and then threw.encryptis now generic over the plaintext's type: a literalnull, or a value typedJsonDocument, givesdata: Encrypted | null, through.withLockContext()and.audit()too. A value TypeScript knows is non-null, and every scalar column, still givesdata: Encrypted. No runtime change. If your code readsresult.dataafter encrypting a Json value that may benull, it must now check fornullfirst.EncryptOperationandEncryptOperationWithLockContexttake an optional result type parameter (defaultEncrypted), and theEncryptResult<P>helper type is exported from@cipherstash/stack/encryption.@cipherstash/stack-supabase: the per-term query-encryption fallback (used when the client has nobulkEncrypt) now rejects anullenvelope instead of sending the string"null"as a filter operand, matching the bulk path.stash: thestash-encryptionskill now says whatencryptreturns for anullJson document.Updated dependencies [fd0ee91]
Updated dependencies [bbb1bfa]
Updated dependencies [20ccab3]
@cipherstash/wizard@1.3.0
Patch Changes
@modelcontextprotocol/sdk^1.32.0as a direct dependency so theauto-installed peer of
@anthropic-ai/claude-agent-sdkresolves to a releasepatched against GHSA-6qxp-vccf-f47h / CVE-2026-104850, instead of the vulnerable
1.29.0 previously locked. The wizard never imports the MCP SDK directly — this
is a peer-resolution pin only; no API change.
@cipherstash/auth-darwin-arm64@1.0.0
@cipherstash/auth-darwin-x64@1.0.0
@cipherstash/auth-linux-arm64-gnu@1.0.0
@cipherstash/auth-linux-x64-gnu@1.0.0
@cipherstash/auth-linux-x64-musl@1.0.0
@cipherstash/auth-win32-x64-msvc@1.0.0
@cipherstash/e2e@0.0.8
Patch Changes
@cipherstash/basic-example@1.2.19
Patch Changes
@cipherstash/prisma-example@0.1.5
Patch Changes
@cipherstash/bench@0.0.10
Patch Changes
@cipherstash/ffi-integration-tests@1.0.3
Patch Changes
@cipherstash/test-kit@0.0.6
Patch Changes