@atproto/oauth-provider 0.2.5 → 0.2.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (177) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/dist/account/account-store.js +3 -3
  3. package/dist/account/account-store.js.map +1 -1
  4. package/dist/assets/app/bundle-manifest.json +2 -2
  5. package/dist/assets/app/main.js +3 -3
  6. package/dist/assets/app/main.js.map +1 -1
  7. package/dist/assets/asset.d.ts +0 -1
  8. package/dist/assets/asset.d.ts.map +1 -1
  9. package/dist/assets/assets-middleware.js +1 -2
  10. package/dist/assets/assets-middleware.js.map +1 -1
  11. package/dist/assets/index.js +2 -2
  12. package/dist/assets/index.js.map +1 -1
  13. package/dist/client/client-auth.js +2 -3
  14. package/dist/client/client-auth.js.map +1 -1
  15. package/dist/client/client-manager.d.ts +1 -1
  16. package/dist/client/client-manager.d.ts.map +1 -1
  17. package/dist/client/client-manager.js +3 -4
  18. package/dist/client/client-manager.js.map +1 -1
  19. package/dist/client/client-store.js +3 -4
  20. package/dist/client/client-store.js.map +1 -1
  21. package/dist/client/client-utils.d.ts +0 -1
  22. package/dist/client/client-utils.d.ts.map +1 -1
  23. package/dist/client/client-utils.js +2 -3
  24. package/dist/client/client-utils.js.map +1 -1
  25. package/dist/device/device-details.d.ts +0 -1
  26. package/dist/device/device-details.d.ts.map +1 -1
  27. package/dist/device/device-details.js +3 -3
  28. package/dist/device/device-details.js.map +1 -1
  29. package/dist/device/device-id.d.ts.map +1 -1
  30. package/dist/device/device-manager.d.ts +1 -2
  31. package/dist/device/device-manager.d.ts.map +1 -1
  32. package/dist/device/device-store.js +2 -3
  33. package/dist/device/device-store.js.map +1 -1
  34. package/dist/device/session-id.d.ts.map +1 -1
  35. package/dist/dpop/dpop-manager.d.ts +0 -1
  36. package/dist/dpop/dpop-manager.d.ts.map +1 -1
  37. package/dist/lib/html/build-document.d.ts +0 -1
  38. package/dist/lib/html/build-document.d.ts.map +1 -1
  39. package/dist/lib/html/escapers.js +4 -5
  40. package/dist/lib/html/escapers.js.map +1 -1
  41. package/dist/lib/html/util.js +2 -3
  42. package/dist/lib/html/util.js.map +1 -1
  43. package/dist/lib/http/accept.d.ts +0 -1
  44. package/dist/lib/http/accept.d.ts.map +1 -1
  45. package/dist/lib/http/accept.js +1 -2
  46. package/dist/lib/http/accept.js.map +1 -1
  47. package/dist/lib/http/context.js +1 -2
  48. package/dist/lib/http/context.js.map +1 -1
  49. package/dist/lib/http/method.d.ts +0 -1
  50. package/dist/lib/http/method.d.ts.map +1 -1
  51. package/dist/lib/http/method.js +1 -2
  52. package/dist/lib/http/method.js.map +1 -1
  53. package/dist/lib/http/middleware.d.ts +0 -1
  54. package/dist/lib/http/middleware.d.ts.map +1 -1
  55. package/dist/lib/http/middleware.js +4 -5
  56. package/dist/lib/http/middleware.js.map +1 -1
  57. package/dist/lib/http/parser.d.ts +2 -5
  58. package/dist/lib/http/parser.d.ts.map +1 -1
  59. package/dist/lib/http/parser.js +2 -2
  60. package/dist/lib/http/parser.js.map +1 -1
  61. package/dist/lib/http/path.js +1 -2
  62. package/dist/lib/http/path.js.map +1 -1
  63. package/dist/lib/http/request.d.ts +0 -1
  64. package/dist/lib/http/request.d.ts.map +1 -1
  65. package/dist/lib/http/request.js +9 -10
  66. package/dist/lib/http/request.js.map +1 -1
  67. package/dist/lib/http/response.d.ts +0 -3
  68. package/dist/lib/http/response.d.ts.map +1 -1
  69. package/dist/lib/http/response.js +7 -8
  70. package/dist/lib/http/response.js.map +1 -1
  71. package/dist/lib/http/route.d.ts +0 -1
  72. package/dist/lib/http/route.d.ts.map +1 -1
  73. package/dist/lib/http/route.js +1 -2
  74. package/dist/lib/http/route.js.map +1 -1
  75. package/dist/lib/http/router.d.ts +2 -4
  76. package/dist/lib/http/router.d.ts.map +1 -1
  77. package/dist/lib/http/stream.d.ts +2 -7
  78. package/dist/lib/http/stream.d.ts.map +1 -1
  79. package/dist/lib/http/stream.js +5 -5
  80. package/dist/lib/http/stream.js.map +1 -1
  81. package/dist/lib/http/types.d.ts +0 -1
  82. package/dist/lib/http/types.d.ts.map +1 -1
  83. package/dist/lib/http/url.d.ts +0 -1
  84. package/dist/lib/http/url.d.ts.map +1 -1
  85. package/dist/lib/http/url.js +1 -2
  86. package/dist/lib/http/url.js.map +1 -1
  87. package/dist/lib/redis.d.ts.map +1 -1
  88. package/dist/lib/redis.js +7 -6
  89. package/dist/lib/redis.js.map +1 -1
  90. package/dist/lib/util/cast.js +1 -2
  91. package/dist/lib/util/cast.js.map +1 -1
  92. package/dist/lib/util/crypto.js +2 -2
  93. package/dist/lib/util/crypto.js.map +1 -1
  94. package/dist/lib/util/date.js +2 -3
  95. package/dist/lib/util/date.js.map +1 -1
  96. package/dist/lib/util/hostname.d.ts +0 -1
  97. package/dist/lib/util/hostname.d.ts.map +1 -1
  98. package/dist/lib/util/hostname.js +4 -5
  99. package/dist/lib/util/hostname.js.map +1 -1
  100. package/dist/lib/util/redirect-uri.js +1 -2
  101. package/dist/lib/util/redirect-uri.js.map +1 -1
  102. package/dist/lib/util/time.js +1 -2
  103. package/dist/lib/util/time.js.map +1 -1
  104. package/dist/lib/util/well-known.d.ts +0 -1
  105. package/dist/lib/util/well-known.d.ts.map +1 -1
  106. package/dist/lib/util/well-known.js +1 -2
  107. package/dist/lib/util/well-known.js.map +1 -1
  108. package/dist/metadata/build-metadata.d.ts.map +1 -1
  109. package/dist/metadata/build-metadata.js +4 -4
  110. package/dist/metadata/build-metadata.js.map +1 -1
  111. package/dist/oauth-provider.d.ts +1 -2
  112. package/dist/oauth-provider.d.ts.map +1 -1
  113. package/dist/oauth-verifier.d.ts +1 -2
  114. package/dist/oauth-verifier.d.ts.map +1 -1
  115. package/dist/output/build-authorize-data.js +1 -2
  116. package/dist/output/build-authorize-data.js.map +1 -1
  117. package/dist/output/build-error-payload.js +2 -3
  118. package/dist/output/build-error-payload.js.map +1 -1
  119. package/dist/output/customization.d.ts +1 -1
  120. package/dist/output/customization.d.ts.map +1 -1
  121. package/dist/output/customization.js +3 -4
  122. package/dist/output/customization.js.map +1 -1
  123. package/dist/output/output-manager.d.ts +0 -1
  124. package/dist/output/output-manager.d.ts.map +1 -1
  125. package/dist/output/send-authorize-redirect.d.ts +0 -1
  126. package/dist/output/send-authorize-redirect.d.ts.map +1 -1
  127. package/dist/output/send-authorize-redirect.js +1 -2
  128. package/dist/output/send-authorize-redirect.js.map +1 -1
  129. package/dist/output/send-web-page.d.ts +0 -1
  130. package/dist/output/send-web-page.d.ts.map +1 -1
  131. package/dist/output/send-web-page.js +2 -3
  132. package/dist/output/send-web-page.js.map +1 -1
  133. package/dist/replay/replay-store-redis.d.ts +1 -1
  134. package/dist/replay/replay-store-redis.d.ts.map +1 -1
  135. package/dist/replay/replay-store.js +3 -4
  136. package/dist/replay/replay-store.js.map +1 -1
  137. package/dist/request/code.d.ts +1 -1
  138. package/dist/request/code.d.ts.map +1 -1
  139. package/dist/request/request-data.d.ts.map +1 -1
  140. package/dist/request/request-id.d.ts.map +1 -1
  141. package/dist/request/request-manager.d.ts.map +1 -1
  142. package/dist/request/request-manager.js +2 -1
  143. package/dist/request/request-manager.js.map +1 -1
  144. package/dist/request/request-store-redis.d.ts +1 -1
  145. package/dist/request/request-store-redis.d.ts.map +1 -1
  146. package/dist/request/request-store-redis.js.map +1 -1
  147. package/dist/request/request-store.js +2 -3
  148. package/dist/request/request-store.js.map +1 -1
  149. package/dist/request/request-uri.js +3 -3
  150. package/dist/request/request-uri.js.map +1 -1
  151. package/dist/signer/signed-token-payload.d.ts +90 -90
  152. package/dist/signer/signed-token-payload.d.ts.map +1 -1
  153. package/dist/signer/signer.d.ts +6 -6
  154. package/dist/signer/signer.d.ts.map +1 -1
  155. package/dist/token/refresh-token.d.ts +1 -1
  156. package/dist/token/refresh-token.d.ts.map +1 -1
  157. package/dist/token/token-claims.d.ts +90 -90
  158. package/dist/token/token-claims.d.ts.map +1 -1
  159. package/dist/token/token-id.d.ts +1 -1
  160. package/dist/token/token-id.d.ts.map +1 -1
  161. package/dist/token/token-store.js +2 -3
  162. package/dist/token/token-store.js.map +1 -1
  163. package/dist/token/verify-token-claims.js +1 -2
  164. package/dist/token/verify-token-claims.js.map +1 -1
  165. package/package.json +3 -7
  166. package/src/client/client-manager.ts +3 -3
  167. package/src/lib/http/stream.ts +4 -2
  168. package/src/lib/redis.ts +5 -3
  169. package/src/metadata/build-metadata.ts +6 -3
  170. package/src/oauth-provider.ts +1 -1
  171. package/src/oauth-verifier.ts +1 -1
  172. package/src/replay/replay-store-redis.ts +1 -1
  173. package/src/request/request-manager.ts +4 -1
  174. package/src/request/request-store-redis.ts +2 -1
  175. package/tsconfig.backend.tsbuildinfo +1 -0
  176. package/tsconfig.frontend.tsbuildinfo +1 -0
  177. package/tsconfig.tools.tsbuildinfo +1 -0
