@thunderid/express 0.0.3 → 0.0.5
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.
- package/dist/ThunderIDExpressClient.d.ts +11 -9
- package/dist/ThunderIDExpressClient.d.ts.map +1 -1
- package/dist/cjs/index.cjs +306 -172
- package/dist/{__legacy__/constants/logger-config.d.ts → constants/CookieConfig.d.ts} +11 -11
- package/dist/constants/CookieConfig.d.ts.map +1 -0
- package/dist/edge/index.js +300 -172
- package/dist/index.d.ts +6 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +300 -172
- package/dist/middleware/authentication.d.ts +66 -0
- package/dist/middleware/authentication.d.ts.map +1 -0
- package/dist/middleware/flow.d.ts +50 -0
- package/dist/middleware/flow.d.ts.map +1 -0
- package/dist/{__legacy__/middleware/protect-route.d.ts → middleware/protect.d.ts} +12 -5
- package/dist/middleware/protect.d.ts.map +1 -0
- package/dist/models/config.d.ts +28 -9
- package/dist/models/config.d.ts.map +1 -1
- package/dist/{__legacy__/models/protect-route.d.ts → models/protectRoute.d.ts} +6 -3
- package/dist/models/protectRoute.d.ts.map +1 -0
- package/dist/{__legacy__/constants/index.d.ts → utils/expressUtils.d.ts} +9 -4
- package/dist/utils/expressUtils.d.ts.map +1 -0
- package/package.json +2 -2
- package/dist/__legacy__/client.d.ts +0 -46
- package/dist/__legacy__/client.d.ts.map +0 -1
- package/dist/__legacy__/constants/default-options.d.ts +0 -26
- package/dist/__legacy__/constants/default-options.d.ts.map +0 -1
- package/dist/__legacy__/constants/index.d.ts.map +0 -1
- package/dist/__legacy__/constants/logger-config.d.ts.map +0 -1
- package/dist/__legacy__/middleware/authentication.d.ts +0 -23
- package/dist/__legacy__/middleware/authentication.d.ts.map +0 -1
- package/dist/__legacy__/middleware/index.d.ts +0 -20
- package/dist/__legacy__/middleware/index.d.ts.map +0 -1
- package/dist/__legacy__/middleware/protect-route.d.ts.map +0 -1
- package/dist/__legacy__/models/client-config.d.ts +0 -33
- package/dist/__legacy__/models/client-config.d.ts.map +0 -1
- package/dist/__legacy__/models/data.d.ts +0 -21
- package/dist/__legacy__/models/data.d.ts.map +0 -1
- package/dist/__legacy__/models/index.d.ts +0 -21
- package/dist/__legacy__/models/index.d.ts.map +0 -1
- package/dist/__legacy__/models/protect-route.d.ts.map +0 -1
- package/dist/__legacy__/utils/express-utils.d.ts +0 -22
- package/dist/__legacy__/utils/express-utils.d.ts.map +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Copyright (c)
|
|
2
|
+
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
|
|
3
3
|
*
|
|
4
4
|
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
5
|
* Version 2.0 (the "License"); you may not use this file except
|
|
@@ -16,7 +16,14 @@
|
|
|
16
16
|
* under the License.
|
|
17
17
|
*/
|
|
18
18
|
import express from 'express';
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
19
|
+
/**
|
|
20
|
+
* Returns Express middleware that blocks unauthenticated requests.
|
|
21
|
+
* Requires `thunderID()` to be mounted before this middleware so that
|
|
22
|
+
* `req.thunderIDAuth` is populated.
|
|
23
|
+
*
|
|
24
|
+
* @param onUnauthenticated - Called when the session is missing or invalid.
|
|
25
|
+
* Defaults to sending a 401 response.
|
|
26
|
+
*/
|
|
27
|
+
declare const protect: (onUnauthenticated?: (res: express.Response) => void) => ((req: express.Request, res: express.Response, next: express.NextFunction) => Promise<void>);
|
|
28
|
+
export default protect;
|
|
29
|
+
//# sourceMappingURL=protect.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"protect.d.ts","sourceRoot":"","sources":["../../src/middleware/protect.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAGH,OAAO,OAAO,MAAM,SAAS,CAAC;AAI9B;;;;;;;GAOG;AACH,QAAA,MAAM,OAAO,GACX,oBAAoB,CAAC,GAAG,EAAE,OAAO,CAAC,QAAQ,KAAK,IAAI,KAClD,CAAC,CAAC,GAAG,EAAE,OAAO,CAAC,OAAO,EAAE,GAAG,EAAE,OAAO,CAAC,QAAQ,EAAE,IAAI,EAAE,OAAO,CAAC,YAAY,KAAK,OAAO,CAAC,IAAI,CAAC,CA4B7F,CAAC;AAEF,eAAe,OAAO,CAAC"}
|
package/dist/models/config.d.ts
CHANGED
|
@@ -15,16 +15,35 @@
|
|
|
15
15
|
* specific language governing permissions and limitations
|
|
16
16
|
* under the License.
|
|
17
17
|
*/
|
|
18
|
-
import { ThunderIDNodeConfig } from '@thunderid/node';
|
|
18
|
+
import { ThunderIDNodeConfig, ThunderIDRuntimeError, TokenResponse } from '@thunderid/node';
|
|
19
|
+
import express from 'express';
|
|
19
20
|
/**
|
|
20
|
-
*
|
|
21
|
-
|
|
21
|
+
* Express-specific configuration fields.
|
|
22
|
+
*/
|
|
23
|
+
export interface StrictExpressClientConfig {
|
|
24
|
+
/** Called with the response and token on successful sign-in. */
|
|
25
|
+
onSignIn?: (res: express.Response, tokenResponse: TokenResponse) => void;
|
|
26
|
+
/** Called with the response on successful sign-out. */
|
|
27
|
+
onSignOut?: (res: express.Response) => void;
|
|
28
|
+
/** Called with the response and error on authentication failure. */
|
|
29
|
+
onError?: (res: express.Response, exception: ThunderIDRuntimeError) => void;
|
|
30
|
+
/** Called with the response when a protected route is accessed without a valid session. */
|
|
31
|
+
onUnauthenticated?: (res: express.Response) => void;
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* Full configuration type for `ThunderIDExpressClient`.
|
|
35
|
+
* Combines node-level auth config with Express-specific settings.
|
|
36
|
+
*
|
|
37
|
+
* `afterSignInUrl` and `afterSignOutUrl` are optional. When omitted, the SDK
|
|
38
|
+
* infers them from the first incoming request's origin combined with the path
|
|
39
|
+
* derived from those URLs (defaulting to `/login` and `/logout`).
|
|
22
40
|
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
41
|
+
* Set `mode: 'embedded'` to enable app-native embedded auth via `handleFlow()`.
|
|
42
|
+
* Defaults to `'redirect'` (standard OAuth 2.0 authorization-code flow).
|
|
43
|
+
*/
|
|
44
|
+
export type ExpressClientConfig = ThunderIDNodeConfig & StrictExpressClientConfig;
|
|
45
|
+
/**
|
|
46
|
+
* Configuration type for the ThunderID Express.js SDK.
|
|
28
47
|
*/
|
|
29
|
-
export type ThunderIDExpressConfig =
|
|
48
|
+
export type ThunderIDExpressConfig = ExpressClientConfig;
|
|
30
49
|
//# sourceMappingURL=config.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/models/config.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAC,mBAAmB,EAAC,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/models/config.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAC,mBAAmB,EAAE,qBAAqB,EAAE,aAAa,EAAC,MAAM,iBAAiB,CAAC;AAC1F,OAAO,OAAO,MAAM,SAAS,CAAC;AAE9B;;GAEG;AACH,MAAM,WAAW,yBAAyB;IACxC,gEAAgE;IAChE,QAAQ,CAAC,EAAE,CAAC,GAAG,EAAE,OAAO,CAAC,QAAQ,EAAE,aAAa,EAAE,aAAa,KAAK,IAAI,CAAC;IACzE,uDAAuD;IACvD,SAAS,CAAC,EAAE,CAAC,GAAG,EAAE,OAAO,CAAC,QAAQ,KAAK,IAAI,CAAC;IAC5C,oEAAoE;IACpE,OAAO,CAAC,EAAE,CAAC,GAAG,EAAE,OAAO,CAAC,QAAQ,EAAE,SAAS,EAAE,qBAAqB,KAAK,IAAI,CAAC;IAC5E,2FAA2F;IAC3F,iBAAiB,CAAC,EAAE,CAAC,GAAG,EAAE,OAAO,CAAC,QAAQ,KAAK,IAAI,CAAC;CACrD;AAED;;;;;;;;;;GAUG;AACH,MAAM,MAAM,mBAAmB,GAAG,mBAAmB,GAAG,yBAAyB,CAAC;AAElF;;GAEG;AACH,MAAM,MAAM,sBAAsB,GAAG,mBAAmB,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Copyright (c)
|
|
2
|
+
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
|
|
3
3
|
*
|
|
4
4
|
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
5
|
* Version 2.0 (the "License"); you may not use this file except
|
|
@@ -16,5 +16,8 @@
|
|
|
16
16
|
* under the License.
|
|
17
17
|
*/
|
|
18
18
|
import express from 'express';
|
|
19
|
-
|
|
20
|
-
|
|
19
|
+
/**
|
|
20
|
+
* Callback invoked when an unauthenticated request hits a protected route.
|
|
21
|
+
*/
|
|
22
|
+
export type UnauthenticatedCallback = (res: express.Response) => void;
|
|
23
|
+
//# sourceMappingURL=protectRoute.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"protectRoute.d.ts","sourceRoot":"","sources":["../../src/models/protectRoute.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,OAAO,MAAM,SAAS,CAAC;AAE9B;;GAEG;AACH,MAAM,MAAM,uBAAuB,GAAG,CAAC,GAAG,EAAE,OAAO,CAAC,QAAQ,KAAK,IAAI,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Copyright (c)
|
|
2
|
+
* Copyright (c) 2025, WSO2 LLC. (https://www.wso2.com).
|
|
3
3
|
*
|
|
4
4
|
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
5
|
* Version 2.0 (the "License"); you may not use this file except
|
|
@@ -15,6 +15,11 @@
|
|
|
15
15
|
* specific language governing permissions and limitations
|
|
16
16
|
* under the License.
|
|
17
17
|
*/
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
18
|
+
/**
|
|
19
|
+
* Returns `true` if the given URL contains an OAuth error query parameter.
|
|
20
|
+
*
|
|
21
|
+
* @param url - The URL to inspect.
|
|
22
|
+
*/
|
|
23
|
+
declare const hasErrorInURL: (url: string) => boolean;
|
|
24
|
+
export default hasErrorInURL;
|
|
25
|
+
//# sourceMappingURL=expressUtils.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"expressUtils.d.ts","sourceRoot":"","sources":["../../src/utils/expressUtils.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAIH;;;;GAIG;AACH,QAAA,MAAM,aAAa,GAAI,KAAK,MAAM,KAAG,OAAsC,CAAC;AAE5E,eAAe,aAAa,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@thunderid/express",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.5",
|
|
4
4
|
"description": "Express.js SDK for ThunderID",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"thunderid",
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
},
|
|
47
47
|
"dependencies": {
|
|
48
48
|
"uuid": "11.1.0",
|
|
49
|
-
"@thunderid/node": "^0.0.
|
|
49
|
+
"@thunderid/node": "^0.0.6"
|
|
50
50
|
},
|
|
51
51
|
"peerDependencies": {
|
|
52
52
|
"express": ">=4.21.2"
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright (c) 2026, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
-
*
|
|
4
|
-
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
-
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
-
* in compliance with the License.
|
|
7
|
-
* You may obtain a copy of the License at
|
|
8
|
-
*
|
|
9
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
-
*
|
|
11
|
-
* Unless required by applicable law or agreed to in writing,
|
|
12
|
-
* software distributed under the License is distributed on an
|
|
13
|
-
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
-
* KIND, either express or implied. See the License for the
|
|
15
|
-
* specific language governing permissions and limitations
|
|
16
|
-
* under the License.
|
|
17
|
-
*/
|
|
18
|
-
import { AuthClientConfig, TokenResponse, Storage, User, OIDCEndpoints, IdToken, TokenExchangeRequestConfig, ThunderIDAuthException } from '@thunderid/node';
|
|
19
|
-
import express from 'express';
|
|
20
|
-
import { ExpressClientConfig, UnauthenticatedCallback } from './models';
|
|
21
|
-
export declare class ThunderIDExpressClient {
|
|
22
|
-
private _authClient;
|
|
23
|
-
private _storage?;
|
|
24
|
-
private static _clientConfig;
|
|
25
|
-
private static _instance;
|
|
26
|
-
private constructor();
|
|
27
|
-
static getInstance(config: ExpressClientConfig, storage?: Storage): ThunderIDExpressClient;
|
|
28
|
-
static getInstance(): ThunderIDExpressClient;
|
|
29
|
-
signIn(req: express.Request, res: express.Response, next: express.nextFunction, signInConfig?: Record<string, string | boolean>): Promise<TokenResponse>;
|
|
30
|
-
signOut(userId: string): Promise<string>;
|
|
31
|
-
isSignedIn(userId: string): Promise<boolean>;
|
|
32
|
-
getIdToken(userId: string): Promise<string>;
|
|
33
|
-
getUser(userId: string): Promise<User>;
|
|
34
|
-
getOpenIDProviderEndpoints(): Promise<OIDCEndpoints>;
|
|
35
|
-
getDecodedIdToken(userId?: string): Promise<IdToken>;
|
|
36
|
-
getAccessToken(userId?: string): Promise<string>;
|
|
37
|
-
exchangeToken(config: TokenExchangeRequestConfig, userId?: string): Promise<TokenResponse | Response>;
|
|
38
|
-
reInitialize(config: Partial<AuthClientConfig>): Promise<void>;
|
|
39
|
-
revokeAccessToken(userId?: string): Promise<Response>;
|
|
40
|
-
static didSignOutFail(afterSignOutUrl: string): boolean;
|
|
41
|
-
static isSignOutSuccessful(afterSignOutUrl: string): boolean;
|
|
42
|
-
static protectRoute(callback: UnauthenticatedCallback): (req: express.Request, res: express.Response, next: express.nextFunction) => Promise<void>;
|
|
43
|
-
static thunderIDExpressAuth(onSignIn: (response: TokenResponse) => void, onSignOut: () => void, onError: (exception: ThunderIDAuthException) => void): any;
|
|
44
|
-
getStorageManager(): Promise<import("@thunderid/node").StorageManager<import("@thunderid/node").StrictAuthClientConfig>>;
|
|
45
|
-
}
|
|
46
|
-
//# sourceMappingURL=client.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../src/__legacy__/client.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAEL,gBAAgB,EAEhB,aAAa,EACb,OAAO,EACP,IAAI,EACJ,aAAa,EACb,OAAO,EACP,0BAA0B,EAC1B,sBAAsB,EAEvB,MAAM,iBAAiB,CAAC;AACzB,OAAO,OAAO,MAAM,SAAS,CAAC;AAI9B,OAAO,EAAC,mBAAmB,EAAE,uBAAuB,EAAC,MAAM,UAAU,CAAC;AAGtE,qBAAa,sBAAsB;IACjC,OAAO,CAAC,WAAW,CAA8C;IACjE,OAAO,CAAC,QAAQ,CAAC,CAAU;IAC3B,OAAO,CAAC,MAAM,CAAC,aAAa,CAAsB;IAElD,OAAO,CAAC,MAAM,CAAC,SAAS,CAAyB;IAEjD,OAAO;WAuBO,WAAW,CAAC,MAAM,EAAE,mBAAmB,EAAE,OAAO,CAAC,EAAE,OAAO,GAAG,sBAAsB;WACnF,WAAW,IAAI,sBAAsB;IAqBtC,MAAM,CACjB,GAAG,EAAE,OAAO,CAAC,OAAO,EACpB,GAAG,EAAE,OAAO,CAAC,QAAQ,EACrB,IAAI,EAAE,OAAO,CAAC,YAAY,EAC1B,YAAY,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,GAC9C,OAAO,CAAC,aAAa,CAAC;IA4DZ,OAAO,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAIxC,UAAU,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC;IAI5C,UAAU,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAI3C,OAAO,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAItC,0BAA0B,IAAI,OAAO,CAAC,aAAa,CAAC;IAIpD,iBAAiB,CAAC,MAAM,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC;IAIpD,cAAc,CAAC,MAAM,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAIhD,aAAa,CAAC,MAAM,EAAE,0BAA0B,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,aAAa,GAAG,QAAQ,CAAC;IAIrG,YAAY,CAAC,MAAM,EAAE,OAAO,CAAC,gBAAgB,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC;IAI9D,iBAAiB,CAAC,MAAM,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,QAAQ,CAAC;WAIpD,cAAc,CAAC,eAAe,EAAE,MAAM,GAAG,OAAO;WAIhD,mBAAmB,CAAC,eAAe,EAAE,MAAM,GAAG,OAAO;WAIrD,YAAY,CACxB,QAAQ,EAAE,uBAAuB,GAChC,CAAC,GAAG,EAAE,OAAO,CAAC,OAAO,EAAE,GAAG,EAAE,OAAO,CAAC,QAAQ,EAAE,IAAI,EAAE,OAAO,CAAC,YAAY,KAAK,OAAO,CAAC,IAAI,CAAC;WAY/E,oBAAoB,CAChC,QAAQ,EAAE,CAAC,QAAQ,EAAE,aAAa,KAAK,IAAI,EAC3C,SAAS,EAAE,MAAM,IAAI,EACrB,OAAO,EAAE,CAAC,SAAS,EAAE,sBAAsB,KAAK,IAAI,GACnD,GAAG;IAYO,iBAAiB;CAG/B"}
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright (c) 2026, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
-
*
|
|
4
|
-
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
-
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
-
* in compliance with the License.
|
|
7
|
-
* You may obtain a copy of the License at
|
|
8
|
-
*
|
|
9
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
-
*
|
|
11
|
-
* Unless required by applicable law or agreed to in writing,
|
|
12
|
-
* software distributed under the License is distributed on an
|
|
13
|
-
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
-
* KIND, either express or implied. See the License for the
|
|
15
|
-
* specific language governing permissions and limitations
|
|
16
|
-
* under the License.
|
|
17
|
-
*/
|
|
18
|
-
export declare enum CookieConfig {
|
|
19
|
-
defaultMaxAge = 90000,
|
|
20
|
-
defaultHttpOnly = "true",
|
|
21
|
-
defaultSameSite = "lax",
|
|
22
|
-
defaultSecure = "false"
|
|
23
|
-
}
|
|
24
|
-
export declare const DEFAULT_LOGIN_PATH = "/login";
|
|
25
|
-
export declare const DEFAULT_LOGOUT_PATH = "/logout";
|
|
26
|
-
//# sourceMappingURL=default-options.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"default-options.d.ts","sourceRoot":"","sources":["../../../src/__legacy__/constants/default-options.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,oBAAY,YAAY;IACtB,aAAa,QAAQ;IACrB,eAAe,SAAS;IACxB,eAAe,QAAQ;IACvB,aAAa,UAAU;CACxB;AAED,eAAO,MAAM,kBAAkB,WAAW,CAAC;AAE3C,eAAO,MAAM,mBAAmB,YAAY,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/__legacy__/constants/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,cAAc,mBAAmB,CAAC;AAClC,cAAc,iBAAiB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"logger-config.d.ts","sourceRoot":"","sources":["../../../src/__legacy__/constants/logger-config.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,eAAO,MAAM,aAAa;;;;;;;;;CASzB,CAAC"}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright (c) 2026, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
-
*
|
|
4
|
-
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
-
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
-
* in compliance with the License.
|
|
7
|
-
* You may obtain a copy of the License at
|
|
8
|
-
*
|
|
9
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
-
*
|
|
11
|
-
* Unless required by applicable law or agreed to in writing,
|
|
12
|
-
* software distributed under the License is distributed on an
|
|
13
|
-
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
-
* KIND, either express or implied. See the License for the
|
|
15
|
-
* specific language governing permissions and limitations
|
|
16
|
-
* under the License.
|
|
17
|
-
*/
|
|
18
|
-
import { ThunderIDAuthException, TokenResponse } from '@thunderid/node';
|
|
19
|
-
import express from 'express';
|
|
20
|
-
import { ThunderIDExpressClient } from '../client';
|
|
21
|
-
import { ExpressClientConfig } from '../models';
|
|
22
|
-
export declare const thunderIDExpressAuth: (thunderIDExpressClient: ThunderIDExpressClient, config: ExpressClientConfig, onSignIn: (res: express.Response, tokenResponse: TokenResponse) => void, onSignOut: (res: express.Response) => void, onError: (res: express.Response, exception: ThunderIDAuthException) => void) => any;
|
|
23
|
-
//# sourceMappingURL=authentication.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"authentication.d.ts","sourceRoot":"","sources":["../../../src/__legacy__/middleware/authentication.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAC,sBAAsB,EAAW,aAAa,EAAS,MAAM,iBAAiB,CAAC;AACvF,OAAO,OAAO,MAAM,SAAS,CAAC;AAC9B,OAAO,EAAC,sBAAsB,EAAC,MAAM,WAAW,CAAC;AAEjD,OAAO,EAAC,mBAAmB,EAAC,MAAM,WAAW,CAAC;AAE9C,eAAO,MAAM,oBAAoB,GAC/B,wBAAwB,sBAAsB,EAC9C,QAAQ,mBAAmB,EAC3B,UAAU,CAAC,GAAG,EAAE,OAAO,CAAC,QAAQ,EAAE,aAAa,EAAE,aAAa,KAAK,IAAI,EACvE,WAAW,CAAC,GAAG,EAAE,OAAO,CAAC,QAAQ,KAAK,IAAI,EAC1C,SAAS,CAAC,GAAG,EAAE,OAAO,CAAC,QAAQ,EAAE,SAAS,EAAE,sBAAsB,KAAK,IAAI,KAC1E,GAsEF,CAAC"}
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright (c) 2026, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
-
*
|
|
4
|
-
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
-
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
-
* in compliance with the License.
|
|
7
|
-
* You may obtain a copy of the License at
|
|
8
|
-
*
|
|
9
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
-
*
|
|
11
|
-
* Unless required by applicable law or agreed to in writing,
|
|
12
|
-
* software distributed under the License is distributed on an
|
|
13
|
-
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
-
* KIND, either express or implied. See the License for the
|
|
15
|
-
* specific language governing permissions and limitations
|
|
16
|
-
* under the License.
|
|
17
|
-
*/
|
|
18
|
-
export * from './protect-route';
|
|
19
|
-
export * from './authentication';
|
|
20
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/__legacy__/middleware/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,cAAc,iBAAiB,CAAC;AAChC,cAAc,kBAAkB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"protect-route.d.ts","sourceRoot":"","sources":["../../../src/__legacy__/middleware/protect-route.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAGH,OAAO,OAAO,MAAM,SAAS,CAAC;AAC9B,OAAO,EAAC,sBAAsB,EAAC,MAAM,WAAW,CAAC;AACjD,OAAO,EAAC,uBAAuB,EAAC,MAAM,WAAW,CAAC;AAElD,eAAO,MAAM,YAAY,GACvB,wBAAwB,sBAAsB,EAC9C,UAAU,uBAAuB,KAChC,CAAC,CAAC,GAAG,EAAE,OAAO,CAAC,OAAO,EAAE,GAAG,EAAE,OAAO,CAAC,QAAQ,EAAE,IAAI,EAAE,OAAO,CAAC,YAAY,KAAK,OAAO,CAAC,IAAI,CAAC,CAyB7F,CAAC"}
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright (c) 2026, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
-
*
|
|
4
|
-
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
-
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
-
* in compliance with the License.
|
|
7
|
-
* You may obtain a copy of the License at
|
|
8
|
-
*
|
|
9
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
-
*
|
|
11
|
-
* Unless required by applicable law or agreed to in writing,
|
|
12
|
-
* software distributed under the License is distributed on an
|
|
13
|
-
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
-
* KIND, either express or implied. See the License for the
|
|
15
|
-
* specific language governing permissions and limitations
|
|
16
|
-
* under the License.
|
|
17
|
-
*/
|
|
18
|
-
import { AuthClientConfig } from '@thunderid/node';
|
|
19
|
-
export interface StrictExpressClientConfig {
|
|
20
|
-
appURL: string;
|
|
21
|
-
cookieConfig?: {
|
|
22
|
-
maxAge?: number;
|
|
23
|
-
httpOnly?: boolean;
|
|
24
|
-
sameSite?: string;
|
|
25
|
-
secure?: boolean;
|
|
26
|
-
};
|
|
27
|
-
globalAuth?: boolean;
|
|
28
|
-
loginPath?: string;
|
|
29
|
-
logoutPath?: string;
|
|
30
|
-
signInConfig?: Record<string, string | boolean>;
|
|
31
|
-
}
|
|
32
|
-
export type ExpressClientConfig = Exclude<AuthClientConfig, 'afterSignInUrl' | 'afterSignOutUrl'> & StrictExpressClientConfig;
|
|
33
|
-
//# sourceMappingURL=client-config.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"client-config.d.ts","sourceRoot":"","sources":["../../../src/__legacy__/models/client-config.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAC,gBAAgB,EAAC,MAAM,iBAAiB,CAAC;AAEjD,MAAM,WAAW,yBAAyB;IACxC,MAAM,EAAE,MAAM,CAAC;IACf,YAAY,CAAC,EAAE;QACb,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,QAAQ,CAAC,EAAE,OAAO,CAAC;QACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;QAClB,MAAM,CAAC,EAAE,OAAO,CAAC;KAClB,CAAC;IACF,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,YAAY,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,CAAC;CACjD;AAED,MAAM,MAAM,mBAAmB,GAAG,OAAO,CAAC,gBAAgB,EAAE,gBAAgB,GAAG,iBAAiB,CAAC,GAC/F,yBAAyB,CAAC"}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright (c) 2026, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
-
*
|
|
4
|
-
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
-
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
-
* in compliance with the License.
|
|
7
|
-
* You may obtain a copy of the License at
|
|
8
|
-
*
|
|
9
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
-
*
|
|
11
|
-
* Unless required by applicable law or agreed to in writing,
|
|
12
|
-
* software distributed under the License is distributed on an
|
|
13
|
-
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
-
* KIND, either express or implied. See the License for the
|
|
15
|
-
* specific language governing permissions and limitations
|
|
16
|
-
* under the License.
|
|
17
|
-
*/
|
|
18
|
-
export interface AuthURL {
|
|
19
|
-
url: string;
|
|
20
|
-
}
|
|
21
|
-
//# sourceMappingURL=data.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"data.d.ts","sourceRoot":"","sources":["../../../src/__legacy__/models/data.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,MAAM,WAAW,OAAO;IACtB,GAAG,EAAE,MAAM,CAAC;CACb"}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright (c) 2026, WSO2 LLC. (https://www.wso2.com).
|
|
3
|
-
*
|
|
4
|
-
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
5
|
-
* Version 2.0 (the "License"); you may not use this file except
|
|
6
|
-
* in compliance with the License.
|
|
7
|
-
* You may obtain a copy of the License at
|
|
8
|
-
*
|
|
9
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
10
|
-
*
|
|
11
|
-
* Unless required by applicable law or agreed to in writing,
|
|
12
|
-
* software distributed under the License is distributed on an
|
|
13
|
-
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
14
|
-
* KIND, either express or implied. See the License for the
|
|
15
|
-
* specific language governing permissions and limitations
|
|
16
|
-
* under the License.
|
|
17
|
-
*/
|
|
18
|
-
export * from './data';
|
|
19
|
-
export * from './client-config';
|
|
20
|
-
export * from './protect-route';
|
|
21
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/__legacy__/models/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,cAAc,QAAQ,CAAC;AACvB,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"protect-route.d.ts","sourceRoot":"","sources":["../../../src/__legacy__/models/protect-route.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,OAAO,MAAM,SAAS,CAAC;AAE9B,MAAM,MAAM,uBAAuB,GAAG,CAAC,GAAG,EAAE,OAAO,CAAC,QAAQ,EAAE,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC"}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
export declare class ExpressUtils {
|
|
2
|
-
private static readonly AUTH_CODE_REGEXP;
|
|
3
|
-
/**
|
|
4
|
-
* Copyright (c) 2026, WSO2 LLC. (https://www.wso2.com).
|
|
5
|
-
*
|
|
6
|
-
* WSO2 LLC. licenses this file to you under the Apache License,
|
|
7
|
-
* Version 2.0 (the "License"); you may not use this file except
|
|
8
|
-
* in compliance with the License.
|
|
9
|
-
* You may obtain a copy of the License at
|
|
10
|
-
*
|
|
11
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
12
|
-
*
|
|
13
|
-
* Unless required by applicable law or agreed to in writing,
|
|
14
|
-
* software distributed under the License is distributed on an
|
|
15
|
-
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
16
|
-
* KIND, either express or implied. See the License for the
|
|
17
|
-
* specific language governing permissions and limitations
|
|
18
|
-
* under the License.
|
|
19
|
-
*/
|
|
20
|
-
static hasErrorInURL(url: string): boolean;
|
|
21
|
-
}
|
|
22
|
-
//# sourceMappingURL=express-utils.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"express-utils.d.ts","sourceRoot":"","sources":["../../../src/__legacy__/utils/express-utils.ts"],"names":[],"mappings":"AAAA,qBAAa,YAAY;IACvB,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,gBAAgB,CAA6B;IAErE;;;;;;;;;;;;;;;;OAgBG;WACW,aAAa,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO;CAGlD"}
|