@atproto/pds 0.4.26 → 0.4.28
Sign up to get free protection for your applications and to get access to all the features.
package/CHANGELOG.md
CHANGED
@@ -1,5 +1,20 @@
|
|
1
1
|
# @atproto/pds
|
2
2
|
|
3
|
+
## 0.4.28
|
4
|
+
|
5
|
+
### Patch Changes
|
6
|
+
|
7
|
+
- [#2522](https://github.com/bluesky-social/atproto/pull/2522) [`53551be6c`](https://github.com/bluesky-social/atproto/commit/53551be6cf092a9b4d2e132788b94ac0d4ffcecc) Thanks [@devinivy](https://github.com/devinivy)! - Set max-age CORS header to max practical value
|
8
|
+
|
9
|
+
## 0.4.27
|
10
|
+
|
11
|
+
### Patch Changes
|
12
|
+
|
13
|
+
- [#2517](https://github.com/bluesky-social/atproto/pull/2517) [`1d4ab5d04`](https://github.com/bluesky-social/atproto/commit/1d4ab5d046aac4539658ee6d7e61882c54d5beb9) Thanks [@dholms](https://github.com/dholms)! - Fix a bad join on privileged app passwords.
|
14
|
+
|
15
|
+
- Updated dependencies [[`1d4ab5d04`](https://github.com/bluesky-social/atproto/commit/1d4ab5d046aac4539658ee6d7e61882c54d5beb9)]:
|
16
|
+
- @atproto/api@0.12.13
|
17
|
+
|
3
18
|
## 0.4.26
|
4
19
|
|
5
20
|
### Patch Changes
|
@@ -87,7 +87,9 @@ exports.storeRefreshToken = storeRefreshToken;
|
|
87
87
|
const getRefreshToken = async (db, id) => {
|
88
88
|
const res = await db.db
|
89
89
|
.selectFrom('refresh_token')
|
90
|
-
.leftJoin('app_password',
|
90
|
+
.leftJoin('app_password', (join) => join
|
91
|
+
.onRef('app_password.did', '=', 'refresh_token.did')
|
92
|
+
.onRef('app_password.name', '=', 'refresh_token.appPasswordName'))
|
91
93
|
.where('id', '=', id)
|
92
94
|
.selectAll('refresh_token')
|
93
95
|
.select('app_password.privileged')
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"auth.js","sourceRoot":"","sources":["../../../src/account-manager/helpers/auth.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;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,CAAA;AAC3B,CAAC,CAAA;AAbY,QAAA,6BAA6B,iCAazC;AAEM,MAAM,iBAAiB,GAAG,GAAG,EAAE;IACpC,OAAO,GAAG,CAAC,QAAQ,CAAC,MAAM,CAAC,WAAW,CAAC,EAAE,CAAC,EAAE,QAAQ,CAAC,CAAA;AACvD,CAAC,CAAA;AAFY,QAAA,iBAAiB,qBAE7B;AAEM,MAAM,WAAW,GAAG,CAAC,WAAmC,EAAa,EAAE;IAC5E,IAAI,CAAC,WAAW;QAAE,OAAO,yBAAS,CAAC,MAAM,CAAA;IACzC,OAAO,WAAW,CAAC,UAAU;QAC3B,CAAC,CAAC,yBAAS,CAAC,iBAAiB;QAC7B,CAAC,CAAC,yBAAS,CAAC,OAAO,CAAA;AACvB,CAAC,CAAA;AALY,QAAA,WAAW,eAKvB;AAED,MAAa,sBAAuB,SAAQ,KAAK;CAAG;AAApD,wDAAoD"}
|
package/dist/index.js
CHANGED
@@ -108,7 +108,7 @@ class PDS {
|
|
108
108
|
static async create(cfg, secrets, overrides) {
|
109
109
|
const app = (0, express_1.default)();
|
110
110
|
app.set('trust proxy', true);
|
111
|
-
app.use((0, cors_1.default)());
|
111
|
+
app.use((0, cors_1.default)({ maxAge: common_1.DAY / common_1.SECOND }));
|
112
112
|
app.use(logger_1.loggerMiddleware);
|
113
113
|
app.use((0, compression_1.default)());
|
114
114
|
const ctx = await context_1.default.fromConfig(cfg, secrets, overrides);
|
package/dist/index.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,uDAAuD;AACvD,sDAAsD;AACtD,mDAAmD;AACnD,+CAA+C;AAC/C,gCAA6B;AAE7B,sDAA6B;AAC7B,gDAAuB;AAEvB,oDAA2B;AAE3B,
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;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@
|
|
1
1
|
{
|
2
2
|
"name": "@atproto/pds",
|
3
|
-
"version": "0.4.
|
3
|
+
"version": "0.4.28",
|
4
4
|
"license": "MIT",
|
5
5
|
"description": "Reference implementation of atproto Personal Data Server (PDS)",
|
6
6
|
"keywords": [
|
@@ -43,12 +43,12 @@
|
|
43
43
|
"typed-emitter": "^2.1.0",
|
44
44
|
"uint8arrays": "3.0.0",
|
45
45
|
"zod": "^3.21.4",
|
46
|
+
"@atproto/api": "^0.12.13",
|
46
47
|
"@atproto/aws": "^0.2.0",
|
47
48
|
"@atproto/common": "^0.4.0",
|
48
|
-
"@atproto/api": "^0.12.12",
|
49
49
|
"@atproto/crypto": "^0.4.0",
|
50
|
-
"@atproto/lexicon": "^0.4.0",
|
51
50
|
"@atproto/identity": "^0.4.0",
|
51
|
+
"@atproto/lexicon": "^0.4.0",
|
52
52
|
"@atproto/repo": "^0.4.0",
|
53
53
|
"@atproto/syntax": "^0.3.0",
|
54
54
|
"@atproto/xrpc": "^0.5.0",
|
@@ -70,8 +70,8 @@
|
|
70
70
|
"jest": "^28.1.2",
|
71
71
|
"ts-node": "^10.8.2",
|
72
72
|
"ws": "^8.12.0",
|
73
|
-
"@atproto/api": "^0.12.
|
74
|
-
"@atproto/bsky": "^0.0.
|
73
|
+
"@atproto/api": "^0.12.13",
|
74
|
+
"@atproto/bsky": "^0.0.56",
|
75
75
|
"@atproto/lex-cli": "^0.4.0"
|
76
76
|
},
|
77
77
|
"scripts": {
|
@@ -107,10 +107,10 @@ export const storeRefreshToken = async (
|
|
107
107
|
export const getRefreshToken = async (db: AccountDb, id: string) => {
|
108
108
|
const res = await db.db
|
109
109
|
.selectFrom('refresh_token')
|
110
|
-
.leftJoin(
|
111
|
-
|
112
|
-
|
113
|
-
|
110
|
+
.leftJoin('app_password', (join) =>
|
111
|
+
join
|
112
|
+
.onRef('app_password.did', '=', 'refresh_token.did')
|
113
|
+
.onRef('app_password.name', '=', 'refresh_token.appPasswordName'),
|
114
114
|
)
|
115
115
|
.where('id', '=', id)
|
116
116
|
.selectAll('refresh_token')
|
package/src/index.ts
CHANGED
@@ -9,7 +9,7 @@ import cors from 'cors'
|
|
9
9
|
import http from 'http'
|
10
10
|
import events from 'events'
|
11
11
|
import { Options as XrpcServerOptions } from '@atproto/xrpc-server'
|
12
|
-
import { DAY, HOUR, MINUTE } from '@atproto/common'
|
12
|
+
import { DAY, HOUR, MINUTE, SECOND } from '@atproto/common'
|
13
13
|
import API from './api'
|
14
14
|
import * as basicRoutes from './basic-routes'
|
15
15
|
import * as wellKnown from './well-known'
|
@@ -54,7 +54,7 @@ export class PDS {
|
|
54
54
|
): Promise<PDS> {
|
55
55
|
const app = express()
|
56
56
|
app.set('trust proxy', true)
|
57
|
-
app.use(cors())
|
57
|
+
app.use(cors({ maxAge: DAY / SECOND }))
|
58
58
|
app.use(loggerMiddleware)
|
59
59
|
app.use(compression())
|
60
60
|
|