@@ -1 +1 @@
1
- {"version":3,"file":"token-claims.d.ts","sourceRoot":"","sources":["../../src/token/token-claims.ts"],"names":[],"mappings":"AACA,OAAO,CAAC,MAAM,KAAK,CAAA;AAGnB,OAAO,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAA;AAG9C,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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,GAAG,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC,CAAA"}
@@ -3,5 +3,5 @@ export declare const TOKEN_ID_LENGTH: number;
3
3
  export declare const tokenIdSchema: z.ZodEffects<z.ZodString, `tok-${string}`, string>;
4
4
  export type TokenId = z.infer<typeof tokenIdSchema>;
5
5
  export declare const generateTokenId: () => Promise<TokenId>;
6
- export declare const isTokenId: (data: unknown) => data is `tok-${string}`;
6
+ export declare const isTokenId: (data: unknown) => data is TokenId;
7
7
  //# sourceMappingURL=token-id.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"token-id.d.ts","sourceRoot":"","sources":["../../src/token/token-id.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAKvB,eAAO,MAAM,eAAe,QACwB,CAAA;AAEpD,eAAO,MAAM,aAAa,oDASvB,CAAA;AAEH,MAAM,MAAM,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAA;AACnD,eAAO,MAAM,eAAe,QAAa,QAAQ,OAAO,CAEvD,CAAA;AAED,eAAO,MAAM,SAAS,SAAU,OAAO,4BACA,CAAA"}
