@shware/security 7.1.0 → 8.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (212) hide show
  1. package/README.md +108 -30
  2. package/dist/auth/attributes.cjs +5 -5
  3. package/dist/auth/attributes.cjs.map +1 -1
  4. package/dist/auth/attributes.d.cts +3 -5
  5. package/dist/auth/attributes.d.cts.map +1 -1
  6. package/dist/auth/attributes.d.mts +3 -5
  7. package/dist/auth/attributes.d.mts.map +1 -1
  8. package/dist/auth/attributes.mjs +5 -5
  9. package/dist/auth/attributes.mjs.map +1 -1
  10. package/dist/auth/desktop-codes.cjs +57 -0
  11. package/dist/auth/desktop-codes.cjs.map +1 -0
  12. package/dist/auth/desktop-codes.d.cts +24 -0
  13. package/dist/auth/desktop-codes.d.cts.map +1 -0
  14. package/dist/auth/desktop-codes.d.mts +24 -0
  15. package/dist/auth/desktop-codes.d.mts.map +1 -0
  16. package/dist/auth/desktop-codes.mjs +55 -0
  17. package/dist/auth/desktop-codes.mjs.map +1 -0
  18. package/dist/auth/email-codes.cjs +77 -0
  19. package/dist/auth/email-codes.cjs.map +1 -0
  20. package/dist/auth/email-codes.d.cts +39 -0
  21. package/dist/auth/email-codes.d.cts.map +1 -0
  22. package/dist/auth/email-codes.d.mts +39 -0
  23. package/dist/auth/email-codes.d.mts.map +1 -0
  24. package/dist/auth/email-codes.mjs +75 -0
  25. package/dist/auth/email-codes.mjs.map +1 -0
  26. package/dist/auth/error.cjs +47 -0
  27. package/dist/auth/error.cjs.map +1 -0
  28. package/dist/auth/error.d.cts +88 -0
  29. package/dist/auth/error.d.cts.map +1 -0
  30. package/dist/auth/error.d.mts +88 -0
  31. package/dist/auth/error.d.mts.map +1 -0
  32. package/dist/auth/error.mjs +45 -0
  33. package/dist/auth/error.mjs.map +1 -0
  34. package/dist/auth/index.cjs +245 -385
  35. package/dist/auth/index.cjs.map +1 -1
  36. package/dist/auth/index.d.cts +66 -57
  37. package/dist/auth/index.d.cts.map +1 -1
  38. package/dist/auth/index.d.mts +66 -57
  39. package/dist/auth/index.d.mts.map +1 -1
  40. package/dist/auth/index.mjs +248 -388
  41. package/dist/auth/index.mjs.map +1 -1
  42. package/dist/auth/respond.cjs +99 -0
  43. package/dist/auth/respond.cjs.map +1 -0
  44. package/dist/auth/respond.d.cts +39 -0
  45. package/dist/auth/respond.d.cts.map +1 -0
  46. package/dist/auth/respond.d.mts +39 -0
  47. package/dist/auth/respond.d.mts.map +1 -0
  48. package/dist/auth/respond.mjs +92 -0
  49. package/dist/auth/respond.mjs.map +1 -0
  50. package/dist/auth/types.d.cts +27 -13
  51. package/dist/auth/types.d.cts.map +1 -1
  52. package/dist/auth/types.d.mts +27 -13
  53. package/dist/auth/types.d.mts.map +1 -1
  54. package/dist/core/index.cjs +1 -2
  55. package/dist/core/index.d.cts +0 -2
  56. package/dist/core/index.d.cts.map +1 -1
  57. package/dist/core/index.d.mts +0 -2
  58. package/dist/core/index.d.mts.map +1 -1
  59. package/dist/core/index.mjs +1 -2
  60. package/dist/email/schema.cjs +1 -2
  61. package/dist/email/schema.d.cts +0 -2
  62. package/dist/email/schema.d.cts.map +1 -1
  63. package/dist/email/schema.d.mts +0 -2
  64. package/dist/email/schema.d.mts.map +1 -1
  65. package/dist/email/schema.mjs +1 -2
  66. package/dist/index.cjs +5 -0
  67. package/dist/index.d.cts +4 -1
  68. package/dist/index.d.mts +4 -1
  69. package/dist/index.mjs +3 -1
  70. package/dist/oauth2/client.cjs +1 -2
  71. package/dist/oauth2/client.d.cts +0 -2
  72. package/dist/oauth2/client.d.cts.map +1 -1
  73. package/dist/oauth2/client.d.mts +0 -2
  74. package/dist/oauth2/client.d.mts.map +1 -1
  75. package/dist/oauth2/client.mjs +1 -2
  76. package/dist/oauth2/error.cjs +1 -9
  77. package/dist/oauth2/error.cjs.map +1 -1
  78. package/dist/oauth2/error.d.cts +0 -5
  79. package/dist/oauth2/error.d.cts.map +1 -1
  80. package/dist/oauth2/error.d.mts +0 -5
  81. package/dist/oauth2/error.d.mts.map +1 -1
  82. package/dist/oauth2/error.mjs +2 -9
  83. package/dist/oauth2/error.mjs.map +1 -1
  84. package/dist/oauth2/name.cjs +1 -2
  85. package/dist/oauth2/name.d.cts +0 -2
  86. package/dist/oauth2/name.d.cts.map +1 -1
  87. package/dist/oauth2/name.d.mts +0 -2
  88. package/dist/oauth2/name.d.mts.map +1 -1
  89. package/dist/oauth2/name.mjs +1 -2
  90. package/dist/oauth2/provider/apple-client-secret.cjs +1 -2
  91. package/dist/oauth2/provider/apple-client-secret.d.cts +0 -2
  92. package/dist/oauth2/provider/apple-client-secret.d.cts.map +1 -1
  93. package/dist/oauth2/provider/apple-client-secret.d.mts +0 -2
  94. package/dist/oauth2/provider/apple-client-secret.d.mts.map +1 -1
  95. package/dist/oauth2/provider/apple-client-secret.mjs +1 -2
  96. package/dist/oauth2/provider/apple.cjs +1 -2
  97. package/dist/oauth2/provider/apple.d.cts +0 -2
  98. package/dist/oauth2/provider/apple.d.cts.map +1 -1
  99. package/dist/oauth2/provider/apple.d.mts +0 -2
  100. package/dist/oauth2/provider/apple.d.mts.map +1 -1
  101. package/dist/oauth2/provider/apple.mjs +1 -2
  102. package/dist/oauth2/provider/common.cjs +2 -3
  103. package/dist/oauth2/provider/common.cjs.map +1 -1
  104. package/dist/oauth2/provider/common.d.cts +0 -2
  105. package/dist/oauth2/provider/common.d.cts.map +1 -1
  106. package/dist/oauth2/provider/common.d.mts +0 -2
  107. package/dist/oauth2/provider/common.d.mts.map +1 -1
  108. package/dist/oauth2/provider/common.mjs +2 -3
  109. package/dist/oauth2/provider/common.mjs.map +1 -1
  110. package/dist/oauth2/provider/facebook.cjs +3 -6
  111. package/dist/oauth2/provider/facebook.cjs.map +1 -1
  112. package/dist/oauth2/provider/facebook.d.cts +0 -3
  113. package/dist/oauth2/provider/facebook.d.cts.map +1 -1
  114. package/dist/oauth2/provider/facebook.d.mts +0 -3
  115. package/dist/oauth2/provider/facebook.d.mts.map +1 -1
  116. package/dist/oauth2/provider/facebook.mjs +3 -6
  117. package/dist/oauth2/provider/facebook.mjs.map +1 -1
  118. package/dist/oauth2/provider/github.cjs +1 -2
  119. package/dist/oauth2/provider/github.d.cts +0 -2
  120. package/dist/oauth2/provider/github.d.cts.map +1 -1
  121. package/dist/oauth2/provider/github.d.mts +0 -2
  122. package/dist/oauth2/provider/github.d.mts.map +1 -1
  123. package/dist/oauth2/provider/github.mjs +1 -2
  124. package/dist/oauth2/provider/google.cjs +1 -2
  125. package/dist/oauth2/provider/google.d.cts +0 -2
  126. package/dist/oauth2/provider/google.d.cts.map +1 -1
  127. package/dist/oauth2/provider/google.d.mts +0 -2
  128. package/dist/oauth2/provider/google.d.mts.map +1 -1
  129. package/dist/oauth2/provider/google.mjs +1 -2
  130. package/dist/oauth2/provider/wechat.cjs +1 -2
  131. package/dist/oauth2/provider/wechat.d.cts +0 -2
  132. package/dist/oauth2/provider/wechat.d.cts.map +1 -1
  133. package/dist/oauth2/provider/wechat.d.mts +0 -2
  134. package/dist/oauth2/provider/wechat.d.mts.map +1 -1
  135. package/dist/oauth2/provider/wechat.mjs +1 -2
  136. package/dist/oauth2/provider/x.cjs +7 -6
  137. package/dist/oauth2/provider/x.cjs.map +1 -1
  138. package/dist/oauth2/provider/x.d.cts +3 -4
  139. package/dist/oauth2/provider/x.d.cts.map +1 -1
  140. package/dist/oauth2/provider/x.d.mts +3 -4
  141. package/dist/oauth2/provider/x.d.mts.map +1 -1
  142. package/dist/oauth2/provider/x.mjs +7 -6
  143. package/dist/oauth2/provider/x.mjs.map +1 -1
  144. package/dist/oauth2/types.cjs +1 -2
  145. package/dist/oauth2/types.cjs.map +1 -1
  146. package/dist/oauth2/types.d.cts +5 -2
  147. package/dist/oauth2/types.d.cts.map +1 -1
  148. package/dist/oauth2/types.d.mts +5 -2
  149. package/dist/oauth2/types.d.mts.map +1 -1
  150. package/dist/oauth2/types.mjs +1 -2
  151. package/dist/oauth2/types.mjs.map +1 -1
  152. package/dist/session/common.cjs +11 -15
  153. package/dist/session/common.cjs.map +1 -1
  154. package/dist/session/common.d.cts +7 -5
  155. package/dist/session/common.d.cts.map +1 -1
  156. package/dist/session/common.d.mts +7 -5
  157. package/dist/session/common.d.mts.map +1 -1
  158. package/dist/session/common.mjs +11 -14
  159. package/dist/session/common.mjs.map +1 -1
  160. package/dist/session/db.cjs +3 -4
  161. package/dist/session/db.cjs.map +1 -1
  162. package/dist/session/db.d.cts +0 -2
  163. package/dist/session/db.d.cts.map +1 -1
  164. package/dist/session/db.d.mts +0 -2
  165. package/dist/session/db.d.mts.map +1 -1
  166. package/dist/session/db.mjs +4 -5
  167. package/dist/session/db.mjs.map +1 -1
  168. package/dist/session/map-session.cjs +1 -2
  169. package/dist/session/map-session.d.cts +0 -2
  170. package/dist/session/map-session.d.cts.map +1 -1
  171. package/dist/session/map-session.d.mts +0 -2
  172. package/dist/session/map-session.d.mts.map +1 -1
  173. package/dist/session/map-session.mjs +1 -2
  174. package/dist/session/redis.cjs +7 -10
  175. package/dist/session/redis.cjs.map +1 -1
  176. package/dist/session/redis.d.cts +0 -2
  177. package/dist/session/redis.d.cts.map +1 -1
  178. package/dist/session/redis.d.mts +0 -2
  179. package/dist/session/redis.d.mts.map +1 -1
  180. package/dist/session/redis.mjs +8 -11
  181. package/dist/session/redis.mjs.map +1 -1
  182. package/dist/session/types.d.cts +0 -14
  183. package/dist/session/types.d.cts.map +1 -1
  184. package/dist/session/types.d.mts +0 -14
  185. package/dist/session/types.d.mts.map +1 -1
  186. package/dist/utils/http.cjs +1 -2
  187. package/dist/utils/http.d.cts +0 -2
  188. package/dist/utils/http.d.cts.map +1 -1
  189. package/dist/utils/http.d.mts +0 -2
  190. package/dist/utils/http.d.mts.map +1 -1
  191. package/dist/utils/http.mjs +1 -2
  192. package/dist/utils/oauth2.cjs +1 -2
  193. package/dist/utils/oauth2.d.cts +0 -2
  194. package/dist/utils/oauth2.d.cts.map +1 -1
  195. package/dist/utils/oauth2.d.mts +0 -2
  196. package/dist/utils/oauth2.d.mts.map +1 -1
  197. package/dist/utils/oauth2.mjs +1 -2
  198. package/dist/utils/timing.cjs +1 -2
  199. package/dist/utils/timing.d.cts +0 -2
  200. package/dist/utils/timing.d.cts.map +1 -1
  201. package/dist/utils/timing.d.mts +0 -2
  202. package/dist/utils/timing.d.mts.map +1 -1
  203. package/dist/utils/timing.mjs +1 -2
  204. package/dist/utils/valid.cjs +35 -54
  205. package/dist/utils/valid.cjs.map +1 -1
  206. package/dist/utils/valid.d.cts +8 -25
  207. package/dist/utils/valid.d.cts.map +1 -1
  208. package/dist/utils/valid.d.mts +8 -25
  209. package/dist/utils/valid.d.mts.map +1 -1
  210. package/dist/utils/valid.mjs +33 -52
  211. package/dist/utils/valid.mjs.map +1 -1
  212. package/package.json +4 -4
