Skip to content

Commit 5eb1b6b

Browse files
ci: release (#159)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
1 parent f34c980 commit 5eb1b6b

7 files changed

Lines changed: 45 additions & 30 deletions

File tree

.changeset/check-account-status-private-state.md

Lines changed: 0 additions & 5 deletions
This file was deleted.

.changeset/oauth-granular-permissions.md

Lines changed: 0 additions & 14 deletions
This file was deleted.

.changeset/oauth-refresh-token-fixes.md

Lines changed: 0 additions & 9 deletions
This file was deleted.

packages/oauth-provider/CHANGELOG.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,24 @@
11
# @getcirrus/oauth-provider
22

3+
## 0.4.0
4+
5+
### Minor Changes
6+
7+
- [#158](https://github.com/ascorbic/cirrus/pull/158) [`ec935b1`](https://github.com/ascorbic/cirrus/commit/ec935b16b7f44b22ff325781e0c88ccc3d07e599) Thanks [@ascorbic](https://github.com/ascorbic)! - Support granular OAuth permissions and permission sets per the atproto permission spec.
8+
- `repo:`, `rpc:`, `blob:`, `account:`, `identity:` scopes are parsed and enforced (via `@atproto/oauth-scopes`); `transition:generic` / `transition:email` / `transition:chat.bsky` keep working through the transitional shim.
9+
- `verifyAccessToken` now accepts a `(perms) => p.assertRepo({ collection, action })`-style check callback in addition to the legacy required-scope string.
10+
- PDS write endpoints (`createRecord`, `putRecord`, `deleteRecord`, `applyWrites`, `uploadBlob`) assert the matching scope before dispatching.
11+
- `include:NSID?aud=...` permission-set scopes are resolved via `@atcute/lexicon-resolver` and expanded inline at code-issuance time, so resource-server checks never need network access. The PDS caches resolved permission sets in DO SQLite with the spec's stale-while-revalidate semantics (24h soft / 90d hard).
12+
- The consent UI groups long granular-scope lists by NSID authority and collapses them behind a `<details>` disclosure, so a 30-scope client like tangled.org renders as a few audit-friendly lines instead of a wall of text. `include:` scopes render the resolved bundle's title/detail.
13+
14+
**Note on legacy auth:** session JWTs (from `createSession` / app-password flow), service JWTs, and the static `AUTH_TOKEN` continue to bypass scope checks at resource handlers — they're treated as fully-trusted callers per their original semantics (app-password equivalents). The new `rpc:` proxy enforcement only applies to OAuth (`DPoP`) tokens; legacy clients can still call any AppView method via the proxy regardless of granular scopes.
15+
16+
### Patch Changes
17+
18+
- [#155](https://github.com/ascorbic/cirrus/pull/155) [`d1a7074`](https://github.com/ascorbic/cirrus/commit/d1a70748126870274980d76e230719e29f408290) Thanks [@a-lavis](https://github.com/a-lavis)! - Fix two OAuth token refresh bugs that prevented spec-compliant clients (e.g. tangled.org via indigo) from refreshing their session after the access token expired.
19+
- Track access and refresh expiry separately on `TokenData` (`accessExpiresAt` / `refreshExpiresAt`) instead of a single `expiresAt`. `cleanup()` now prunes by `refreshExpiresAt`, so a row isn't deleted while its refresh token is still valid. The PDS SQLite store migrates legacy `oauth_tokens` rows in place, deriving `refresh_expires_at` as `MAX(expires_at, issued_at + REFRESH_TOKEN_TTL)`.
20+
- The PDS auth middleware now sends `WWW-Authenticate: DPoP error="invalid_token"` on 401 responses for invalid/expired OAuth access tokens, as required by the atproto XRPC spec. Clients that gate refresh on this header (indigo, and others) will now refresh automatically instead of staying logged-in-but-broken until the user signs out.
21+
322
## 0.3.2
423

524
### Patch Changes

packages/oauth-provider/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@getcirrus/oauth-provider",
3-
"version": "0.3.2",
3+
"version": "0.4.0",
44
"description": "OAuth 2.1 Provider with AT Protocol extensions for Cloudflare Workers",
55
"type": "module",
66
"main": "dist/index.js",

packages/pds/CHANGELOG.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,29 @@
11
# @getcirrus/pds
22

3+
## 0.14.0
4+
5+
### Minor Changes
6+
7+
- [#158](https://github.com/ascorbic/cirrus/pull/158) [`ec935b1`](https://github.com/ascorbic/cirrus/commit/ec935b16b7f44b22ff325781e0c88ccc3d07e599) Thanks [@ascorbic](https://github.com/ascorbic)! - Support granular OAuth permissions and permission sets per the atproto permission spec.
8+
- `repo:`, `rpc:`, `blob:`, `account:`, `identity:` scopes are parsed and enforced (via `@atproto/oauth-scopes`); `transition:generic` / `transition:email` / `transition:chat.bsky` keep working through the transitional shim.
9+
- `verifyAccessToken` now accepts a `(perms) => p.assertRepo({ collection, action })`-style check callback in addition to the legacy required-scope string.
10+
- PDS write endpoints (`createRecord`, `putRecord`, `deleteRecord`, `applyWrites`, `uploadBlob`) assert the matching scope before dispatching.
11+
- `include:NSID?aud=...` permission-set scopes are resolved via `@atcute/lexicon-resolver` and expanded inline at code-issuance time, so resource-server checks never need network access. The PDS caches resolved permission sets in DO SQLite with the spec's stale-while-revalidate semantics (24h soft / 90d hard).
12+
- The consent UI groups long granular-scope lists by NSID authority and collapses them behind a `<details>` disclosure, so a 30-scope client like tangled.org renders as a few audit-friendly lines instead of a wall of text. `include:` scopes render the resolved bundle's title/detail.
13+
14+
**Note on legacy auth:** session JWTs (from `createSession` / app-password flow), service JWTs, and the static `AUTH_TOKEN` continue to bypass scope checks at resource handlers — they're treated as fully-trusted callers per their original semantics (app-password equivalents). The new `rpc:` proxy enforcement only applies to OAuth (`DPoP`) tokens; legacy clients can still call any AppView method via the proxy regardless of granular scopes.
15+
16+
### Patch Changes
17+
18+
- [#153](https://github.com/ascorbic/cirrus/pull/153) [`6e4d81d`](https://github.com/ascorbic/cirrus/commit/6e4d81dbf065568a273739ee59e97870381d5e68) Thanks [@georgemblack](https://github.com/georgemblack)! - Fix `com.atproto.server.checkAccountStatus` response to be lexicon-compliant: `privateStateValues` is a required `integer` (not nullable), so return `0` instead of `null` in both the activated and not-activated branches.
19+
20+
- [#155](https://github.com/ascorbic/cirrus/pull/155) [`d1a7074`](https://github.com/ascorbic/cirrus/commit/d1a70748126870274980d76e230719e29f408290) Thanks [@a-lavis](https://github.com/a-lavis)! - Fix two OAuth token refresh bugs that prevented spec-compliant clients (e.g. tangled.org via indigo) from refreshing their session after the access token expired.
21+
- Track access and refresh expiry separately on `TokenData` (`accessExpiresAt` / `refreshExpiresAt`) instead of a single `expiresAt`. `cleanup()` now prunes by `refreshExpiresAt`, so a row isn't deleted while its refresh token is still valid. The PDS SQLite store migrates legacy `oauth_tokens` rows in place, deriving `refresh_expires_at` as `MAX(expires_at, issued_at + REFRESH_TOKEN_TTL)`.
22+
- The PDS auth middleware now sends `WWW-Authenticate: DPoP error="invalid_token"` on 401 responses for invalid/expired OAuth access tokens, as required by the atproto XRPC spec. Clients that gate refresh on this header (indigo, and others) will now refresh automatically instead of staying logged-in-but-broken until the user signs out.
23+
24+
- Updated dependencies [[`ec935b1`](https://github.com/ascorbic/cirrus/commit/ec935b16b7f44b22ff325781e0c88ccc3d07e599), [`d1a7074`](https://github.com/ascorbic/cirrus/commit/d1a70748126870274980d76e230719e29f408290)]:
25+
- @getcirrus/oauth-provider@0.4.0
26+
327
## 0.13.0
428

529
### Minor Changes

packages/pds/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@getcirrus/pds",
3-
"version": "0.13.0",
3+
"version": "0.14.0",
44
"description": "Cirrus – A single-user AT Protocol PDS on Cloudflare Workers",
55
"type": "module",
66
"main": "dist/index.js",

0 commit comments

Comments
 (0)