1
+ {"version":3,"file":"token-id.d.ts","sourceRoot":"","sources":["../../src/token/token-id.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAKvB,eAAO,MAAM,eAAe,QACwB,CAAA;AAEpD,eAAO,MAAM,aAAa,oDASvB,CAAA;AAEH,MAAM,MAAM,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAA;AACnD,eAAO,MAAM,eAAe,QAAa,OAAO,CAAC,OAAO,CAEvD,CAAA;AAED,eAAO,MAAM,SAAS,SAAU,OAAO,KAAG,IAAI,IAAI,OACX,CAAA"}
@@ -14,7 +14,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
- exports.asTokenStore = exports.isTokenStore = void 0;
17
+ exports.isTokenStore = isTokenStore;
18
+ exports.asTokenStore = asTokenStore;
18
19
  // Export all types needed to implement the TokenStore interface
19
20
  __exportStar(require("./token-id.js"), exports);
20
21
  __exportStar(require("./token-data.js"), exports);
@@ -27,12 +28,10 @@ function isTokenStore(implementation) {
27
28
  typeof implementation.findTokenByCode === 'function' &&
28
29
  typeof implementation.findTokenByRefreshToken === 'function');
29
30
  }
30
- exports.isTokenStore = isTokenStore;
31
31
  function asTokenStore(implementation) {
32
32
  if (!implementation || !isTokenStore(implementation)) {
33
33
  throw new Error('Invalid TokenStore implementation');
34
34
  }
35
35
  return implementation;
36
36
  }