@@ -1,7 +1,7 @@
1
1
  import { Principal } from "../core/index.mjs";
2
2
  import { Session } from "../session/types.mjs";
3
+ import { EmailSender } from "./email-codes.mjs";
3
4
  import { AuthConfig, AuthService, AuthorizedHandler, LoggedHandler, OAuth2AuthorizationOptions } from "./types.mjs";
4
- //#region src/auth/index.d.ts
5
5
  export declare const PATH: {
6
6
  readonly CSRF: '/csrf';
7
7
  readonly LOGOUT: '/logout';
@@ -13,13 +13,18 @@ export declare const PATH: {
13
13
  readonly LOGIN_OAUTH2_NATIVE: '/login/oauth2/native/:provider';
14
14
  readonly LOGIN_OAUTH2_ONETAP: '/login/oauth2/onetap/google';
15
15
  readonly LOGIN_EMAIL: '/login/email';
16
- readonly LOGIN_PHONE: '/login/phone';
17
16
  readonly SEND_EMAIL_VERIFICATION_CODE: '/auth/sendEmailVerificationCode';
18
- readonly SEND_PHONE_VERIFICATION_CODE: '/auth/sendPhoneVerificationCode';
19
17
  readonly DESKTOP_AUTHORIZE: '/auth/desktop/authorize';
20
18
  readonly DESKTOP_EXCHANGE: '/auth/desktop/exchange';
21
19
  readonly CLEANUP_EXPIRED_SESSIONS: '/sessions/expired/cleanup';
22
20
  };
21
+ /**
22
+ * The login routes and session helpers. Every route is one straight line: read and validate the
23
+ * request, check the credential, call the host's `onAuthorized`, sign in. Failures are thrown and
24
+ * answered in one place per kind of route: a JSON route runs under `guard`, which maps a
25
+ * `RequestError`, an `AuthenticationError` or an `OAuth2Error` to its google.rpc body (see
26
+ * `respond.ts`); the redirect callback maps the same errors to `errorUri` parameters (`redirect`).
27
+ */
23
28
  export declare class Auth implements AuthService {
24
29
  private readonly timing;
25
30
  private readonly cookieName;
@@ -27,87 +32,92 @@ export declare class Auth implements AuthService {
27
32
  private readonly kv;
28
33
  private readonly repository;
29
34
  private readonly turnstileSecretKey?;
30
- private readonly maxVerificationAttempts;
31
- private readonly verificationResendCooldown;
35
+ private readonly emailCodes;
36
+ private readonly desktopCodes;
32
37
  private readonly oauth2Client;
33
38
  private readonly onetapRequireNonce;
34
39
  private readonly touchInterval;
40
+ private readonly sessionHeader;
35
41
  private readonly ATTR_OAUTH2_AUTHORIZATION_REQUEST;
36
42
  constructor({ sessionRepository, kvRepository, turnstileSecretKey, verificationCode, oauth2, cookie, session, timing }: AuthConfig);
37
43
  private getSessionId;
44
+ /** The session the request carries, if it exists. */
45
+ private loadSession;
46
+ /** The signed-in principal of a session, if any. */
47
+ private principalOf;
48
+ /**
49
+ * A new session signed in as `principal`. With `carryOver`, what the host kept in the pre-login
50
+ * session moves to the new one; the authorization request (state, PKCE verifier, flow
51
+ * attributes) is single-use and was consumed, and a principal left there from an earlier
52
+ * sign-in is replaced. The new id is never the one the browser brought, which may have been
53
+ * planted by an attacker who started the flow (session fixation).
54
+ */
55
+ private signIn;
56
+ /**
57
+ * `response` carrying `session`: its cookie, renewed for the whole inactive interval, and with
58
+ * `session.header` on, the `X-Auth-Token` header a client without a cookie jar reads.
59
+ */
60
+ private withSession;
61
+ /** Runs a JSON route: a failure it knows is its response, anything else is the host's. */
62
+ private guard;
63
+ /** The error redirect of the callback flow; `refusal`'s reason and metadata ride along. */
64
+ private redirect;
38
65
  csrf: (_request: Request) => Promise<Response>;
39
66
  logout: (request: Request) => Promise<Response>;
40
67
  logged: (request: Request, onLogged?: LoggedHandler) => Promise<Response>;
41
68
  private createPkceParameters;
42
69
  private getOauth2StateKey;
43
70
  private getOauth2NonceKey;
44
- private getEmailVerificationCodeKey;
45
- private getEmailVerificationAttemptsKey;
46
- private getEmailVerificationCooldownKey;
47
- private getPhoneVerificationCodeKey;
48
- private getDesktopCodeKey;
71
+ /**
72
+ * Spends a nonce `oauth2Nonce` issued for `provider`: `NONCE_MISMATCH` for one that was not,
73
+ * or was used already. An id token is replayable until it expires; the nonce it carries makes
74
+ * it sign in once.
75
+ */
76
+ private consumeNonce;
49
77
  oauth2State: (request: Request) => Promise<Response>;
50
78
  oauth2Nonce: (request: Request) => Promise<Response>;
51
79
  oauth2Authorization: (request: Request, options?: OAuth2AuthorizationOptions) => Promise<Response>;
52
- private readonly redirect;
53
80
  loginOAuth2Code: (request: Request, handler: AuthorizedHandler) => Promise<Response>;
54
- /**
55
- * A fresh session for `name`, carrying over what the host kept in the pre-login one. The
56
- * authorization request (state, PKCE verifier, flow attributes) is single-use and was consumed
57
- * by this callback, and a principal left there from an earlier sign-in is replaced.
58
- */
59
- private signedInSession;
81
+ /** The shared tail of the JSON login routes: the host's handler, then a signed-in session. */
82
+ private authorize;
60
83
  loginOAuth2Native: (request: Request, handler: AuthorizedHandler) => Promise<Response>;
61
84
  loginOAuth2Onetap: (request: Request, handler: AuthorizedHandler, provider?: string) => Promise<Response>;
62
- sendEmailVerificationCode: (request: Request, sender: (data: {
63
- email: string;
64
- verificationCode: string;
65
- }) => Promise<void>) => Promise<Response>;
85
+ sendEmailVerificationCode: (request: Request, sender: EmailSender) => Promise<Response>;
86
+ verifyEmailCode: (email: string, verificationCode: string) => Promise<void>;
66
87
  loginEmail: (request: Request, handler: AuthorizedHandler) => Promise<Response>;
67
88
  /**
68
- * Step 1 of the desktop / native app sign-in handshake. The caller already
69
- * completed normal sign-in on the web (so a cookie session exists); this
70
- * issues a 5-minute single-use code that the web page hands off to the
71
- * desktop client via a loopback redirect.
89
+ * Step 1 of the desktop / native app sign-in handshake. The caller already completed normal
90
+ * sign-in on the web (so a cookie session exists); this issues a 5-minute single-use code that
91
+ * the web page hands off to the desktop client via a loopback redirect.
72
92
  *
73
- * PKCE (RFC 7636, S256 only): the desktop generates a random `code_verifier`
74
- * before opening the browser, derives `code_challenge = base64url(sha256(verifier))`,
75
- * and threads the challenge through the URL → web page → here. We pin
76
- * the challenge to the code in KV; `desktopExchange` enforces that the
77
- * caller knows the matching verifier. This blocks an attacker who only
78
- * intercepts the auth code (browser history, malicious extension, packet
79
- * capture on loopback) from exchanging it.
93
+ * PKCE (RFC 7636, S256 only): the desktop generates a random `code_verifier` before opening the
94
+ * browser, derives `code_challenge = base64url(sha256(verifier))`, and threads the challenge
95
+ * through the URL → web page → here. The challenge is pinned to the code; `desktopExchange`
96
+ * enforces that the caller knows the matching verifier. This blocks an attacker who only
97
+ * intercepts the auth code (browser history, malicious extension, packet capture on loopback)
98
+ * from exchanging it.
80
99
  *
81
- * Requires an authenticated cookie session — anonymous callers get 401.
82
- * Throttling / abuse protection on this endpoint is the API layer's job
83
- * (rate-limit per principal); the SDK doesn't gate it because the
84
- * upstream sign-in flow already passed CAPTCHA / OAuth / verification.
100
+ * Requires an authenticated cookie session: anonymous callers get 401. Throttling / abuse
101
+ * protection on this endpoint is the API layer's job (rate-limit per principal); the SDK does
102
+ * not gate it because the upstream sign-in flow already passed CAPTCHA / OAuth / verification.
85
103
  */
86
104
  desktopAuthorize: (request: Request) => Promise<Response>;
87
105
  /**
88
- * Step 2 of the desktop / native app sign-in handshake. The desktop
89
- * client hands back the auth code it received via the loopback callback,
90
- * and we mint a fresh session for it — independent of the web cookie
91
- * session that originally `authorize`'d the code, so logging out on
92
- * either side doesn't cascade to the other.
106
+ * Step 2 of the desktop / native app sign-in handshake. The desktop client hands back the auth
107
+ * code it received via the loopback callback, and we mint a fresh session for it, independent
108
+ * of the web cookie session that originally authorized the code, so logging out on either side
109
+ * does not cascade to the other.
93
110
  *
94
- * Cookie attributes: defaults to `SameSite=None; Secure` so the cookie
95
- * survives cross-site fetches from the desktop renderer's `file://` /
96
- * `app://` origin. The configured base `cookieOptions` provide
97
- * everything else (`domain`, `path`, `httpOnly`, `maxAge`); the override
98
- * is targeted at the SameSite/Secure pair only. In a non-HTTPS dev
99
- * backend this combination is rejected by Chromium — see the desktop
100
- * sign-in PRD for workarounds.
111
+ * Cookie attributes: `SameSite=None; Secure` so the cookie survives cross-site fetches from the
112
+ * desktop renderer's `file://` / `app://` origin. The configured `cookieOptions` provide
113
+ * everything else (`domain`, `path`, `httpOnly`); the override is targeted at the
114
+ * SameSite/Secure pair only. In a non-HTTPS dev backend this combination is rejected by
115
+ * Chromium, see the desktop sign-in PRD for workarounds.
101
116
  *
102
- * No CSRF check needed — the request carries no cookie, the auth code
103
- * itself is the credential, and KV's single-use removal blocks replay.
117
+ * No CSRF check needed: the request carries no cookie, the auth code itself is the credential,
118
+ * and the code's single-use removal blocks replay.
104
119
  */
105
120
  desktopExchange: (request: Request) => Promise<Response>;
106
- sendPhoneVerificationCode: (_request: Request, _sender: (data: {
107
- phone: string;
108
- verificationCode: string;
109
- }) => Promise<void>) => Promise<Response>;
110
- loginPhone: (_request: Request, _handler: AuthorizedHandler) => Promise<Response>;
111
121
  kick: (principal: Principal) => Promise<void>;
112
122
  /**
113
123
  * Sliding expiration: an authenticated request renews the session, as `logged` does, so a user
@@ -117,12 +127,11 @@ export declare class Auth implements AuthService {
117
127
  * `AuthConfig`), so a session accessed again within the interval is not rewritten.
118
128
  */
119
129
  private touch;
130
+ getPrincipal: (request: Request) => Promise<Principal | null>;
120
131
  isAuthenticated: (request: Request) => Promise<boolean>;
121
132
  getSession: <T extends boolean>(request: Request, create: T) => Promise<T extends true ? Session : Session | null>;
122
133
  deleteSession: (sessionId: string) => Promise<void>;
123
- getPrincipal: (request: Request) => Promise<Principal | null>;
124
134
  listSessions: (principal: Principal) => Promise<Session[]>;
125
135
  cleanupExpiredSessions: (cleanupCount?: number) => Promise<Response>;
126
136
  }
127
- //#endregion
128
137
  //# sourceMappingURL=index.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.mts","names":[],"sources":["../../src/auth/index.ts"],"mappings":";;;;qBA4Ga;WACX;WACA;WACA;WAEA;WACA;WACA;WACA;WACA;WACA;WAEA;WACA;WACA;WACA;WASA;WACA;WAEA;;qBAMW,gBAAgB;mBACV;mBACA;mBACA;mBACA;mBACA;mBACA;mBACA;mBACA;mBACA;mBACA;mBACA;mBACA;EAEjB,cACE,mBACA,cACA,oBACA,kBACA,QACA,QACA,SACA,UACC;UA2BK;EAYR,OAAI,UAAoB,YAAU,QAAQ;EAmB1C,SAAM,SAAmB,YAAU,QAAQ;EAU3C,SAAM,SAAmB,SAAO,WAAa,kBAAgB,QAAQ;UAsB7D;UAUA;UAIA;UAIA;UAIA;UAIA;UAIA;UAIA;EAIR,cAAW,SAAmB,YAAU,QAAQ;EAOhD,cAAW,SAAmB,YAAU,QAAQ;EAOhD,sBAAmB,SACR,SAAO,UACN,+BACT,QAAQ;mBAmCM;EAUjB,kBAAe,SAAmB,SAAO,SAAW,sBAAoB,QAAQ;;;;;;UA+HxE;EAYR,oBAAiB,SAAmB,SAAO,SAAW,sBAAoB,QAAQ;EAmDlF,oBAAiB,SACN,SAAO,SACP,mBAAiB,sBAEzB,QAAQ;EA6EX,4BAAyB,SACd,SAAO,SACP;IAAQ;IAAe;QAA+B,kBAC9D,QAAQ;EA0CX,aAAU,SAAmB,SAAO,SAAW,sBAAoB,QAAQ;;;;;;;;;;;;;;;;;;;;EAsE3E,mBAAgB,SAAmB,YAAU,QAAQ;;;;;;;;;;;;;;;;;;;EA0DrD,kBAAe,SAAmB,YAAU,QAAQ;EAgEpD,4BAAyB,UACb,SAAO,UACP;IAAQ;IAAe;QAA+B,kBAC/D,QAAQ;EAIX,aAAU,UAAoB,SAAO,UAAY,sBAAoB,QAAQ;EAI7E,OAAI,WAA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