@toa.io/extensions.exposition 1.0.0-alpha.150 → 1.0.0-alpha.152
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/components/identity.federation/manifest.toa.yaml +12 -13
- package/components/identity.federation/operations/authenticate.js +0 -1
- package/components/identity.federation/operations/authenticate.js.map +1 -1
- package/components/identity.federation/operations/decode.js +0 -1
- package/components/identity.federation/operations/decode.js.map +1 -1
- package/components/identity.federation/operations/incept.d.ts +1 -1
- package/components/identity.federation/operations/incept.js +1 -2
- package/components/identity.federation/operations/incept.js.map +1 -1
- package/components/identity.federation/operations/lib/Ctx.d.ts +1 -2
- package/components/identity.federation/operations/lib/decode.js +0 -14
- package/components/identity.federation/operations/lib/decode.js.map +1 -1
- package/components/identity.federation/operations/lib/exchange.js +1 -1
- package/components/identity.federation/operations/lib/exchange.js.map +1 -1
- package/components/identity.federation/operations/tsconfig.tsbuildinfo +1 -1
- package/components/identity.federation/operations/types/context.d.ts +1 -2
- package/components/identity.federation/source/authenticate.ts +0 -1
- package/components/identity.federation/source/decode.ts +0 -1
- package/components/identity.federation/source/incept.ts +2 -3
- package/components/identity.federation/source/lib/Ctx.ts +1 -2
- package/components/identity.federation/source/lib/decode.ts +1 -21
- package/components/identity.federation/source/lib/exchange.ts +1 -1
- package/components/identity.federation/source/types/context.ts +1 -3
- package/documentation/map.md +10 -0
- package/features/identity.federation.feature +1 -37
- package/features/map.feature +24 -0
- package/package.json +3 -2
- package/source/RTD/Route.ts +8 -2
- package/source/RTD/segment.ts +2 -0
- package/source/directives/auth/Incept.ts +1 -0
- package/transpiled/RTD/Route.d.ts +1 -0
- package/transpiled/RTD/Route.js +7 -2
- package/transpiled/RTD/Route.js.map +1 -1
- package/transpiled/RTD/segment.d.ts +1 -0
- package/transpiled/RTD/segment.js +2 -0
- package/transpiled/RTD/segment.js.map +1 -1
- package/transpiled/directives/auth/Incept.js +1 -0
- package/transpiled/directives/auth/Incept.js.map +1 -1
- package/transpiled/tsconfig.tsbuildinfo +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { JWTPayload } from 'jose';
|
|
2
|
-
import type { Call, Observation, Query,
|
|
2
|
+
import type { Call, Observation, Query, telemetry } from '@toa.io/types';
|
|
3
3
|
import type { Entity } from './entity';
|
|
4
4
|
import type { Configuration } from './configuration';
|
|
5
5
|
export interface Context {
|
|
@@ -17,7 +17,6 @@ export interface Context {
|
|
|
17
17
|
};
|
|
18
18
|
};
|
|
19
19
|
logs: telemetry.Logs;
|
|
20
|
-
stash: Stash;
|
|
21
20
|
configuration: Configuration;
|
|
22
21
|
}
|
|
23
22
|
export interface TransitInput {
|
|
@@ -4,11 +4,10 @@ import type { Request } from '@toa.io/types'
|
|
|
4
4
|
import type { Context, Entity, TransitInput, Scheme } from './types'
|
|
5
5
|
|
|
6
6
|
export async function effect (input: Input, context: Context): Promise<Output | Error> {
|
|
7
|
-
if (input.scheme
|
|
7
|
+
if (input.scheme === 'code') return ERR_SCHEME
|
|
8
8
|
|
|
9
9
|
const payload = await decode(input.credentials, {
|
|
10
10
|
trust: context.configuration.trust,
|
|
11
|
-
stash: context.stash,
|
|
12
11
|
logs: context.logs
|
|
13
12
|
})
|
|
14
13
|
|
|
@@ -27,9 +26,9 @@ export async function effect (input: Input, context: Context): Promise<Output |
|
|
|
27
26
|
const ERR_SCHEME = new Err('ERR_SCHEME', 'Unsupported scheme')
|
|
28
27
|
|
|
29
28
|
export interface Input {
|
|
30
|
-
scheme: Scheme
|
|
31
29
|
authority: string
|
|
32
30
|
credentials: string
|
|
31
|
+
scheme?: Scheme
|
|
33
32
|
id?: string
|
|
34
33
|
}
|
|
35
34
|
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import * as jose from 'jose'
|
|
2
2
|
import { createRemoteJWKSet } from './discovery'
|
|
3
|
-
import { ERR_TRUST, ERR_ISS, ERR_SUB
|
|
4
|
-
import type { Stash } from '@toa.io/types'
|
|
3
|
+
import { ERR_TRUST, ERR_ISS, ERR_SUB } from './errors'
|
|
5
4
|
import type { Ctx } from './Ctx'
|
|
6
5
|
import type { Payload } from './Payload'
|
|
7
6
|
|
|
@@ -25,24 +24,5 @@ export async function decode (token: string, ctx: Ctx): Promise<Payload | Error>
|
|
|
25
24
|
|
|
26
25
|
const { payload } = await jose.jwtVerify(token, jwks[iss], { audience: trusted.aud })
|
|
27
26
|
|
|
28
|
-
if (payload.jti !== undefined) {
|
|
29
|
-
const error = await validateJti(payload, ctx.stash)
|
|
30
|
-
|
|
31
|
-
if (error instanceof Error)
|
|
32
|
-
return error
|
|
33
|
-
}
|
|
34
|
-
|
|
35
27
|
return payload as Payload
|
|
36
28
|
}
|
|
37
|
-
|
|
38
|
-
async function validateJti (payload: jose.JWTPayload, stash: Stash): Promise<void | Error> {
|
|
39
|
-
if (payload.exp === undefined)
|
|
40
|
-
return ERR_EXP
|
|
41
|
-
|
|
42
|
-
const ttl = payload.exp - Math.floor(Date.now() / 1000)
|
|
43
|
-
const key = `identity:federation:jti:${payload.jti}`
|
|
44
|
-
const ok = await stash.set(key, 1, 'EX', ttl, 'NX') // set if not exists
|
|
45
|
-
|
|
46
|
-
if (ok === null)
|
|
47
|
-
return ERR_REPLAY
|
|
48
|
-
}
|
|
@@ -95,7 +95,7 @@ async function sign (trust: Trust): Promise<string> {
|
|
|
95
95
|
const signature = trust.signature!
|
|
96
96
|
const aud = Array.isArray(trust.aud) ? trust.aud[0] : trust.aud!
|
|
97
97
|
const now = Math.floor(Date.now() / 1000)
|
|
98
|
-
const key = await jose.importPKCS8(signature.key, 'ES256')
|
|
98
|
+
const key = await jose.importPKCS8(atob(signature.key), 'ES256')
|
|
99
99
|
|
|
100
100
|
return await new jose.SignJWT({})
|
|
101
101
|
.setProtectedHeader({ alg: 'ES256', kid: signature.kid })
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import type { JWTPayload } from 'jose'
|
|
2
|
-
|
|
3
|
-
import type { Call, Observation, Query, Stash, telemetry } from '@toa.io/types'
|
|
2
|
+
import type { Call, Observation, Query, telemetry } from '@toa.io/types'
|
|
4
3
|
import type { Entity } from './entity'
|
|
5
4
|
import type { Configuration } from './configuration'
|
|
6
5
|
|
|
@@ -19,7 +18,6 @@ export interface Context {
|
|
|
19
18
|
}
|
|
20
19
|
}
|
|
21
20
|
logs: telemetry.Logs
|
|
22
|
-
stash: Stash
|
|
23
21
|
configuration: Configuration
|
|
24
22
|
}
|
|
25
23
|
|
package/documentation/map.md
CHANGED
|
@@ -75,6 +75,16 @@ remaining directives or used as criteria in the operation call.
|
|
|
75
75
|
endpoint: create
|
|
76
76
|
```
|
|
77
77
|
|
|
78
|
+
Wildcard routes are supported by using `**` as the parameter name.
|
|
79
|
+
|
|
80
|
+
```yaml
|
|
81
|
+
/path/to/**:
|
|
82
|
+
GET:
|
|
83
|
+
map:segments:
|
|
84
|
+
path: '**'
|
|
85
|
+
endpoint: observe
|
|
86
|
+
```
|
|
87
|
+
|
|
78
88
|
## Bearer token claims
|
|
79
89
|
|
|
80
90
|
The `map:claims` directive maps the values of
|
|
@@ -236,42 +236,6 @@ Feature: Identity Federation
|
|
|
236
236
|
id: ${{ Bob.id }}
|
|
237
237
|
"""
|
|
238
238
|
|
|
239
|
-
Scenario: Tokens with `jti` are one-time
|
|
240
|
-
Given the `identity.federation` configuration:
|
|
241
|
-
"""yaml
|
|
242
|
-
trust:
|
|
243
|
-
- iss: http://localhost:44444
|
|
244
|
-
"""
|
|
245
|
-
And ID token with jti is issued for User
|
|
246
|
-
When the following request is received:
|
|
247
|
-
"""
|
|
248
|
-
GET /identity/ HTTP/1.1
|
|
249
|
-
host: nex.toa.io
|
|
250
|
-
authorization: Bearer ${{ User.id_token }}
|
|
251
|
-
accept: application/yaml
|
|
252
|
-
"""
|
|
253
|
-
Then the following reply is sent:
|
|
254
|
-
"""
|
|
255
|
-
200 OK
|
|
256
|
-
authorization: Token ${{ User.token }}
|
|
257
|
-
|
|
258
|
-
id: ${{ User.id }}
|
|
259
|
-
roles: []
|
|
260
|
-
"""
|
|
261
|
-
|
|
262
|
-
# second use
|
|
263
|
-
When the following request is received:
|
|
264
|
-
"""
|
|
265
|
-
GET /identity/ HTTP/1.1
|
|
266
|
-
host: nex.toa.io
|
|
267
|
-
authorization: Bearer ${{ User.id_token }}
|
|
268
|
-
accept: application/yaml
|
|
269
|
-
"""
|
|
270
|
-
Then the following reply is sent:
|
|
271
|
-
"""
|
|
272
|
-
401 Unauthorized
|
|
273
|
-
"""
|
|
274
|
-
|
|
275
239
|
Scenario: Authorization code flow with secret
|
|
276
240
|
Given the `identity.federation` configuration:
|
|
277
241
|
"""yaml
|
|
@@ -305,7 +269,7 @@ Feature: Identity Federation
|
|
|
305
269
|
signature:
|
|
306
270
|
iss: io.toa.nex.id
|
|
307
271
|
kid: key-id
|
|
308
|
-
key:
|
|
272
|
+
key: LS0tLS1CRUdJTiBQUklWQVRFIEtFWS0tLS0tCk1JR0hBZ0VBTUJNR0J5cUdTTTQ5QWdFR0NDcUdTTTQ5QXdFSEJHMHdhd0lCQVFRZzl4OURhdHdIMEdaSFNDbzkKVE1IVFZYeWVZMFlROHFiNzNqSFYydjRNc3llaFJBTkNBQVF3YVlsbmEyaFNWM0cvUklsTkxWNDFsZzhQbTRLZgpIZkN1S0tpdzNCSUpUblNBckFNSkxTeTF2WXdTSU1IejcyMG1rbVdUcld1UWtranZrRHBaeGZSdgotLS0tLUVORCBQUklWQVRFIEtFWS0tLS0t
|
|
309
273
|
"""
|
|
310
274
|
And auth code for Bob is issued for https://web.toa.io/callback/
|
|
311
275
|
When the following request is received:
|
package/features/map.feature
CHANGED
|
@@ -165,6 +165,30 @@ Feature: HTTP context mapping
|
|
|
165
165
|
Hello Ken
|
|
166
166
|
"""
|
|
167
167
|
|
|
168
|
+
Scenario: Mapping wildcard route parameter
|
|
169
|
+
Given the `echo` is running with the following manifest:
|
|
170
|
+
"""yaml
|
|
171
|
+
exposition:
|
|
172
|
+
/foo/**:
|
|
173
|
+
io:output: true
|
|
174
|
+
GET:
|
|
175
|
+
map:segments:
|
|
176
|
+
name: '**'
|
|
177
|
+
endpoint: compute
|
|
178
|
+
"""
|
|
179
|
+
When the following request is received:
|
|
180
|
+
"""
|
|
181
|
+
GET /echo/foo/bar/baz/ HTTP/1.1
|
|
182
|
+
host: nex.toa.io
|
|
183
|
+
accept: text/plain
|
|
184
|
+
"""
|
|
185
|
+
Then the following reply is sent:
|
|
186
|
+
"""
|
|
187
|
+
200 OK
|
|
188
|
+
|
|
189
|
+
Hello bar/baz
|
|
190
|
+
"""
|
|
191
|
+
|
|
168
192
|
Scenario: Mapping the authority
|
|
169
193
|
Given the annotation:
|
|
170
194
|
"""yaml
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@toa.io/extensions.exposition",
|
|
3
|
-
"version": "1.0.0-alpha.
|
|
3
|
+
"version": "1.0.0-alpha.152",
|
|
4
4
|
"description": "Toa Exposition",
|
|
5
5
|
"author": "temich <tema.gurtovoy@gmail.com>",
|
|
6
6
|
"homepage": "https://github.com/toa-io/toa#readme",
|
|
@@ -17,6 +17,7 @@
|
|
|
17
17
|
"access": "public"
|
|
18
18
|
},
|
|
19
19
|
"dependencies": {
|
|
20
|
+
"@aws-sdk/protocol-http": "3.370.0",
|
|
20
21
|
"@simplewebauthn/server": "13.1.1",
|
|
21
22
|
"@toa.io/core": "1.0.0-alpha.136",
|
|
22
23
|
"@toa.io/generic": "1.0.0-alpha.93",
|
|
@@ -62,5 +63,5 @@
|
|
|
62
63
|
},
|
|
63
64
|
"testEnvironment": "node"
|
|
64
65
|
},
|
|
65
|
-
"gitHead": "
|
|
66
|
+
"gitHead": "066053005ffced9760789e1db1628b6526c1fae3"
|
|
66
67
|
}
|
package/source/RTD/Route.ts
CHANGED
|
@@ -7,6 +7,7 @@ export class Route {
|
|
|
7
7
|
public readonly variables: number = 0
|
|
8
8
|
public readonly segments: Segment[]
|
|
9
9
|
private readonly node: Node
|
|
10
|
+
private readonly wildcard: boolean = false
|
|
10
11
|
|
|
11
12
|
public constructor (segments: Segment[], node: Node) {
|
|
12
13
|
this.root = segments.length === 0
|
|
@@ -14,8 +15,10 @@ export class Route {
|
|
|
14
15
|
this.node = node
|
|
15
16
|
|
|
16
17
|
for (const segment of segments)
|
|
17
|
-
if (segment.fragment === null)
|
|
18
|
+
if (segment.fragment === null) {
|
|
18
19
|
this.variables++
|
|
20
|
+
this.wildcard ||= segment.wildcard === true
|
|
21
|
+
}
|
|
19
22
|
}
|
|
20
23
|
|
|
21
24
|
public match (fragments: string[], parameters: Parameter[]): Match | null {
|
|
@@ -27,11 +30,14 @@ export class Route {
|
|
|
27
30
|
|
|
28
31
|
if (segment.fragment === null && segment.placeholder !== null)
|
|
29
32
|
parameters.push({ name: segment.placeholder, value: fragments[i] })
|
|
33
|
+
|
|
34
|
+
if (segment.fragment === null && segment.wildcard === true)
|
|
35
|
+
parameters.push({ name: '**', value: fragments.slice(this.segments.length - 1).join('/') })
|
|
30
36
|
}
|
|
31
37
|
|
|
32
38
|
const exact = this.segments.length === fragments.length
|
|
33
39
|
|
|
34
|
-
if (exact && !this.node.intermediate)
|
|
40
|
+
if ((exact && !this.node.intermediate) || this.wildcard)
|
|
35
41
|
return { node: this.node, parameters }
|
|
36
42
|
else
|
|
37
43
|
return this.matchNested(fragments, parameters)
|
package/source/RTD/segment.ts
CHANGED
|
@@ -15,6 +15,7 @@ export function fragment (path: string): string[] {
|
|
|
15
15
|
function parse (segment: string): Segment {
|
|
16
16
|
if (segment[0] === ':') return { fragment: null, placeholder: segment.substring(1) }
|
|
17
17
|
else if (segment === '*') return { fragment: null, placeholder: null }
|
|
18
|
+
else if (segment === '**') return { fragment: null, placeholder: null, wildcard: true }
|
|
18
19
|
else return { fragment: segment }
|
|
19
20
|
}
|
|
20
21
|
|
|
@@ -23,4 +24,5 @@ export type Segment = {
|
|
|
23
24
|
} | {
|
|
24
25
|
fragment: null
|
|
25
26
|
placeholder: string | null
|
|
27
|
+
wildcard?: boolean
|
|
26
28
|
}
|
|
@@ -6,6 +6,7 @@ export declare class Route {
|
|
|
6
6
|
readonly variables: number;
|
|
7
7
|
readonly segments: Segment[];
|
|
8
8
|
private readonly node;
|
|
9
|
+
private readonly wildcard;
|
|
9
10
|
constructor(segments: Segment[], node: Node);
|
|
10
11
|
match(fragments: string[], parameters: Parameter[]): Match | null;
|
|
11
12
|
equals(route: Route): boolean;
|
package/transpiled/RTD/Route.js
CHANGED
|
@@ -6,13 +6,16 @@ class Route {
|
|
|
6
6
|
variables = 0;
|
|
7
7
|
segments;
|
|
8
8
|
node;
|
|
9
|
+
wildcard = false;
|
|
9
10
|
constructor(segments, node) {
|
|
10
11
|
this.root = segments.length === 0;
|
|
11
12
|
this.segments = segments;
|
|
12
13
|
this.node = node;
|
|
13
14
|
for (const segment of segments)
|
|
14
|
-
if (segment.fragment === null)
|
|
15
|
+
if (segment.fragment === null) {
|
|
15
16
|
this.variables++;
|
|
17
|
+
this.wildcard ||= segment.wildcard === true;
|
|
18
|
+
}
|
|
16
19
|
}
|
|
17
20
|
match(fragments, parameters) {
|
|
18
21
|
for (let i = 0; i < this.segments.length; i++) {
|
|
@@ -21,9 +24,11 @@ class Route {
|
|
|
21
24
|
return null;
|
|
22
25
|
if (segment.fragment === null && segment.placeholder !== null)
|
|
23
26
|
parameters.push({ name: segment.placeholder, value: fragments[i] });
|
|
27
|
+
if (segment.fragment === null && segment.wildcard === true)
|
|
28
|
+
parameters.push({ name: '**', value: fragments.slice(this.segments.length - 1).join('/') });
|
|
24
29
|
}
|
|
25
30
|
const exact = this.segments.length === fragments.length;
|
|
26
|
-
if (exact && !this.node.intermediate)
|
|
31
|
+
if ((exact && !this.node.intermediate) || this.wildcard)
|
|
27
32
|
return { node: this.node, parameters };
|
|
28
33
|
else
|
|
29
34
|
return this.matchNested(fragments, parameters);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Route.js","sourceRoot":"","sources":["../../source/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EO,WAAW,CAAE,SAAmB,EAAE,UAAuB;QAC/D,SAAS,GAAG,SAAS,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAA;QAEjD,OAAO,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,SAAS,EAAE,UAAU,CAAC,CAAA;IAC/C,CAAC;CACF;AA7DD,sBA6DC"}
|
|
@@ -19,6 +19,8 @@ function parse(segment) {
|
|
|
19
19
|
return { fragment: null, placeholder: segment.substring(1) };
|
|
20
20
|
else if (segment === '*')
|
|
21
21
|
return { fragment: null, placeholder: null };
|
|
22
|
+
else if (segment === '**')
|
|
23
|
+
return { fragment: null, placeholder: null, wildcard: true };
|
|
22
24
|
else
|
|
23
25
|
return { fragment: segment };
|
|
24
26
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"segment.js","sourceRoot":"","sources":["../../source/RTD/segment.ts"],"names":[],"mappings":";;;AAAA,SAAgB,OAAO,CAAE,IAAY;IACnC,OAAO,QAAQ,CAAC,IAAI,CAAC,CAAC,GAAG,CAAC,KAAK,CAAC,CAAA;AAClC,CAAC;AAFD,0BAEC;AAED,SAAgB,QAAQ,CAAE,IAAY;IACpC,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAA;IAE7B,iBAAiB;IACjB,IAAI,KAAK,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,KAAK,EAAE;QAAE,KAAK,CAAC,MAAM,EAAE,CAAA;IAElD,gBAAgB;IAChB,OAAO,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,CAAA;AACxB,CAAC;AARD,4BAQC;AAED,SAAS,KAAK,CAAE,OAAe;IAC7B,IAAI,OAAO,CAAC,CAAC,CAAC,KAAK,GAAG;QAAE,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,CAAA;SAC/E,IAAI,OAAO,KAAK,GAAG;QAAE,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,IAAI,EAAE,CAAA;;
|
|
1
|
+
{"version":3,"file":"segment.js","sourceRoot":"","sources":["../../source/RTD/segment.ts"],"names":[],"mappings":";;;AAAA,SAAgB,OAAO,CAAE,IAAY;IACnC,OAAO,QAAQ,CAAC,IAAI,CAAC,CAAC,GAAG,CAAC,KAAK,CAAC,CAAA;AAClC,CAAC;AAFD,0BAEC;AAED,SAAgB,QAAQ,CAAE,IAAY;IACpC,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAA;IAE7B,iBAAiB;IACjB,IAAI,KAAK,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,KAAK,EAAE;QAAE,KAAK,CAAC,MAAM,EAAE,CAAA;IAElD,gBAAgB;IAChB,OAAO,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,CAAA;AACxB,CAAC;AARD,4BAQC;AAED,SAAS,KAAK,CAAE,OAAe;IAC7B,IAAI,OAAO,CAAC,CAAC,CAAC,KAAK,GAAG;QAAE,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,CAAA;SAC/E,IAAI,OAAO,KAAK,GAAG;QAAE,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,IAAI,EAAE,CAAA;SACjE,IAAI,OAAO,KAAK,IAAI;QAAE,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAA;;QAClF,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,CAAA;AACnC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Incept.js","sourceRoot":"","sources":["../../../source/directives/auth/Incept.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;A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