37
- exports.asTokenStore = asTokenStore;
38
37
  //# sourceMappingURL=token-store.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"token-store.js","sourceRoot":"","sources":["../../src/token/token-store.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAQA,gEAAgE;AAChE,gDAA6B;AAC7B,kDAA+B;AAC/B,qDAAkC;AA8ClC,SAAgB,YAAY,CAC1B,cAA6D;IAE7D,OAAO,CACL,OAAO,cAAc,CAAC,WAAW,KAAK,UAAU;QAChD,OAAO,cAAc,CAAC,SAAS,KAAK,UAAU;QAC9C,OAAO,cAAc,CAAC,WAAW,KAAK,UAAU;QAChD,OAAO,cAAc,CAAC,WAAW,KAAK,UAAU;QAChD,OAAO,cAAc,CAAC,eAAe,KAAK,UAAU;QACpD,OAAO,cAAc,CAAC,uBAAuB,KAAK,UAAU,CAC7D,CAAA;AACH,CAAC;AAXD,oCAWC;AAED,SAAgB,YAAY,CAC1B,cAA8D;IAE9D,IAAI,CAAC,cAAc,IAAI,CAAC,YAAY,CAAC,cAAc,CAAC,EAAE,CAAC;QACrD,MAAM,IAAI,KAAK,CAAC,mCAAmC,CAAC,CAAA;IACtD,CAAC;IACD,OAAO,cAAc,CAAA;AACvB,CAAC;AAPD,oCAOC"}
1
+ {"version":3,"file":"token-store.js","sourceRoot":"","sources":["../../src/token/token-store.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAyDA,oCAWC;AAED,oCAOC;AArED,gEAAgE;AAChE,gDAA6B;AAC7B,kDAA+B;AAC/B,qDAAkC;AA8ClC,SAAgB,YAAY,CAC1B,cAA6D;IAE7D,OAAO,CACL,OAAO,cAAc,CAAC,WAAW,KAAK,UAAU;QAChD,OAAO,cAAc,CAAC,SAAS,KAAK,UAAU;QAC9C,OAAO,cAAc,CAAC,WAAW,KAAK,UAAU;QAChD,OAAO,cAAc,CAAC,WAAW,KAAK,UAAU;QAChD,OAAO,cAAc,CAAC,eAAe,KAAK,UAAU;QACpD,OAAO,cAAc,CAAC,uBAAuB,KAAK,UAAU,CAC7D,CAAA;AACH,CAAC;AAED,SAAgB,YAAY,CAC1B,cAA8D;IAE9D,IAAI,CAAC,cAAc,IAAI,CAAC,YAAY,CAAC,cAAc,CAAC,EAAE,CAAC;QACrD,MAAM,IAAI,KAAK,CAAC,mCAAmC,CAAC,CAAA;IACtD,CAAC;IACD,OAAO,cAAc,CAAA;AACvB,CAAC"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.verifyTokenClaims = void 0;
3
+ exports.verifyTokenClaims = verifyTokenClaims;
4
4
  const invalid_dpop_key_binding_error_js_1 = require("../errors/invalid-dpop-key-binding-error.js");
5
5
  const invalid_dpop_proof_error_js_1 = require("../errors/invalid-dpop-proof-error.js");
6
6
  const cast_js_1 = require("../lib/util/cast.js");
@@ -35,5 +35,4 @@ function verifyTokenClaims(token, tokenId, tokenType, dpopJkt, claims, options)
35
35
  }
36
36
  return { token, tokenId, tokenType, claims };
37
37
  }
38
- exports.verifyTokenClaims = verifyTokenClaims;
39
38
  //# sourceMappingURL=verify-token-claims.js.map
@@ -1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Generic OAuth2 and OpenID Connect provider for Node.js. Currently only supports features needed for Atproto.",
6
6
  "keywords": [
@@ -46,7 +46,7 @@
46
46
  "@atproto/common": "^0.4.4",
47
47
  "@atproto/jwk": "0.1.1",
48
48
  "@atproto/jwk-jose": "0.1.2",
49
- "@atproto/oauth-types": "0.1.5"
49
+ "@atproto/oauth-types": "0.2.0"
50
50
  },
51
51
  "devDependencies": {
52
52
  "@rollup/plugin-commonjs": "^25.0.7",
@@ -68,13 +68,9 @@
68
68
  "rollup": "^4.13.0",
69
69
  "rollup-plugin-postcss": "^4.0.2",
70
70
  "tailwindcss": "^3.4.1",
71
- "typescript": "^5.3.3",
71
+ "typescript": "^5.6.3",
72
72
  "@atproto-labs/rollup-plugin-bundle-manifest": "0.1.0"
73
73
  },
74
- "optionalDependencies": {
75
- "ioredis": "^5.3.2",
76
- "keygrip": "^1.1.0"
77
- },
78
74
  "scripts": {
79
75
  "build:frontend": "rollup --config rollup.config.js",
80
76
  "build:backend": "tsc --build --force tsconfig.backend.json",
@@ -815,10 +815,10 @@ function isPrivateUseUriScheme(uri: URL) {
815
815
  }
816
816
 
817
817
  function buildJsonGetRequest(uri: string, options?: GetCachedOptions) {
818
- const headers = new Headers([['accept', 'application/json']])
819
- if (options?.noCache) headers.set('cache-control', 'no-cache')
820
818
  return new Request(uri, {
821
- headers,
819
+ headers: { accept: 'application/json' },
820
+ // @ts-expect-error invalid types in "undici-types"
821
+ cache: options?.noCache ? 'no-cache' : undefined,
822
822
  signal: options?.signal,
823
823
  redirect: 'error',
824
824
  })
@@ -14,8 +14,10 @@ import {
14
14
  export function decodeHttpRequest(req: IncomingMessage): Readable {
15
15
  try {
16
16
  return decodeStream(req, req.headers['content-encoding'])
17
- } catch (err) {
18
- throw createHttpError(415, err, { expose: err instanceof TypeError })
17
+ } catch (cause) {
18
+ const message =
19
+ cause instanceof TypeError ? cause.message : `Invalid content-encoding`
20
+ throw createHttpError(415, message, { cause })
19
21
  }
20
22
  }
21
23
 
package/src/lib/redis.ts CHANGED
@@ -5,9 +5,7 @@ export type { Redis, RedisOptions }
5
5
  export type CreateRedisOptions = Redis | RedisOptions | string
6
6
 
7
7
  export function createRedis(options: CreateRedisOptions): Redis {
8
- if (options instanceof Redis) {
9
- return options
10
- } else if (typeof options === 'string') {
8
+ if (typeof options === 'string') {
11
9
  const url = new URL(
12
10
  options.startsWith('redis://') ? options : `redis://${options}`,
13
11
  )
@@ -17,6 +15,10 @@ export function createRedis(options: CreateRedisOptions): Redis {
17
15
  port: parseInt(url.port, 10),
18
16
  password: url.password,
19
17
  })
18
+ } else if ('on' in options && 'call' in options && 'acl' in options) {
19
+ // Not using "instanceof" here in case the options is an instance of another
20
+ // version of ioredis (Redis is both a class and an interface).
21
+ return options
20
22
  } else {
21
23
  return new Redis(options)
22
24
  }
@@ -1,5 +1,8 @@
1
1
  import { Keyset } from '@atproto/jwk'
2
- import { OAuthAuthorizationServerMetadata } from '@atproto/oauth-types'
2
+ import {
3
+ OAuthAuthorizationServerMetadata,
4
+ oauthAuthorizationServerMetadataSchema,
5
+ } from '@atproto/oauth-types'
3
6
 
4
7
  import { Client } from '../client/client.js'
5
8
  import { VERIFY_ALGOS } from '../lib/util/crypto.js'
@@ -19,7 +22,7 @@ export function buildMetadata(
19
22
  keyset: Keyset,
20
23
  customMetadata?: CustomMetadata,
21
24
  ): OAuthAuthorizationServerMetadata {
22
- return {
25
+ return oauthAuthorizationServerMetadataSchema.parse({
23
26
  issuer,
24
27
 
25
28
  scopes_supported: [
@@ -119,5 +122,5 @@ export function buildMetadata(
119
122
 
120
123
  // https://drafts.aaronpk.com/draft-parecki-oauth-client-id-metadata-document/draft-parecki-oauth-client-id-metadata-document.html
121
124
  client_id_metadata_document_supported: true,
122
- }
125
+ })
123
126
  }
@@ -29,7 +29,7 @@ import {
29
29
  oauthTokenIdentificationSchema,
30
30
  oauthTokenRequestSchema,
31
31
  } from '@atproto/oauth-types'
32
- import { Redis, type RedisOptions } from 'ioredis'
32
+ import type { Redis, RedisOptions } from 'ioredis'
33
33
  import z, { ZodError } from 'zod'
34
34
 
35
35
  import { AccessTokenType } from './access-token/access-token-type.js'
@@ -4,7 +4,7 @@ import {
4
4
  OAuthTokenType,
5
5
  oauthIssuerIdentifierSchema,
6
6
  } from '@atproto/oauth-types'
7
- import { Redis, type RedisOptions } from 'ioredis'
7
+ import type { Redis, RedisOptions } from 'ioredis'
8
8
 
9
9
  import { AccessTokenType } from './access-token/access-token-type.js'
10
10
  import { DpopManager, DpopManagerOptions } from './dpop/dpop-manager.js'
@@ -1,4 +1,4 @@
1
- import { Redis } from 'ioredis'
1
+ import type { Redis } from 'ioredis'
2
2
 
3
3
  import { CreateRedisOptions, createRedis } from '../lib/redis.js'
4
4
  import type { ReplayStore } from './replay-store.js'
@@ -442,7 +442,10 @@ export class RequestManager {
442
442
  }
443
443
 
444
444
  if (data.clientId !== client.id) {
445
- throw new InvalidGrantError('This code was issued for another client')
445
+ // Note: do not reveal the original client ID to the client using an invalid id
446
+ throw new InvalidGrantError(
447
+ `The code was not issued to client "${client.id}"`,
448
+ )
446
449
  }
447
450
 
448
451
  if (data.expiresAt < new Date()) {
@@ -1,4 +1,5 @@
1
- import { Redis } from 'ioredis'
1
+ import type { Redis } from 'ioredis'
2
+
2
3
  import { CreateRedisOptions, createRedis } from '../lib/redis.js'
3
4
  import { Code } from './code.js'
4
5
  import { RequestData } from './request-data.js'
@@ -0,0 +1 @@
1
+ {"root":["./src/constants.ts","./src/index.ts","./src/oauth-client.ts","./src/oauth-dpop.ts","./src/oauth-errors.ts","./src/oauth-hooks.ts","./src/oauth-provider.ts","./src/oauth-store.ts","./src/oauth-verifier.ts","./src/access-token/access-token-type.ts","./src/account/account-manager.ts","./src/account/account-store.ts","./src/account/account.ts","./src/assets/asset.ts","./src/assets/assets-middleware.ts","./src/assets/index.ts","./src/client/client-auth.ts","./src/client/client-data.ts","./src/client/client-id.ts","./src/client/client-info.ts","./src/client/client-manager.ts","./src/client/client-store.ts","./src/client/client-utils.ts","./src/client/client.ts","./src/device/device-data.ts","./src/device/device-details.ts","./src/device/device-id.ts","./src/device/device-manager.ts","./src/device/device-store.ts","./src/device/session-id.ts","./src/dpop/dpop-manager.ts","./src/dpop/dpop-nonce.ts","./src/errors/access-denied-error.ts","./src/errors/account-selection-required-error.ts","./src/errors/consent-required-error.ts","./src/errors/invalid-authorization-details-error.ts","./src/errors/invalid-client-error.ts","./src/errors/invalid-client-id-error.ts","./src/errors/invalid-client-metadata-error.ts","./src/errors/invalid-dpop-key-binding-error.ts","./src/errors/invalid-dpop-proof-error.ts","./src/errors/invalid-grant-error.ts","./src/errors/invalid-parameters-error.ts","./src/errors/invalid-redirect-uri-error.ts","./src/errors/invalid-request-error.ts","./src/errors/invalid-scope-error.ts","./src/errors/invalid-token-error.ts","./src/errors/login-required-error.ts","./src/errors/oauth-error.ts","./src/errors/second-authentication-factor-required-error.ts","./src/errors/unauthorized-client-error.ts","./src/errors/use-dpop-nonce-error.ts","./src/errors/www-authenticate-error.ts","./src/lib/redis.ts","./src/lib/html/build-document.ts","./src/lib/html/escapers.ts","./src/lib/html/html.ts","./src/lib/html/index.ts","./src/lib/html/tags.ts","./src/lib/html/util.ts","./src/lib/http/accept.ts","./src/lib/http/context.ts","./src/lib/http/index.ts","./src/lib/http/method.ts","./src/lib/http/middleware.ts","./src/lib/http/parser.ts","./src/lib/http/path.ts","./src/lib/http/request.ts","./src/lib/http/response.ts","./src/lib/http/route.ts","./src/lib/http/router.ts","./src/lib/http/stream.ts","./src/lib/http/types.ts","./src/lib/http/url.ts","./src/lib/util/authorization-header.ts","./src/lib/util/cast.ts","./src/lib/util/crypto.ts","./src/lib/util/date.ts","./src/lib/util/hostname.ts","./src/lib/util/redirect-uri.ts","./src/lib/util/time.ts","./src/lib/util/type.ts","./src/lib/util/well-known.ts","./src/metadata/build-metadata.ts","./src/oidc/sub.ts","./src/output/build-authorize-data.ts","./src/output/build-error-payload.ts","./src/output/customization.ts","./src/output/output-manager.ts","./src/output/send-authorize-redirect.ts","./src/output/send-web-page.ts","./src/replay/replay-manager.ts","./src/replay/replay-store-memory.ts","./src/replay/replay-store-redis.ts","./src/replay/replay-store.ts","./src/request/code.ts","./src/request/request-data.ts","./src/request/request-id.ts","./src/request/request-info.ts","./src/request/request-manager.ts","./src/request/request-store-memory.ts","./src/request/request-store-redis.ts","./src/request/request-store.ts","./src/request/request-uri.ts","./src/signer/signed-token-payload.ts","./src/signer/signer.ts","./src/token/refresh-token.ts","./src/token/token-claims.ts","./src/token/token-data.ts","./src/token/token-id.ts","./src/token/token-manager.ts","./src/token/token-store.ts","./src/token/verify-token-claims.ts"],"version":"5.6.3"}
@@ -0,0 +1 @@
1
+ {"root":["./src/assets/app/backend-data.ts","./src/assets/app/cookies.ts","./src/assets/app/hooks/use-api.ts","./src/assets/app/hooks/use-bound-dispatch.ts","./src/assets/app/hooks/use-csrf-token.ts","./src/assets/app/lib/api.ts","./src/assets/app/lib/clsx.ts","./src/assets/app/lib/util.ts","./src/assets/app/app.tsx","./src/assets/app/main.tsx","./src/assets/app/components/accept-form.tsx","./src/assets/app/components/account-identifier.tsx","./src/assets/app/components/account-picker.tsx","./src/assets/app/components/button.tsx","./src/assets/app/components/client-name.tsx","./src/assets/app/components/fieldset.tsx","./src/assets/app/components/form-card.tsx","./src/assets/app/components/help-card.tsx","./src/assets/app/components/info-card.tsx","./src/assets/app/components/input-checkbox.tsx","./src/assets/app/components/input-container.tsx","./src/assets/app/components/input-layout.tsx","./src/assets/app/components/input-text.tsx","./src/assets/app/components/layout-title-page.tsx","./src/assets/app/components/layout-welcome.tsx","./src/assets/app/components/sign-in-form.tsx","./src/assets/app/components/sign-up-account-form.tsx","./src/assets/app/components/sign-up-disclaimer.tsx","./src/assets/app/components/url-viewer.tsx","./src/assets/app/components/icons/alert-icon.tsx","./src/assets/app/components/icons/at-symbol-icon.tsx","./src/assets/app/components/icons/caret-right-icon.tsx","./src/assets/app/components/icons/lock-icon.tsx","./src/assets/app/components/icons/token-icon.tsx","./src/assets/app/components/icons/util.tsx","./src/assets/app/views/accept-view.tsx","./src/assets/app/views/authorize-view.tsx","./src/assets/app/views/error-view.tsx","./src/assets/app/views/sign-in-view.tsx","./src/assets/app/views/sign-up-view.tsx","./src/assets/app/views/welcome-view.tsx"],"version":"5.6.3"}
@@ -0,0 +1 @@
1
+ {"root":["./rollup.config.js","./tailwind.config.js"],"version":"5.6.3"}