@things-factory/auth-azure-ad 6.1.176 → 6.1.178
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/client/bootstrap.ts +1 -8
- package/client/index.ts +0 -1
- package/client/route.ts +0 -3
- package/config/config.development.js +14 -13
- package/config/config.production.js +14 -13
- package/dist-client/bootstrap.js +1 -7
- package/dist-client/bootstrap.js.map +1 -1
- package/dist-client/index.d.ts +0 -1
- package/dist-client/index.js +1 -1
- package/dist-client/index.js.map +1 -1
- package/dist-client/route.d.ts +1 -1
- package/dist-client/route.js +0 -3
- package/dist-client/route.js.map +1 -1
- package/dist-client/tsconfig.tsbuildinfo +1 -1
- package/dist-server/controllers/get-access-token.js +31 -0
- package/dist-server/controllers/get-access-token.js.map +1 -0
- package/dist-server/controllers/subscribe-users-change.js +34 -0
- package/dist-server/controllers/subscribe-users-change.js.map +1 -0
- package/dist-server/controllers/sync-user-info.js +78 -0
- package/dist-server/controllers/sync-user-info.js.map +1 -0
- package/dist-server/index.js +1 -0
- package/dist-server/index.js.map +1 -1
- package/dist-server/router/auth-azure-ad-router.js +0 -14
- package/dist-server/router/auth-azure-ad-router.js.map +1 -1
- package/dist-server/router/auth-azure-ad-webhook-router.js +62 -0
- package/dist-server/router/auth-azure-ad-webhook-router.js.map +1 -0
- package/dist-server/router/index.js +1 -0
- package/dist-server/router/index.js.map +1 -1
- package/dist-server/routes.js +1 -0
- package/dist-server/routes.js.map +1 -1
- package/dist-server/service/auth-azure-ad/auth-azure-ad-mutation.js +39 -0
- package/dist-server/service/auth-azure-ad/auth-azure-ad-mutation.js.map +1 -0
- package/dist-server/service/auth-azure-ad/index.js +6 -0
- package/dist-server/service/auth-azure-ad/index.js.map +1 -0
- package/dist-server/service/index.js +19 -0
- package/dist-server/service/index.js.map +1 -0
- package/dist-server/tsconfig.tsbuildinfo +1 -1
- package/helps/auth-azure-ad/auth-azure-ad.md +160 -0
- package/package.json +4 -4
- package/server/controllers/get-access-token.ts +29 -0
- package/server/controllers/subscribe-users-change.ts +34 -0
- package/server/controllers/sync-user-info.ts +100 -0
- package/server/index.ts +1 -0
- package/server/router/auth-azure-ad-router.ts +0 -19
- package/server/router/auth-azure-ad-webhook-router.ts +82 -0
- package/server/router/index.ts +1 -0
- package/server/routes.ts +2 -1
- package/server/service/auth-azure-ad/auth-azure-ad-mutation.ts +24 -0
- package/server/service/auth-azure-ad/index.ts +3 -0
- package/server/service/index.ts +19 -0
- package/things-factory.config.js +5 -7
- package/client/actions/main.ts +0 -1
- package/client/pages/main.ts +0 -21
- package/client/reducers/main.ts +0 -17
- package/dist-client/actions/main.d.ts +0 -1
- package/dist-client/actions/main.js +0 -2
- package/dist-client/actions/main.js.map +0 -1
- package/dist-client/pages/main.d.ts +0 -1
- package/dist-client/pages/main.js +0 -25
- package/dist-client/pages/main.js.map +0 -1
- package/dist-client/reducers/main.d.ts +0 -6
- package/dist-client/reducers/main.js +0 -14
- package/dist-client/reducers/main.js.map +0 -1
package/client/bootstrap.ts
CHANGED
package/client/index.ts
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './actions/main'
|
package/client/route.ts
CHANGED
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
module.exports = {
|
|
2
|
-
SSOAzureAD: {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
}
|
|
2
|
+
// SSOAzureAD: {
|
|
3
|
+
// tenantID: 'your_tenant_id',
|
|
4
|
+
// clientID: 'your_client_id',
|
|
5
|
+
// clientSecret: 'your_client_secret',
|
|
6
|
+
// identityMetadata: 'https://login.microsoftonline.com/your_tenant_id/v2.0/.well-known/openid-configuration',
|
|
7
|
+
// responseType: 'code id_token',
|
|
8
|
+
// responseMode: 'form_post',
|
|
9
|
+
// redirectUrl: 'http://localhost:3000/auth/openid/return',
|
|
10
|
+
// allowHttpForRedirectUrl: true,
|
|
11
|
+
// validateIssuer: false,
|
|
12
|
+
// passReqToCallback: false
|
|
13
|
+
// // useCookieInsteadOfSession: true,
|
|
14
|
+
// // cookieEncryptionKeys: [{ key: 'your_cookie_encryption_key', iv: 'your_cookie_encryption_iv' }]
|
|
15
|
+
// }
|
|
15
16
|
}
|
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
module.exports = {
|
|
2
|
-
SSOAzureAD: {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
}
|
|
2
|
+
// SSOAzureAD: {
|
|
3
|
+
// tenantID: 'your_tenant_id',
|
|
4
|
+
// clientID: 'your_client_id',
|
|
5
|
+
// clientSecret: 'your_client_secret',
|
|
6
|
+
// identityMetadata: 'https://login.microsoftonline.com/your_tenant_id/v2.0/.well-known/openid-configuration',
|
|
7
|
+
// responseType: 'code id_token',
|
|
8
|
+
// responseMode: 'form_post',
|
|
9
|
+
// redirectUrl: 'http://localhost:3000/auth/openid/return',
|
|
10
|
+
// allowHttpForRedirectUrl: true,
|
|
11
|
+
// validateIssuer: false,
|
|
12
|
+
// passReqToCallback: false
|
|
13
|
+
// // useCookieInsteadOfSession: true,
|
|
14
|
+
// // cookieEncryptionKeys: [{ key: 'your_cookie_encryption_key', iv: 'your_cookie_encryption_iv' }]
|
|
15
|
+
// }
|
|
15
16
|
}
|
package/dist-client/bootstrap.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bootstrap.js","sourceRoot":"","sources":["../client/bootstrap.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"bootstrap.js","sourceRoot":"","sources":["../client/bootstrap.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,OAAO,UAAU,SAAS,KAAI,CAAC","sourcesContent":["export default function bootstrap() {}\n"]}
|
package/dist-client/index.d.ts
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './actions/main';
|
package/dist-client/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
package/dist-client/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../client/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../client/index.ts"],"names":[],"mappings":"","sourcesContent":[""]}
|
package/dist-client/route.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export default function route(page: string):
|
|
1
|
+
export default function route(page: string): void;
|
package/dist-client/route.js
CHANGED
package/dist-client/route.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"route.js","sourceRoot":"","sources":["../client/route.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,OAAO,UAAU,KAAK,CAAC,IAAY;IACxC,QAAQ,IAAI,EAAE;
|
|
1
|
+
{"version":3,"file":"route.js","sourceRoot":"","sources":["../client/route.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,OAAO,UAAU,KAAK,CAAC,IAAY;IACxC,QAAQ,IAAI,EAAE;KACb;AACH,CAAC","sourcesContent":["export default function route(page: string) {\n switch (page) {\n }\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"program":{"fileNames":["../../../node_modules/lerna/node_modules/typescript/lib/lib.es5.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2016.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2017.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2018.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2019.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.dom.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.dom.iterable.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.core.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2017.object.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2017.string.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2019.array.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2019.object.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2019.string.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2019.symbol.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2019.intl.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.date.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.promise.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.string.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.intl.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.number.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.esnext.intl.d.ts","../../../node_modules/tslib/tslib.d.ts","../../../node_modules/@operato/shell/dist/src/types/domain.d.ts","../../../node_modules/@operato/shell/dist/src/types/user.d.ts","../../../node_modules/@operato/shell/dist/src/types/role.d.ts","../../../node_modules/@operato/shell/dist/src/types/privilege.d.ts","../../../node_modules/@operato/shell/dist/src/types/types.d.ts","../../../node_modules/@operato/shell/dist/src/types/index.d.ts","../../../node_modules/redux/index.d.ts","../../../node_modules/pwa-helpers/lazy-reducer-enhancer.d.ts","../../../node_modules/@operato/shell/dist/src/store.d.ts","../../../node_modules/@operato/shell/dist/src/actions/app.d.ts","../../../node_modules/@operato/shell/dist/src/actions/route.d.ts","../../../node_modules/@operato/shell/dist/src/actions/busy.d.ts","../../../node_modules/@operato/shell/dist/src/actions/const.d.ts","../../../node_modules/@operato/shell/dist/src/actions/index.d.ts","../../../node_modules/@lit/reactive-element/css-tag.d.ts","../../../node_modules/@lit/reactive-element/reactive-controller.d.ts","../../../node_modules/@lit/reactive-element/reactive-element.d.ts","../../../node_modules/@types/trusted-types/lib/index.d.ts","../../../node_modules/@types/trusted-types/index.d.ts","../../../node_modules/lit-html/directive.d.ts","../../../node_modules/lit-html/lit-html.d.ts","../../../node_modules/lit-element/lit-element.d.ts","../../../node_modules/lit-html/is-server.d.ts","../../../node_modules/lit/index.d.ts","../../../node_modules/@operato/shell/dist/src/app/pages/page-view.d.ts","../../../node_modules/@operato/shell/dist/src/object-store.d.ts","../../../node_modules/@operato/shell/dist/src/index.d.ts","../client/actions/main.ts","../client/reducers/main.ts","../client/bootstrap.ts","../client/index.ts","../../../node_modules/@lit/reactive-element/decorators/base.d.ts","../../../node_modules/@lit/reactive-element/decorators/custom-element.d.ts","../../../node_modules/@lit/reactive-element/decorators/property.d.ts","../../../node_modules/@lit/reactive-element/decorators/state.d.ts","../../../node_modules/@lit/reactive-element/decorators/event-options.d.ts","../../../node_modules/@lit/reactive-element/decorators/query.d.ts","../../../node_modules/@lit/reactive-element/decorators/query-all.d.ts","../../../node_modules/@lit/reactive-element/decorators/query-async.d.ts","../../../node_modules/@lit/reactive-element/decorators/query-assigned-nodes.d.ts","../../../node_modules/@lit/reactive-element/decorators/query-assigned-elements.d.ts","../../../node_modules/lit/decorators.d.ts","../../../node_modules/pwa-helpers/connect-mixin.d.ts","../client/pages/main.ts","../client/route.ts","../../../node_modules/@types/node/assert.d.ts","../../../node_modules/@types/node/assert/strict.d.ts","../../../node_modules/@types/node/globals.d.ts","../../../node_modules/@types/node/async_hooks.d.ts","../../../node_modules/@types/node/buffer.d.ts","../../../node_modules/@types/node/child_process.d.ts","../../../node_modules/@types/node/cluster.d.ts","../../../node_modules/@types/node/console.d.ts","../../../node_modules/@types/node/constants.d.ts","../../../node_modules/@types/node/crypto.d.ts","../../../node_modules/@types/node/dgram.d.ts","../../../node_modules/@types/node/diagnostics_channel.d.ts","../../../node_modules/@types/node/dns.d.ts","../../../node_modules/@types/node/dns/promises.d.ts","../../../node_modules/@types/node/domain.d.ts","../../../node_modules/@types/node/dom-events.d.ts","../../../node_modules/@types/node/events.d.ts","../../../node_modules/@types/node/fs.d.ts","../../../node_modules/@types/node/fs/promises.d.ts","../../../node_modules/@types/node/http.d.ts","../../../node_modules/@types/node/http2.d.ts","../../../node_modules/@types/node/https.d.ts","../../../node_modules/@types/node/inspector.d.ts","../../../node_modules/@types/node/module.d.ts","../../../node_modules/@types/node/net.d.ts","../../../node_modules/@types/node/os.d.ts","../../../node_modules/@types/node/path.d.ts","../../../node_modules/@types/node/perf_hooks.d.ts","../../../node_modules/@types/node/process.d.ts","../../../node_modules/@types/node/punycode.d.ts","../../../node_modules/@types/node/querystring.d.ts","../../../node_modules/@types/node/readline.d.ts","../../../node_modules/@types/node/readline/promises.d.ts","../../../node_modules/@types/node/repl.d.ts","../../../node_modules/@types/node/stream.d.ts","../../../node_modules/@types/node/stream/promises.d.ts","../../../node_modules/@types/node/stream/consumers.d.ts","../../../node_modules/@types/node/stream/web.d.ts","../../../node_modules/@types/node/string_decoder.d.ts","../../../node_modules/@types/node/test.d.ts","../../../node_modules/@types/node/timers.d.ts","../../../node_modules/@types/node/timers/promises.d.ts","../../../node_modules/@types/node/tls.d.ts","../../../node_modules/@types/node/trace_events.d.ts","../../../node_modules/@types/node/tty.d.ts","../../../node_modules/@types/node/url.d.ts","../../../node_modules/@types/node/util.d.ts","../../../node_modules/@types/node/v8.d.ts","../../../node_modules/@types/node/vm.d.ts","../../../node_modules/@types/node/wasi.d.ts","../../../node_modules/@types/node/worker_threads.d.ts","../../../node_modules/@types/node/zlib.d.ts","../../../node_modules/@types/node/globals.global.d.ts","../../../node_modules/@types/node/index.d.ts","../../../node_modules/@jest/expect-utils/build/index.d.ts","../../../node_modules/chalk/index.d.ts","../../../node_modules/@sinclair/typebox/typebox.d.ts","../../../node_modules/@jest/schemas/build/index.d.ts","../../../node_modules/pretty-format/build/index.d.ts","../../../node_modules/jest-diff/build/index.d.ts","../../../node_modules/jest-matcher-utils/build/index.d.ts","../../../node_modules/expect/build/index.d.ts","../../../node_modules/@types/jest/index.d.ts"],"fileInfos":[{"version":"8730f4bf322026ff5229336391a18bcaa1f94d4f82416c8b2f3954e2ccaae2ba","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06","4b421cbfb3a38a27c279dec1e9112c3d1da296f77a1a85ddadf7e7a425d45d18","1fc5ab7a764205c68fa10d381b08417795fc73111d6dd16b5b1ed36badb743d9",{"version":"3aafcb693fe5b5c3bd277bd4c3a617b53db474fe498fc5df067c5603b1eebde7","affectsGlobalScope":true},{"version":"f3d4da15233e593eacb3965cde7960f3fddf5878528d882bcedd5cbaba0193c7","affectsGlobalScope":true},{"version":"adb996790133eb33b33aadb9c09f15c2c575e71fb57a62de8bf74dbf59ec7dfb","affectsGlobalScope":true},{"version":"8cc8c5a3bac513368b0157f3d8b31cfdcfe78b56d3724f30f80ed9715e404af8","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"c5c05907c02476e4bde6b7e76a79ffcd948aedd14b6a8f56e4674221b0417398","affectsGlobalScope":true},{"version":"5f406584aef28a331c36523df688ca3650288d14f39c5d2e555c95f0d2ff8f6f","affectsGlobalScope":true},{"version":"22f230e544b35349cfb3bd9110b6ef37b41c6d6c43c3314a31bd0d9652fcec72","affectsGlobalScope":true},{"version":"7ea0b55f6b315cf9ac2ad622b0a7813315bb6e97bf4bb3fbf8f8affbca7dc695","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"eb26de841c52236d8222f87e9e6a235332e0788af8c87a71e9e210314300410a","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"81cac4cbc92c0c839c70f8ffb94eb61e2d32dc1c3cf6d95844ca099463cf37ea","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"d154ea5bb7f7f9001ed9153e876b2d5b8f5c2bb9ec02b3ae0d239ec769f1f2ae","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"9d57b2b5d15838ed094aa9ff1299eecef40b190722eb619bac4616657a05f951","affectsGlobalScope":true},{"version":"6c51b5dd26a2c31dbf37f00cfc32b2aa6a92e19c995aefb5b97a3a64f1ac99de","affectsGlobalScope":true},{"version":"6e7997ef61de3132e4d4b2250e75343f487903ddf5370e7ce33cf1b9db9a63ed","affectsGlobalScope":true},{"version":"2ad234885a4240522efccd77de6c7d99eecf9b4de0914adb9a35c0c22433f993","affectsGlobalScope":true},{"version":"5e5e095c4470c8bab227dbbc61374878ecead104c74ab9960d3adcccfee23205","affectsGlobalScope":true},{"version":"09aa50414b80c023553090e2f53827f007a301bc34b0495bfb2c3c08ab9ad1eb","affectsGlobalScope":true},{"version":"d7f680a43f8cd12a6b6122c07c54ba40952b0c8aa140dcfcf32eb9e6cb028596","affectsGlobalScope":true},{"version":"3787b83e297de7c315d55d4a7c546ae28e5f6c0a361b7a1dcec1f1f50a54ef11","affectsGlobalScope":true},{"version":"e7e8e1d368290e9295ef18ca23f405cf40d5456fa9f20db6373a61ca45f75f40","affectsGlobalScope":true},{"version":"faf0221ae0465363c842ce6aa8a0cbda5d9296940a8e26c86e04cc4081eea21e","affectsGlobalScope":true},{"version":"06393d13ea207a1bfe08ec8d7be562549c5e2da8983f2ee074e00002629d1871","affectsGlobalScope":true},{"version":"2768ef564cfc0689a1b76106c421a2909bdff0acbe87da010785adab80efdd5c","affectsGlobalScope":true},{"version":"b248e32ca52e8f5571390a4142558ae4f203ae2f94d5bac38a3084d529ef4e58","affectsGlobalScope":true},{"version":"52d1bb7ab7a3306fd0375c8bff560feed26ed676a5b0457fa8027b563aecb9a4","affectsGlobalScope":true},"7a1971efcba559ea9002ada4c4e3c925004fb67a755300d53b5edf9399354900","4d4cf93a6b4c81851ad759e4569b6feb7a701e80b13a6f9d8d9c6012bbb86bd6","2e6035af8f3e43bf95e4983329c8277d66f9b271106af27b99a85d1c1b9daf4a","774308610e8d4a9954cd93840f99decbf340accfe3ad7365547950ede8162c92","36c15dd26c66c97b9df26ce34baacdb13fc760c5b9a2d789dcc317d27b189257","3d7c0b593a29d717b2b2ba3f03f819c3c48bf9e250d79c4a31860af80f177e8c","f228d440342f5d0933f5db093aafab2f07de24a427b4488ccfae27b7457d7666",{"version":"fd624f7d7b264922476685870f08c5e1c6d6a0f05dee2429a9747b41f6b699d4","affectsGlobalScope":true},"701978f3975f96e76e3ffc2e1762e3a97e3d323812049fb6fdfd559579b89708",{"version":"4ab17f80ced148d509345cee706b2b85941515dd76e32cf47118bcdf6a4bd56a","affectsGlobalScope":true},"641089f0b8094ef74b9d4b3364d5dec1592d5e3b8a51c1ba491bc8872049e79a","9197b3ca76c01df6120b4ee288fe2d08f8a2089221da97956bee402de0ffd37e","b42033bf1067564808e4d360d79281667c2b3b0792c2d615ab641eb85974d4ba","7af29b0589483f7bb8a99405ddb849f34bc053146184561ed4179e02f5fe4d0f","78faa3783191b2d5d5f7a9e835ee3f6a1456dc391d6eb5b40d3a27dfd9decd6e","52dd370c807255c61765347fc90a9bee3c522b8744dc222714e2bf6b5be3a823","1e5743b25a63fd34ffbae89adcbf248ee17db6ed08d90079ffa93803c3e80d2a","ccf8ea81b0ac699c220b874b804ad02b8aabc5b494e1c3bda0d255ec8d08694d","15fe687c59d62741b4494d5e623d497d55eb38966ecf5bea7f36e48fc3fbe15e",{"version":"17f2b4d00e42e0cc1dfc3be692a6da5a14a6cb73b87259e6d20ff02bcd6d573f","affectsGlobalScope":true},"c567d37119d6f56381af48eb7516030ccf35a36f9aca045e238d9c207a7c536c","b448dfbb5a6c4505f6b6beab587cf41f180ad62bcb506b44e3f2c09d20ba63a9","eba7cf33380cc3a3cf614faf67300e14d0bdff9ea6c5cd6f4b040b1756a48ab1","5e7e090243bf203382a5cb04eabbdc38d78f6d5922f16f543e4da8fa007d5ff9","cd823094ded7c8ac4f94ab6dc387dab699293eb8323d9f948304efc07e4ae7b2","6bf72b2541469cac7a7882468d25a04fdff489625452ff7d3e670c764e5a9ba1","fc48282c397084016a939e1b3f91dcaf4199b6cba339d91d8b2dc2acade79762","981fc22acc36b6a33c9f5b3d468e975b104cf3409b881ca6cffe84c5f9fda7c1",{"version":"2424eba5303e99238f74784c435fd8d50f03d9d0f3c7d84d656c95f55c4c4ab5","signature":"ba960175f14a79c6138113034a9e443ee24a85aa7258669a97bc7e586964f862"},{"version":"b63da6e9f5a056da29ef25aaec292940ec55b70418cf3ed00a50324c2da987bf","signature":"34562c363f5c0b2d399d24ef78b8d5e1732eafd81fd3d0123cc290900ca9aeb2"},{"version":"972e432c9575c47cd1bee8b5589d1a567cd9dbdf658ddb27ddb86328a6bd8d3d","signature":"aac4ddff3d5c1247433870879e9838b1e23b81a9b62c75f59c3e1b64802f2b16"},{"version":"c7cbdfbcebb4e5ab702361ba74b008091f72d1c177a8ab1d04c9e6865f366750","signature":"3bb52b8cf0f82f57d755cae9943caf7fb107719348612ee55ea395f6c599dfa1"},"d45c02bf8b85203f35de2971eafb8f8092090d150c7805a189b3e197f53b12b6","ac388c7c7a262213a3700451bc921e382a93fb27c0252c34ccf03540b4ce044b","097a7e3badfd1c4b35f72aa0f722f5714a4f6a84e53fca5a79dcfebbfc5e718d","fb0107c83e2e0e75b77dacd0c3c6c3ab6844e98dce2a8f858c6f0a57c12136a6","ea410c8280b0ec480acb195c7dd36c1f054403f5fccee0beca85717777cf8562","628bceb593b3a5b3d73ff44a808a347ec07d6ee397104a1d88b0f9a20d8b4599","57e25505a5de058216a8f4416ca850788bfc3a412c8e90109b2ef91f75fdd615","2ba453918c1fcf1cbb2836f731534f356d5fe65ed9628811f686e8de3920ed0e","4bcb813ea56182beaaab1e8274524eb9f1449b0d8e79efc4a0399de09e43f816","cc689acd4eff461c808e01225be6a16d1787e44d451310be5dd556dd7ab08457","f0380f581cb015778c0fe51e95b5b7f6dae237280654558469b2486c1572268a","23c05cc4d97aa608b5ea8badadb4e1b0c4e306ed5d651c5d1760552e91d1ad92",{"version":"27586641ebcf582ce1796d1c87b30a375cd0d7220b4d6195380e3e0875eaf157","signature":"8e609bb71c20b858c77f0e9f90bb1319db8477b13f9f965f1a1e18524bf50881"},{"version":"dfd0643a91faf33fa2de5170a6f2c7bf30926e53665532275db3d834178e6948","signature":"12e50a105b2d989ac7a6f6c2c1e90beb1853ebcc0376221360317d94cd9ce28e"},"09df3b4f1c937f02e7fee2836d4c4d7a63e66db70fd4d4e97126f4542cc21d9d","7394959e5a741b185456e1ef5d64599c36c60a323207450991e7a42e08911419",{"version":"32465ea19404cb188e84cf08c6b1f6b12d739140436402cdbc184a3fd20a7d81","affectsGlobalScope":true},"cce1f5f86974c1e916ec4a8cab6eec9aa8e31e8148845bf07fbaa8e1d97b1a2c",{"version":"45c22e7e615c8bb6e27325339490f6bd83828d843f9f3cf0ce9fd4d81f6cd923","affectsGlobalScope":true},"546ab07e19116d935ad982e76a223275b53bff7771dab94f433b7ab04652936e","7b43160a49cf2c6082da0465876c4a0b164e160b81187caeb0a6ca7a281e85ba",{"version":"aefb5a4a209f756b580eb53ea771cca8aad411603926f307a5e5b8ec6b16dcf6","affectsGlobalScope":true},"a40826e8476694e90da94aa008283a7de50d1dafd37beada623863f1901cb7fb","f5a8b7ec4b798c88679194a8ebc25dcb6f5368e6e5811fcda9fe12b0d445b8db","b86e1a45b29437f3a99bad4147cb9fe2357617e8008c0484568e5bb5138d6e13","b5b719a47968cd61a6f83f437236bb6fe22a39223b6620da81ef89f5d7a78fb7","42c431e7965b641106b5e25ab3283aa4865ca7bb9909610a2abfa6226e4348be","0b7e732af0a9599be28c091d6bd1cb22c856ec0d415d4749c087c3881ca07a56","b7fe70be794e13d1b7940e318b8770cd1fb3eced7707805318a2e3aaac2c3e9e",{"version":"2c71199d1fc83bf17636ad5bf63a945633406b7b94887612bba4ef027c662b3e","affectsGlobalScope":true},{"version":"c65eca1f892b9e5ee97af93963b2bdf813e4be3b599d06dfb681da19df8358b0","affectsGlobalScope":true},"3b4c85eea12187de9929a76792b98406e8778ce575caca8c574f06da82622c54","f788131a39c81e0c9b9e463645dd7132b5bc1beb609b0e31e5c1ceaea378b4df","1ee64912f7961165a3b6e6209fb7a8aced98b578ca1373b9f0ea144edfe17f6c","21894466693f64957b9bd4c80fa3ec7fdfd4efa9d1861e070aca23f10220c9b2","396a8939b5e177542bdf9b5262b4eee85d29851b2d57681fa9d7eae30e225830","ad8848c289c0b633452e58179f46edccd14b5a0fe90ebce411f79ff040b803e0",{"version":"5d4ef3f46c7f9d62f7c964f9f9ccdd293be99fb3dcc66c983f2aea7430e3c7c6","affectsGlobalScope":true},"91f8b5abcdff8f9ecb9656b9852878718416fb7700b2c4fad8331e5b97c080bb","59d8f064f86a4a2be03b33c0efcc9e7a268ad27b22f82dce16899f3364f70ba8","0f05c06ff6196958d76b865ae17245b52d8fe01773626ac3c43214a2458ea7b7",{"version":"f49fb15c4aa06b65b0dce4db4584bfd8a9f74644baef1511b404dc95be34af00","affectsGlobalScope":true},{"version":"d48009cbe8a30a504031cc82e1286f78fed33b7a42abf7602c23b5547b382563","affectsGlobalScope":true},"7aaeb5e62f90e1b2be0fc4844df78cdb1be15c22b427bc6c39d57308785b8f10","3ba30205a029ebc0c91d7b1ab4da73f6277d730ca1fc6692d5a9144c6772c76b","d8dba11dc34d50cb4202de5effa9a1b296d7a2f4a029eec871f894bddfb6430d","8b71dd18e7e63b6f991b511a201fad7c3bf8d1e0dd98acb5e3d844f335a73634","01d8e1419c84affad359cc240b2b551fb9812b450b4d3d456b64cda8102d4f60","458b216959c231df388a5de9dcbcafd4b4ca563bc3784d706d0455467d7d4942","269929a24b2816343a178008ac9ae9248304d92a8ba8e233055e0ed6dbe6ef71","93452d394fdd1dc551ec62f5042366f011a00d342d36d50793b3529bfc9bd633","f8c87b19eae111f8720b0345ab301af8d81add39621b63614dfc2d15fd6f140a","831c22d257717bf2cbb03afe9c4bcffc5ccb8a2074344d4238bf16d3a857bb12",{"version":"786dd9ad95e335a5e76759d078940fdb5001b74498a31f90fad98afe196a84ca","affectsGlobalScope":true},{"version":"cbf046714f3a3ba2544957e1973ac94aa819fa8aa668846fa8de47eb1c41b0b2","affectsGlobalScope":true},"aa34c3aa493d1c699601027c441b9664547c3024f9dbab1639df7701d63d18fa","eae74e3d50820f37c72c0679fed959cd1e63c98f6a146a55b8c4361582fa6a52","7c651f8dce91a927ab62925e73f190763574c46098f2b11fb8ddc1b147a6709a","7440ab60f4cb031812940cc38166b8bb6fbf2540cfe599f87c41c08011f0c1df",{"version":"aed89e3c18f4c659ee8153a76560dffda23e2d801e1e60d7a67abd84bc555f8d","affectsGlobalScope":true},{"version":"0ed13c80faeb2b7160bffb4926ff299c468e67a37a645b3ae0917ba0db633c1b","affectsGlobalScope":true},"e393915d3dc385e69c0e2390739c87b2d296a610662eb0b1cb85224e55992250","2f940651c2f30e6b29f8743fae3f40b7b1c03615184f837132b56ea75edad08b","5749c327c3f789f658072f8340786966c8b05ea124a56c1d8d60e04649495a4d",{"version":"c9d62b2a51b2ff166314d8be84f6881a7fcbccd37612442cf1c70d27d5352f50","affectsGlobalScope":true},"e7dbf5716d76846c7522e910896c5747b6df1abd538fee8f5291bdc843461795",{"version":"ab9b9a36e5284fd8d3bf2f7d5fcbc60052f25f27e4d20954782099282c60d23e","affectsGlobalScope":true},"d3f4c342fb62f348f25f54b473b0ab7371828cbf637134194fa9cdf04856f87b","cdcc132f207d097d7d3aa75615ab9a2e71d6a478162dde8b67f88ea19f3e54de","0d14fa22c41fdc7277e6f71473b20ebc07f40f00e38875142335d5b63cdfc9d2","c085e9aa62d1ae1375794c1fb927a445fa105fed891a7e24edbb1c3300f7384a","f315e1e65a1f80992f0509e84e4ae2df15ecd9ef73df975f7c98813b71e4c8da","5b9586e9b0b6322e5bfbd2c29bd3b8e21ab9d871f82346cb71020e3d84bae73e","3e70a7e67c2cb16f8cd49097360c0309fe9d1e3210ff9222e9dac1f8df9d4fb6","ab68d2a3e3e8767c3fba8f80de099a1cfc18c0de79e42cb02ae66e22dfe14a66","d96cc6598148bf1a98fb2e8dcf01c63a4b3558bdaec6ef35e087fd0562eb40ec",{"version":"c8950367d1812758e9e354c695c60c3e6311bf2cd98b9f9eb469a19df8a9a486","affectsGlobalScope":true}],"options":{"allowSyntheticDefaultImports":true,"declaration":true,"emitDecoratorMetadata":true,"esModuleInterop":true,"experimentalDecorators":true,"importHelpers":true,"inlineSources":true,"module":99,"noEmitOnError":true,"noImplicitAny":false,"outDir":"./","skipLibCheck":true,"sourceMap":true,"strict":true,"target":4,"useDefineForClassFields":false},"fileIdsList":[[136],[136,146],[61,136],[76,136],[61,76,136],[61,76,84,136],[59,60,136],[54,55,56,57,136],[68,136],[50,53,58,69,70,136],[51,52,136],[45,46,47,48,49,136],[46,47,136],[45,46,48,136],[136,148,151],[90,136],[93,136],[94,99,127,136],[95,106,107,114,124,135,136],[95,96,106,114,136],[97,136],[98,99,107,115,136],[99,124,132,136],[100,102,106,114,136],[101,136],[102,103,136],[106,136],[104,106,136],[93,106,136],[106,107,108,124,135,136],[106,107,108,121,124,127,136],[136,140],[102,106,109,114,124,135,136],[106,107,109,110,114,124,132,135,136],[109,111,124,132,135,136],[90,91,92,93,94,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142],[106,112,136],[113,135,136,140],[102,106,114,124,136],[115,136],[116,136],[93,117,136],[118,134,136,140],[119,136],[120,136],[106,121,122,136],[121,123,136,138],[94,106,124,125,126,127,136],[94,124,126,136],[124,125,136],[127,136],[128,136],[93,124,136],[106,130,131,136],[130,131,136],[99,114,124,132,136],[133,136],[114,134,136],[94,109,120,135,136],[99,136],[124,136,137],[113,136,138],[136,139],[94,99,106,108,117,124,135,136,138,140],[124,136,141],[62,136],[136,144,150],[136,148],[136,145,149],[61,65,136],[65,136],[63,64,136],[77,78,79,80,81,82,83,84,85,136],[61,65,66,67,136],[136,147],[51,136],[44,136],[44,71,73,136],[44,72,136],[44,68,71,86,87,136],[44,88,136],[72]],"referencedMap":[[144,1],[147,2],[59,1],[76,3],[77,4],[80,5],[78,5],[82,5],[85,6],[84,1],[83,5],[81,5],[79,4],[60,1],[61,7],[54,1],[56,1],[57,1],[58,8],[55,1],[69,9],[71,10],[70,1],[53,11],[45,1],[50,12],[48,13],[47,14],[49,1],[46,1],[146,1],[152,15],[90,16],[91,16],[93,17],[94,18],[95,19],[96,20],[97,21],[98,22],[99,23],[100,24],[101,25],[102,26],[103,26],[105,27],[104,28],[106,29],[107,30],[108,31],[92,32],[142,1],[109,33],[110,34],[111,35],[143,36],[112,37],[113,38],[114,39],[115,40],[116,41],[117,42],[118,43],[119,44],[120,45],[121,46],[122,46],[123,47],[124,48],[126,49],[125,50],[127,51],[128,52],[129,53],[130,54],[131,55],[132,56],[133,57],[134,58],[135,59],[136,60],[137,61],[138,62],[139,63],[140,64],[141,65],[63,66],[62,1],[145,1],[151,67],[149,68],[150,69],[8,1],[9,1],[11,1],[10,1],[2,1],[12,1],[13,1],[14,1],[15,1],[16,1],[17,1],[18,1],[19,1],[3,1],[4,1],[23,1],[20,1],[21,1],[22,1],[24,1],[25,1],[26,1],[5,1],[27,1],[28,1],[29,1],[30,1],[6,1],[34,1],[31,1],[32,1],[33,1],[35,1],[7,1],[36,1],[41,1],[42,1],[37,1],[38,1],[39,1],[40,1],[1,1],[43,1],[66,70],[64,71],[67,1],[65,72],[86,73],[68,74],[148,75],[87,76],[52,76],[51,1],[44,1],[72,77],[74,78],[75,79],[88,80],[73,79],[89,81]],"exportedModulesMap":[[144,1],[147,2],[59,1],[76,3],[77,4],[80,5],[78,5],[82,5],[85,6],[84,1],[83,5],[81,5],[79,4],[60,1],[61,7],[54,1],[56,1],[57,1],[58,8],[55,1],[69,9],[71,10],[70,1],[53,11],[45,1],[50,12],[48,13],[47,14],[49,1],[46,1],[146,1],[152,15],[90,16],[91,16],[93,17],[94,18],[95,19],[96,20],[97,21],[98,22],[99,23],[100,24],[101,25],[102,26],[103,26],[105,27],[104,28],[106,29],[107,30],[108,31],[92,32],[142,1],[109,33],[110,34],[111,35],[143,36],[112,37],[113,38],[114,39],[115,40],[116,41],[117,42],[118,43],[119,44],[120,45],[121,46],[122,46],[123,47],[124,48],[126,49],[125,50],[127,51],[128,52],[129,53],[130,54],[131,55],[132,56],[133,57],[134,58],[135,59],[136,60],[137,61],[138,62],[139,63],[140,64],[141,65],[63,66],[62,1],[145,1],[151,67],[149,68],[150,69],[8,1],[9,1],[11,1],[10,1],[2,1],[12,1],[13,1],[14,1],[15,1],[16,1],[17,1],[18,1],[19,1],[3,1],[4,1],[23,1],[20,1],[21,1],[22,1],[24,1],[25,1],[26,1],[5,1],[27,1],[28,1],[29,1],[30,1],[6,1],[34,1],[31,1],[32,1],[33,1],[35,1],[7,1],[36,1],[41,1],[42,1],[37,1],[38,1],[39,1],[40,1],[1,1],[43,1],[66,70],[64,71],[67,1],[65,72],[86,73],[68,74],[148,75],[87,76],[52,76],[51,1],[44,1],[75,82]],"semanticDiagnosticsPerFile":[144,147,59,76,77,80,78,82,85,84,83,81,79,60,61,54,56,57,58,55,69,71,70,53,45,50,48,47,49,46,146,152,90,91,93,94,95,96,97,98,99,100,101,102,103,105,104,106,107,108,92,142,109,110,111,143,112,113,114,115,116,117,118,119,120,121,122,123,124,126,125,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,63,62,145,151,149,150,8,9,11,10,2,12,13,14,15,16,17,18,19,3,4,23,20,21,22,24,25,26,5,27,28,29,30,6,34,31,32,33,35,7,36,41,42,37,38,39,40,1,43,66,64,67,65,86,68,148,87,52,51,44,72,74,75,88,73,89]},"version":"4.9.5"}
|
|
1
|
+
{"program":{"fileNames":["../../../node_modules/lerna/node_modules/typescript/lib/lib.es5.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2016.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2017.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2018.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2019.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.dom.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.dom.iterable.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.core.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2017.object.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2017.string.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2019.array.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2019.object.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2019.string.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2019.symbol.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2019.intl.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.date.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.promise.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.string.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.intl.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.es2020.number.d.ts","../../../node_modules/lerna/node_modules/typescript/lib/lib.esnext.intl.d.ts","../../../node_modules/tslib/tslib.d.ts","../client/bootstrap.ts","../client/index.ts","../client/route.ts","../../../node_modules/@types/node/assert.d.ts","../../../node_modules/@types/node/assert/strict.d.ts","../../../node_modules/@types/node/globals.d.ts","../../../node_modules/@types/node/async_hooks.d.ts","../../../node_modules/@types/node/buffer.d.ts","../../../node_modules/@types/node/child_process.d.ts","../../../node_modules/@types/node/cluster.d.ts","../../../node_modules/@types/node/console.d.ts","../../../node_modules/@types/node/constants.d.ts","../../../node_modules/@types/node/crypto.d.ts","../../../node_modules/@types/node/dgram.d.ts","../../../node_modules/@types/node/diagnostics_channel.d.ts","../../../node_modules/@types/node/dns.d.ts","../../../node_modules/@types/node/dns/promises.d.ts","../../../node_modules/@types/node/domain.d.ts","../../../node_modules/@types/node/dom-events.d.ts","../../../node_modules/@types/node/events.d.ts","../../../node_modules/@types/node/fs.d.ts","../../../node_modules/@types/node/fs/promises.d.ts","../../../node_modules/@types/node/http.d.ts","../../../node_modules/@types/node/http2.d.ts","../../../node_modules/@types/node/https.d.ts","../../../node_modules/@types/node/inspector.d.ts","../../../node_modules/@types/node/module.d.ts","../../../node_modules/@types/node/net.d.ts","../../../node_modules/@types/node/os.d.ts","../../../node_modules/@types/node/path.d.ts","../../../node_modules/@types/node/perf_hooks.d.ts","../../../node_modules/@types/node/process.d.ts","../../../node_modules/@types/node/punycode.d.ts","../../../node_modules/@types/node/querystring.d.ts","../../../node_modules/@types/node/readline.d.ts","../../../node_modules/@types/node/readline/promises.d.ts","../../../node_modules/@types/node/repl.d.ts","../../../node_modules/@types/node/stream.d.ts","../../../node_modules/@types/node/stream/promises.d.ts","../../../node_modules/@types/node/stream/consumers.d.ts","../../../node_modules/@types/node/stream/web.d.ts","../../../node_modules/@types/node/string_decoder.d.ts","../../../node_modules/@types/node/test.d.ts","../../../node_modules/@types/node/timers.d.ts","../../../node_modules/@types/node/timers/promises.d.ts","../../../node_modules/@types/node/tls.d.ts","../../../node_modules/@types/node/trace_events.d.ts","../../../node_modules/@types/node/tty.d.ts","../../../node_modules/@types/node/url.d.ts","../../../node_modules/@types/node/util.d.ts","../../../node_modules/@types/node/v8.d.ts","../../../node_modules/@types/node/vm.d.ts","../../../node_modules/@types/node/wasi.d.ts","../../../node_modules/@types/node/worker_threads.d.ts","../../../node_modules/@types/node/zlib.d.ts","../../../node_modules/@types/node/globals.global.d.ts","../../../node_modules/@types/node/index.d.ts","../../../node_modules/@jest/expect-utils/build/index.d.ts","../../../node_modules/chalk/index.d.ts","../../../node_modules/@sinclair/typebox/typebox.d.ts","../../../node_modules/@jest/schemas/build/index.d.ts","../../../node_modules/pretty-format/build/index.d.ts","../../../node_modules/jest-diff/build/index.d.ts","../../../node_modules/jest-matcher-utils/build/index.d.ts","../../../node_modules/expect/build/index.d.ts","../../../node_modules/@types/jest/index.d.ts"],"fileInfos":[{"version":"8730f4bf322026ff5229336391a18bcaa1f94d4f82416c8b2f3954e2ccaae2ba","affectsGlobalScope":true},"dc47c4fa66b9b9890cf076304de2a9c5201e94b740cffdf09f87296d877d71f6","7a387c58583dfca701b6c85e0adaf43fb17d590fb16d5b2dc0a2fbd89f35c467","8a12173c586e95f4433e0c6dc446bc88346be73ffe9ca6eec7aa63c8f3dca7f9","5f4e733ced4e129482ae2186aae29fde948ab7182844c3a5a51dd346182c7b06","4b421cbfb3a38a27c279dec1e9112c3d1da296f77a1a85ddadf7e7a425d45d18","1fc5ab7a764205c68fa10d381b08417795fc73111d6dd16b5b1ed36badb743d9",{"version":"3aafcb693fe5b5c3bd277bd4c3a617b53db474fe498fc5df067c5603b1eebde7","affectsGlobalScope":true},{"version":"f3d4da15233e593eacb3965cde7960f3fddf5878528d882bcedd5cbaba0193c7","affectsGlobalScope":true},{"version":"adb996790133eb33b33aadb9c09f15c2c575e71fb57a62de8bf74dbf59ec7dfb","affectsGlobalScope":true},{"version":"8cc8c5a3bac513368b0157f3d8b31cfdcfe78b56d3724f30f80ed9715e404af8","affectsGlobalScope":true},{"version":"cdccba9a388c2ee3fd6ad4018c640a471a6c060e96f1232062223063b0a5ac6a","affectsGlobalScope":true},{"version":"c5c05907c02476e4bde6b7e76a79ffcd948aedd14b6a8f56e4674221b0417398","affectsGlobalScope":true},{"version":"5f406584aef28a331c36523df688ca3650288d14f39c5d2e555c95f0d2ff8f6f","affectsGlobalScope":true},{"version":"22f230e544b35349cfb3bd9110b6ef37b41c6d6c43c3314a31bd0d9652fcec72","affectsGlobalScope":true},{"version":"7ea0b55f6b315cf9ac2ad622b0a7813315bb6e97bf4bb3fbf8f8affbca7dc695","affectsGlobalScope":true},{"version":"3013574108c36fd3aaca79764002b3717da09725a36a6fc02eac386593110f93","affectsGlobalScope":true},{"version":"eb26de841c52236d8222f87e9e6a235332e0788af8c87a71e9e210314300410a","affectsGlobalScope":true},{"version":"3be5a1453daa63e031d266bf342f3943603873d890ab8b9ada95e22389389006","affectsGlobalScope":true},{"version":"17bb1fc99591b00515502d264fa55dc8370c45c5298f4a5c2083557dccba5a2a","affectsGlobalScope":true},{"version":"7ce9f0bde3307ca1f944119f6365f2d776d281a393b576a18a2f2893a2d75c98","affectsGlobalScope":true},{"version":"6a6b173e739a6a99629a8594bfb294cc7329bfb7b227f12e1f7c11bc163b8577","affectsGlobalScope":true},{"version":"81cac4cbc92c0c839c70f8ffb94eb61e2d32dc1c3cf6d95844ca099463cf37ea","affectsGlobalScope":true},{"version":"b0124885ef82641903d232172577f2ceb5d3e60aed4da1153bab4221e1f6dd4e","affectsGlobalScope":true},{"version":"0eb85d6c590b0d577919a79e0084fa1744c1beba6fd0d4e951432fa1ede5510a","affectsGlobalScope":true},{"version":"da233fc1c8a377ba9e0bed690a73c290d843c2c3d23a7bd7ec5cd3d7d73ba1e0","affectsGlobalScope":true},{"version":"d154ea5bb7f7f9001ed9153e876b2d5b8f5c2bb9ec02b3ae0d239ec769f1f2ae","affectsGlobalScope":true},{"version":"bb2d3fb05a1d2ffbca947cc7cbc95d23e1d053d6595391bd325deb265a18d36c","affectsGlobalScope":true},{"version":"c80df75850fea5caa2afe43b9949338ce4e2de086f91713e9af1a06f973872b8","affectsGlobalScope":true},{"version":"9d57b2b5d15838ed094aa9ff1299eecef40b190722eb619bac4616657a05f951","affectsGlobalScope":true},{"version":"6c51b5dd26a2c31dbf37f00cfc32b2aa6a92e19c995aefb5b97a3a64f1ac99de","affectsGlobalScope":true},{"version":"6e7997ef61de3132e4d4b2250e75343f487903ddf5370e7ce33cf1b9db9a63ed","affectsGlobalScope":true},{"version":"2ad234885a4240522efccd77de6c7d99eecf9b4de0914adb9a35c0c22433f993","affectsGlobalScope":true},{"version":"5e5e095c4470c8bab227dbbc61374878ecead104c74ab9960d3adcccfee23205","affectsGlobalScope":true},{"version":"09aa50414b80c023553090e2f53827f007a301bc34b0495bfb2c3c08ab9ad1eb","affectsGlobalScope":true},{"version":"d7f680a43f8cd12a6b6122c07c54ba40952b0c8aa140dcfcf32eb9e6cb028596","affectsGlobalScope":true},{"version":"3787b83e297de7c315d55d4a7c546ae28e5f6c0a361b7a1dcec1f1f50a54ef11","affectsGlobalScope":true},{"version":"e7e8e1d368290e9295ef18ca23f405cf40d5456fa9f20db6373a61ca45f75f40","affectsGlobalScope":true},{"version":"faf0221ae0465363c842ce6aa8a0cbda5d9296940a8e26c86e04cc4081eea21e","affectsGlobalScope":true},{"version":"06393d13ea207a1bfe08ec8d7be562549c5e2da8983f2ee074e00002629d1871","affectsGlobalScope":true},{"version":"2768ef564cfc0689a1b76106c421a2909bdff0acbe87da010785adab80efdd5c","affectsGlobalScope":true},{"version":"b248e32ca52e8f5571390a4142558ae4f203ae2f94d5bac38a3084d529ef4e58","affectsGlobalScope":true},{"version":"52d1bb7ab7a3306fd0375c8bff560feed26ed676a5b0457fa8027b563aecb9a4","affectsGlobalScope":true},"7a1971efcba559ea9002ada4c4e3c925004fb67a755300d53b5edf9399354900",{"version":"1f8f1bd57f21c36cc25547a0cb99a097f5e5443815789833d230741315a3a948","signature":"aac4ddff3d5c1247433870879e9838b1e23b81a9b62c75f59c3e1b64802f2b16"},"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",{"version":"c0ae510b4743cf5f73102c35337e76cdf9b6340c9e6f117191422603d4387236","signature":"21583817860b17e4b3e44bb8f61dd5965baf7acf41f67bfbf5546e78bd58810c"},"09df3b4f1c937f02e7fee2836d4c4d7a63e66db70fd4d4e97126f4542cc21d9d","7394959e5a741b185456e1ef5d64599c36c60a323207450991e7a42e08911419",{"version":"32465ea19404cb188e84cf08c6b1f6b12d739140436402cdbc184a3fd20a7d81","affectsGlobalScope":true},"cce1f5f86974c1e916ec4a8cab6eec9aa8e31e8148845bf07fbaa8e1d97b1a2c",{"version":"45c22e7e615c8bb6e27325339490f6bd83828d843f9f3cf0ce9fd4d81f6cd923","affectsGlobalScope":true},"546ab07e19116d935ad982e76a223275b53bff7771dab94f433b7ab04652936e","7b43160a49cf2c6082da0465876c4a0b164e160b81187caeb0a6ca7a281e85ba",{"version":"aefb5a4a209f756b580eb53ea771cca8aad411603926f307a5e5b8ec6b16dcf6","affectsGlobalScope":true},"a40826e8476694e90da94aa008283a7de50d1dafd37beada623863f1901cb7fb","f5a8b7ec4b798c88679194a8ebc25dcb6f5368e6e5811fcda9fe12b0d445b8db","b86e1a45b29437f3a99bad4147cb9fe2357617e8008c0484568e5bb5138d6e13","b5b719a47968cd61a6f83f437236bb6fe22a39223b6620da81ef89f5d7a78fb7","42c431e7965b641106b5e25ab3283aa4865ca7bb9909610a2abfa6226e4348be","0b7e732af0a9599be28c091d6bd1cb22c856ec0d415d4749c087c3881ca07a56","b7fe70be794e13d1b7940e318b8770cd1fb3eced7707805318a2e3aaac2c3e9e",{"version":"2c71199d1fc83bf17636ad5bf63a945633406b7b94887612bba4ef027c662b3e","affectsGlobalScope":true},{"version":"c65eca1f892b9e5ee97af93963b2bdf813e4be3b599d06dfb681da19df8358b0","affectsGlobalScope":true},"3b4c85eea12187de9929a76792b98406e8778ce575caca8c574f06da82622c54","f788131a39c81e0c9b9e463645dd7132b5bc1beb609b0e31e5c1ceaea378b4df","1ee64912f7961165a3b6e6209fb7a8aced98b578ca1373b9f0ea144edfe17f6c","21894466693f64957b9bd4c80fa3ec7fdfd4efa9d1861e070aca23f10220c9b2","396a8939b5e177542bdf9b5262b4eee85d29851b2d57681fa9d7eae30e225830","ad8848c289c0b633452e58179f46edccd14b5a0fe90ebce411f79ff040b803e0",{"version":"5d4ef3f46c7f9d62f7c964f9f9ccdd293be99fb3dcc66c983f2aea7430e3c7c6","affectsGlobalScope":true},"91f8b5abcdff8f9ecb9656b9852878718416fb7700b2c4fad8331e5b97c080bb","59d8f064f86a4a2be03b33c0efcc9e7a268ad27b22f82dce16899f3364f70ba8","0f05c06ff6196958d76b865ae17245b52d8fe01773626ac3c43214a2458ea7b7",{"version":"f49fb15c4aa06b65b0dce4db4584bfd8a9f74644baef1511b404dc95be34af00","affectsGlobalScope":true},{"version":"d48009cbe8a30a504031cc82e1286f78fed33b7a42abf7602c23b5547b382563","affectsGlobalScope":true},"7aaeb5e62f90e1b2be0fc4844df78cdb1be15c22b427bc6c39d57308785b8f10","3ba30205a029ebc0c91d7b1ab4da73f6277d730ca1fc6692d5a9144c6772c76b","d8dba11dc34d50cb4202de5effa9a1b296d7a2f4a029eec871f894bddfb6430d","8b71dd18e7e63b6f991b511a201fad7c3bf8d1e0dd98acb5e3d844f335a73634","01d8e1419c84affad359cc240b2b551fb9812b450b4d3d456b64cda8102d4f60","458b216959c231df388a5de9dcbcafd4b4ca563bc3784d706d0455467d7d4942","269929a24b2816343a178008ac9ae9248304d92a8ba8e233055e0ed6dbe6ef71","93452d394fdd1dc551ec62f5042366f011a00d342d36d50793b3529bfc9bd633","f8c87b19eae111f8720b0345ab301af8d81add39621b63614dfc2d15fd6f140a","831c22d257717bf2cbb03afe9c4bcffc5ccb8a2074344d4238bf16d3a857bb12",{"version":"786dd9ad95e335a5e76759d078940fdb5001b74498a31f90fad98afe196a84ca","affectsGlobalScope":true},{"version":"cbf046714f3a3ba2544957e1973ac94aa819fa8aa668846fa8de47eb1c41b0b2","affectsGlobalScope":true},"aa34c3aa493d1c699601027c441b9664547c3024f9dbab1639df7701d63d18fa","eae74e3d50820f37c72c0679fed959cd1e63c98f6a146a55b8c4361582fa6a52","7c651f8dce91a927ab62925e73f190763574c46098f2b11fb8ddc1b147a6709a","7440ab60f4cb031812940cc38166b8bb6fbf2540cfe599f87c41c08011f0c1df",{"version":"aed89e3c18f4c659ee8153a76560dffda23e2d801e1e60d7a67abd84bc555f8d","affectsGlobalScope":true},{"version":"0ed13c80faeb2b7160bffb4926ff299c468e67a37a645b3ae0917ba0db633c1b","affectsGlobalScope":true},"e393915d3dc385e69c0e2390739c87b2d296a610662eb0b1cb85224e55992250","2f940651c2f30e6b29f8743fae3f40b7b1c03615184f837132b56ea75edad08b","5749c327c3f789f658072f8340786966c8b05ea124a56c1d8d60e04649495a4d",{"version":"c9d62b2a51b2ff166314d8be84f6881a7fcbccd37612442cf1c70d27d5352f50","affectsGlobalScope":true},"e7dbf5716d76846c7522e910896c5747b6df1abd538fee8f5291bdc843461795",{"version":"ab9b9a36e5284fd8d3bf2f7d5fcbc60052f25f27e4d20954782099282c60d23e","affectsGlobalScope":true},"d3f4c342fb62f348f25f54b473b0ab7371828cbf637134194fa9cdf04856f87b","cdcc132f207d097d7d3aa75615ab9a2e71d6a478162dde8b67f88ea19f3e54de","0d14fa22c41fdc7277e6f71473b20ebc07f40f00e38875142335d5b63cdfc9d2","c085e9aa62d1ae1375794c1fb927a445fa105fed891a7e24edbb1c3300f7384a","f315e1e65a1f80992f0509e84e4ae2df15ecd9ef73df975f7c98813b71e4c8da","5b9586e9b0b6322e5bfbd2c29bd3b8e21ab9d871f82346cb71020e3d84bae73e","3e70a7e67c2cb16f8cd49097360c0309fe9d1e3210ff9222e9dac1f8df9d4fb6","ab68d2a3e3e8767c3fba8f80de099a1cfc18c0de79e42cb02ae66e22dfe14a66","d96cc6598148bf1a98fb2e8dcf01c63a4b3558bdaec6ef35e087fd0562eb40ec",{"version":"c8950367d1812758e9e354c695c60c3e6311bf2cd98b9f9eb469a19df8a9a486","affectsGlobalScope":true}],"options":{"allowSyntheticDefaultImports":true,"declaration":true,"emitDecoratorMetadata":true,"esModuleInterop":true,"experimentalDecorators":true,"importHelpers":true,"inlineSources":true,"module":99,"noEmitOnError":true,"noImplicitAny":false,"outDir":"./","skipLibCheck":true,"sourceMap":true,"strict":true,"target":4,"useDefineForClassFields":false},"fileIdsList":[[94],[94,104],[94,106,109],[48,94],[51,94],[52,57,85,94],[53,64,65,72,82,93,94],[53,54,64,72,94],[55,94],[56,57,65,73,94],[57,82,90,94],[58,60,64,72,94],[59,94],[60,61,94],[64,94],[62,64,94],[51,64,94],[64,65,66,82,93,94],[64,65,66,79,82,85,94],[94,98],[60,64,67,72,82,93,94],[64,65,67,68,72,82,90,93,94],[67,69,82,90,93,94],[48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100],[64,70,94],[71,93,94,98],[60,64,72,82,94],[73,94],[74,94],[51,75,94],[76,92,94,98],[77,94],[78,94],[64,79,80,94],[79,81,94,96],[52,64,82,83,84,85,94],[52,82,84,94],[82,83,94],[85,94],[86,94],[51,82,94],[64,88,89,94],[88,89,94],[57,72,82,90,94],[91,94],[72,92,94],[52,67,78,93,94],[57,94],[82,94,95],[71,94,96],[94,97],[52,57,64,66,75,82,93,94,96,98],[82,94,99],[94,102,108],[94,106],[94,103,107],[94,105],[44,94]],"referencedMap":[[102,1],[105,2],[104,1],[110,3],[48,4],[49,4],[51,5],[52,6],[53,7],[54,8],[55,9],[56,10],[57,11],[58,12],[59,13],[60,14],[61,14],[63,15],[62,16],[64,17],[65,18],[66,19],[50,20],[100,1],[67,21],[68,22],[69,23],[101,24],[70,25],[71,26],[72,27],[73,28],[74,29],[75,30],[76,31],[77,32],[78,33],[79,34],[80,34],[81,35],[82,36],[84,37],[83,38],[85,39],[86,40],[87,41],[88,42],[89,43],[90,44],[91,45],[92,46],[93,47],[94,48],[95,49],[96,50],[97,51],[98,52],[99,53],[103,1],[109,54],[107,55],[108,56],[8,1],[9,1],[11,1],[10,1],[2,1],[12,1],[13,1],[14,1],[15,1],[16,1],[17,1],[18,1],[19,1],[3,1],[4,1],[23,1],[20,1],[21,1],[22,1],[24,1],[25,1],[26,1],[5,1],[27,1],[28,1],[29,1],[30,1],[6,1],[34,1],[31,1],[32,1],[33,1],[35,1],[7,1],[36,1],[41,1],[42,1],[37,1],[38,1],[39,1],[40,1],[1,1],[43,1],[106,57],[44,1],[45,58],[46,1],[47,58]],"exportedModulesMap":[[102,1],[105,2],[104,1],[110,3],[48,4],[49,4],[51,5],[52,6],[53,7],[54,8],[55,9],[56,10],[57,11],[58,12],[59,13],[60,14],[61,14],[63,15],[62,16],[64,17],[65,18],[66,19],[50,20],[100,1],[67,21],[68,22],[69,23],[101,24],[70,25],[71,26],[72,27],[73,28],[74,29],[75,30],[76,31],[77,32],[78,33],[79,34],[80,34],[81,35],[82,36],[84,37],[83,38],[85,39],[86,40],[87,41],[88,42],[89,43],[90,44],[91,45],[92,46],[93,47],[94,48],[95,49],[96,50],[97,51],[98,52],[99,53],[103,1],[109,54],[107,55],[108,56],[8,1],[9,1],[11,1],[10,1],[2,1],[12,1],[13,1],[14,1],[15,1],[16,1],[17,1],[18,1],[19,1],[3,1],[4,1],[23,1],[20,1],[21,1],[22,1],[24,1],[25,1],[26,1],[5,1],[27,1],[28,1],[29,1],[30,1],[6,1],[34,1],[31,1],[32,1],[33,1],[35,1],[7,1],[36,1],[41,1],[42,1],[37,1],[38,1],[39,1],[40,1],[1,1],[43,1],[106,57],[44,1],[46,1]],"semanticDiagnosticsPerFile":[102,105,104,110,48,49,51,52,53,54,55,56,57,58,59,60,61,63,62,64,65,66,50,100,67,68,69,101,70,71,72,73,74,75,76,77,78,79,80,81,82,84,83,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,103,109,107,108,8,9,11,10,2,12,13,14,15,16,17,18,19,3,4,23,20,21,22,24,25,26,5,27,28,29,30,6,34,31,32,33,35,7,36,41,42,37,38,39,40,1,43,106,44,45,46,47]},"version":"4.9.5"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getAccessToken = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const node_fetch_1 = tslib_1.__importDefault(require("node-fetch"));
|
|
6
|
+
const env_1 = require("@things-factory/env");
|
|
7
|
+
const SSOAzureADConfig = env_1.config.get('SSOAzureAD');
|
|
8
|
+
const authorityHostUrl = 'https://login.microsoftonline.com';
|
|
9
|
+
const authorityUrl = `${authorityHostUrl}/${SSOAzureADConfig.tenantID}`;
|
|
10
|
+
const resource = 'https://graph.microsoft.com';
|
|
11
|
+
const OAUTH2_URL = `${authorityUrl}/oauth2/token?api-version=1.0`;
|
|
12
|
+
async function getAccessToken() {
|
|
13
|
+
try {
|
|
14
|
+
const tokenResponse = await (0, node_fetch_1.default)(OAUTH2_URL, {
|
|
15
|
+
method: 'POST',
|
|
16
|
+
headers: {
|
|
17
|
+
'Content-Type': 'application/x-www-form-urlencoded'
|
|
18
|
+
},
|
|
19
|
+
body: `client_id=${SSOAzureADConfig.clientID}&resource=${resource}&client_secret=${SSOAzureADConfig.clientSecret}&grant_type=client_credentials`
|
|
20
|
+
});
|
|
21
|
+
const result = await tokenResponse.json();
|
|
22
|
+
const { access_token } = result;
|
|
23
|
+
return access_token;
|
|
24
|
+
}
|
|
25
|
+
catch (error) {
|
|
26
|
+
console.error('Error fetching access token:', error);
|
|
27
|
+
return null;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
exports.getAccessToken = getAccessToken;
|
|
31
|
+
//# sourceMappingURL=get-access-token.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"get-access-token.js","sourceRoot":"","sources":["../../server/controllers/get-access-token.ts"],"names":[],"mappings":";;;;AAAA,oEAA8B;AAE9B,6CAA4C;AAE5C,MAAM,gBAAgB,GAAG,YAAM,CAAC,GAAG,CAAC,YAAY,CAAC,CAAA;AAEjD,MAAM,gBAAgB,GAAG,mCAAmC,CAAA;AAC5D,MAAM,YAAY,GAAG,GAAG,gBAAgB,IAAI,gBAAgB,CAAC,QAAQ,EAAE,CAAA;AACvE,MAAM,QAAQ,GAAG,6BAA6B,CAAA;AAC9C,MAAM,UAAU,GAAG,GAAG,YAAY,+BAA+B,CAAA;AAE1D,KAAK,UAAU,cAAc;IAClC,IAAI;QACF,MAAM,aAAa,GAAG,MAAM,IAAA,oBAAK,EAAC,UAAU,EAAE;YAC5C,MAAM,EAAE,MAAM;YACd,OAAO,EAAE;gBACP,cAAc,EAAE,mCAAmC;aACpD;YACD,IAAI,EAAE,aAAa,gBAAgB,CAAC,QAAQ,aAAa,QAAQ,kBAAkB,gBAAgB,CAAC,YAAY,gCAAgC;SACjJ,CAAC,CAAA;QAEF,MAAM,MAAM,GAAG,MAAM,aAAa,CAAC,IAAI,EAAE,CAAA;QACzC,MAAM,EAAE,YAAY,EAAE,GAAG,MAAM,CAAA;QAC/B,OAAO,YAAY,CAAA;KACpB;IAAC,OAAO,KAAK,EAAE;QACd,OAAO,CAAC,KAAK,CAAC,8BAA8B,EAAE,KAAK,CAAC,CAAA;QACpD,OAAO,IAAI,CAAA;KACZ;AACH,CAAC;AAjBD,wCAiBC","sourcesContent":["import fetch from 'node-fetch'\n\nimport { config } from '@things-factory/env'\n\nconst SSOAzureADConfig = config.get('SSOAzureAD')\n\nconst authorityHostUrl = 'https://login.microsoftonline.com'\nconst authorityUrl = `${authorityHostUrl}/${SSOAzureADConfig.tenantID}`\nconst resource = 'https://graph.microsoft.com'\nconst OAUTH2_URL = `${authorityUrl}/oauth2/token?api-version=1.0`\n\nexport async function getAccessToken(): Promise<string | null> {\n try {\n const tokenResponse = await fetch(OAUTH2_URL, {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/x-www-form-urlencoded'\n },\n body: `client_id=${SSOAzureADConfig.clientID}&resource=${resource}&client_secret=${SSOAzureADConfig.clientSecret}&grant_type=client_credentials`\n })\n\n const result = await tokenResponse.json()\n const { access_token } = result\n return access_token\n } catch (error) {\n console.error('Error fetching access token:', error)\n return null\n }\n}\n"]}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.msgraphSubscriptions = exports.getClientState = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const node_fetch_1 = tslib_1.__importDefault(require("node-fetch"));
|
|
6
|
+
const crypto_1 = require("crypto");
|
|
7
|
+
const get_access_token_1 = require("./get-access-token");
|
|
8
|
+
var clientState;
|
|
9
|
+
function getClientState() {
|
|
10
|
+
return clientState;
|
|
11
|
+
}
|
|
12
|
+
exports.getClientState = getClientState;
|
|
13
|
+
async function msgraphSubscriptions() {
|
|
14
|
+
const accessToken = await (0, get_access_token_1.getAccessToken)();
|
|
15
|
+
const expirationDateTime = new Date(Date.now() + 3 * 24 * 60 * 60 * 1000);
|
|
16
|
+
clientState = (0, crypto_1.randomBytes)(20).toString('hex');
|
|
17
|
+
const response = await (0, node_fetch_1.default)('https://graph.microsoft.com/v1.0/subscriptions', {
|
|
18
|
+
method: 'POST',
|
|
19
|
+
headers: {
|
|
20
|
+
Authorization: `Bearer ${accessToken}`,
|
|
21
|
+
'Content-Type': 'application/json'
|
|
22
|
+
},
|
|
23
|
+
body: JSON.stringify({
|
|
24
|
+
changeType: 'created,updated',
|
|
25
|
+
notificationUrl: 'YOUR_WEBHOOK_ENDPOINT_BASE' + '/webhook/azure-ad-users',
|
|
26
|
+
resource: '/users',
|
|
27
|
+
expirationDateTime: expirationDateTime.toISOString() /* 최대 3일 이내, UTC 타임으로 설정 */,
|
|
28
|
+
clientState
|
|
29
|
+
})
|
|
30
|
+
});
|
|
31
|
+
const data = await response.json();
|
|
32
|
+
}
|
|
33
|
+
exports.msgraphSubscriptions = msgraphSubscriptions;
|
|
34
|
+
//# sourceMappingURL=subscribe-users-change.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"subscribe-users-change.js","sourceRoot":"","sources":["../../server/controllers/subscribe-users-change.ts"],"names":[],"mappings":";;;;AAAA,oEAA8B;AAC9B,mCAAoC;AAEpC,yDAAmD;AAEnD,IAAI,WAAW,CAAA;AAEf,SAAgB,cAAc;IAC5B,OAAO,WAAW,CAAA;AACpB,CAAC;AAFD,wCAEC;AAEM,KAAK,UAAU,oBAAoB;IACxC,MAAM,WAAW,GAAG,MAAM,IAAA,iCAAc,GAAE,CAAA;IAC1C,MAAM,kBAAkB,GAAG,IAAI,IAAI,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,IAAI,CAAC,CAAA;IAEzE,WAAW,GAAG,IAAA,oBAAW,EAAC,EAAE,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAA;IAE7C,MAAM,QAAQ,GAAG,MAAM,IAAA,oBAAK,EAAC,gDAAgD,EAAE;QAC7E,MAAM,EAAE,MAAM;QACd,OAAO,EAAE;YACP,aAAa,EAAE,UAAU,WAAW,EAAE;YACtC,cAAc,EAAE,kBAAkB;SACnC;QACD,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC;YACnB,UAAU,EAAE,iBAAiB;YAC7B,eAAe,EAAE,4BAA4B,GAAG,yBAAyB;YACzE,QAAQ,EAAE,QAAQ;YAClB,kBAAkB,EAAE,kBAAkB,CAAC,WAAW,EAAE,CAAC,2BAA2B;YAChF,WAAW;SACZ,CAAC;KACH,CAAC,CAAA;IAEF,MAAM,IAAI,GAAG,MAAM,QAAQ,CAAC,IAAI,EAAE,CAAA;AACpC,CAAC;AAtBD,oDAsBC","sourcesContent":["import fetch from 'node-fetch'\nimport { randomBytes } from 'crypto'\n\nimport { getAccessToken } from './get-access-token'\n\nvar clientState\n\nexport function getClientState() {\n return clientState\n}\n\nexport async function msgraphSubscriptions() {\n const accessToken = await getAccessToken()\n const expirationDateTime = new Date(Date.now() + 3 * 24 * 60 * 60 * 1000)\n\n clientState = randomBytes(20).toString('hex')\n\n const response = await fetch('https://graph.microsoft.com/v1.0/subscriptions', {\n method: 'POST',\n headers: {\n Authorization: `Bearer ${accessToken}`,\n 'Content-Type': 'application/json'\n },\n body: JSON.stringify({\n changeType: 'created,updated',\n notificationUrl: 'YOUR_WEBHOOK_ENDPOINT_BASE' + '/webhook/azure-ad-users',\n resource: '/users',\n expirationDateTime: expirationDateTime.toISOString() /* 최대 3일 이내, UTC 타임으로 설정 */,\n clientState\n })\n })\n\n const data = await response.json()\n}\n"]}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.updateUserInfo = exports.syncAllUserInfo = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const node_fetch_1 = tslib_1.__importDefault(require("node-fetch"));
|
|
6
|
+
const auth_base_1 = require("@things-factory/auth-base");
|
|
7
|
+
const get_access_token_1 = require("./get-access-token");
|
|
8
|
+
async function syncAllUserInfo(context) {
|
|
9
|
+
const accessToken = await (0, get_access_token_1.getAccessToken)();
|
|
10
|
+
if (!accessToken) {
|
|
11
|
+
throw new Error('Failed to obtain access token');
|
|
12
|
+
}
|
|
13
|
+
const latestData = await (0, node_fetch_1.default)('https://graph.microsoft.com/v1.0/users', {
|
|
14
|
+
headers: {
|
|
15
|
+
Authorization: `Bearer ${accessToken}`
|
|
16
|
+
}
|
|
17
|
+
}).then(res => res.json());
|
|
18
|
+
latestData.value
|
|
19
|
+
.filter(({ mail }) => mail)
|
|
20
|
+
.forEach(async (user) => {
|
|
21
|
+
await updateUserInfo(user, context);
|
|
22
|
+
});
|
|
23
|
+
}
|
|
24
|
+
exports.syncAllUserInfo = syncAllUserInfo;
|
|
25
|
+
async function updateUserInfo(userInfo, context) {
|
|
26
|
+
const { tx, domain, user } = context.state;
|
|
27
|
+
// {
|
|
28
|
+
// "id": "d290f1ee-6c54-4b01-90e6-d701748f0851",
|
|
29
|
+
// "businessPhones": [
|
|
30
|
+
// "+1 412 555 0109"
|
|
31
|
+
// ],
|
|
32
|
+
// "displayName": "John Doe",
|
|
33
|
+
// "givenName": "John",
|
|
34
|
+
// "jobTitle": "Developer",
|
|
35
|
+
// "mail": "john.doe@contoso.com",
|
|
36
|
+
// "mobilePhone": "+1 412 555 0109",
|
|
37
|
+
// "officeLocation": "Floor 2",
|
|
38
|
+
// "preferredLanguage": "en-US",
|
|
39
|
+
// "surname": "Doe",
|
|
40
|
+
// "userPrincipalName": "john.doe@contoso.com"
|
|
41
|
+
// }
|
|
42
|
+
const { id, businessPhones, displayName, givenName, surname, jobTitle, mail, mobilePhone, officeLocation, preferredLanguage, userPricipalName } = userInfo;
|
|
43
|
+
const repository = tx.getRepository(auth_base_1.User);
|
|
44
|
+
// 1. 사용자를 찾는다.(email 정보로)
|
|
45
|
+
const existingUser = await repository.findOne({
|
|
46
|
+
where: { email: mail },
|
|
47
|
+
relations: ['domains']
|
|
48
|
+
});
|
|
49
|
+
if (!existingUser) {
|
|
50
|
+
// 2. 사용자가 없다면, 생성한다.
|
|
51
|
+
const salt = auth_base_1.User.generateSalt();
|
|
52
|
+
/* normally they don't login with this password. */
|
|
53
|
+
const password = salt;
|
|
54
|
+
return await repository.save({
|
|
55
|
+
id,
|
|
56
|
+
name: displayName,
|
|
57
|
+
email: mail,
|
|
58
|
+
creator: user,
|
|
59
|
+
updater: user,
|
|
60
|
+
domains: domain ? [domain] : [],
|
|
61
|
+
roles: [],
|
|
62
|
+
salt,
|
|
63
|
+
userType: 'user',
|
|
64
|
+
ssoId: id,
|
|
65
|
+
locale: preferredLanguage,
|
|
66
|
+
status: auth_base_1.UserStatus.ACTIVATED,
|
|
67
|
+
passwordUpdatedAt: new Date(),
|
|
68
|
+
password: auth_base_1.User.encode(password, salt)
|
|
69
|
+
});
|
|
70
|
+
repository.save({});
|
|
71
|
+
}
|
|
72
|
+
else {
|
|
73
|
+
// 3. 사용자가 있다면, 업데이트한다.
|
|
74
|
+
return await repository.save(Object.assign(Object.assign({}, existingUser), { name: displayName, ssoId: id, locale: preferredLanguage, updater: user }));
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
exports.updateUserInfo = updateUserInfo;
|
|
78
|
+
//# sourceMappingURL=sync-user-info.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sync-user-info.js","sourceRoot":"","sources":["../../server/controllers/sync-user-info.ts"],"names":[],"mappings":";;;;AAAA,oEAA8B;AAE9B,yDAA4D;AAC5D,yDAAmD;AAE5C,KAAK,UAAU,eAAe,CAAC,OAAwB;IAC5D,MAAM,WAAW,GAAG,MAAM,IAAA,iCAAc,GAAE,CAAA;IAE1C,IAAI,CAAC,WAAW,EAAE;QAChB,MAAM,IAAI,KAAK,CAAC,+BAA+B,CAAC,CAAA;KACjD;IAED,MAAM,UAAU,GAAG,MAAM,IAAA,oBAAK,EAAC,wCAAwC,EAAE;QACvE,OAAO,EAAE;YACP,aAAa,EAAE,UAAU,WAAW,EAAE;SACvC;KACF,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,CAAA;IAE1B,UAAU,CAAC,KAAK;SACb,MAAM,CAAC,CAAC,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC,IAAI,CAAC;SAC1B,OAAO,CAAC,KAAK,EAAC,IAAI,EAAC,EAAE;QACpB,MAAM,cAAc,CAAC,IAAI,EAAE,OAAO,CAAC,CAAA;IACrC,CAAC,CAAC,CAAA;AACN,CAAC;AAlBD,0CAkBC;AAEM,KAAK,UAAU,cAAc,CAAC,QAAQ,EAAE,OAAwB;IACrE,MAAM,EAAE,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC,KAAK,CAAA;IAE1C,IAAI;IACJ,kDAAkD;IAClD,wBAAwB;IACxB,wBAAwB;IACxB,OAAO;IACP,+BAA+B;IAC/B,yBAAyB;IACzB,6BAA6B;IAC7B,oCAAoC;IACpC,sCAAsC;IACtC,iCAAiC;IACjC,kCAAkC;IAClC,sBAAsB;IACtB,gDAAgD;IAChD,IAAI;IACJ,MAAM,EACJ,EAAE,EACF,cAAc,EACd,WAAW,EACX,SAAS,EACT,OAAO,EACP,QAAQ,EACR,IAAI,EACJ,WAAW,EACX,cAAc,EACd,iBAAiB,EACjB,gBAAgB,EACjB,GAAG,QAAQ,CAAA;IACZ,MAAM,UAAU,GAAG,EAAE,CAAC,aAAa,CAAC,gBAAI,CAAC,CAAA;IAEzC,0BAA0B;IAC1B,MAAM,YAAY,GAAG,MAAM,UAAU,CAAC,OAAO,CAAC;QAC5C,KAAK,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE;QACtB,SAAS,EAAE,CAAC,SAAS,CAAC;KACvB,CAAC,CAAA;IAEF,IAAI,CAAC,YAAY,EAAE;QACjB,qBAAqB;QACrB,MAAM,IAAI,GAAG,gBAAI,CAAC,YAAY,EAAE,CAAA;QAEhC,mDAAmD;QACnD,MAAM,QAAQ,GAAG,IAAI,CAAA;QAErB,OAAO,MAAM,UAAU,CAAC,IAAI,CAAC;YAC3B,EAAE;YACF,IAAI,EAAE,WAAW;YACjB,KAAK,EAAE,IAAI;YACX,OAAO,EAAE,IAAI;YACb,OAAO,EAAE,IAAI;YACb,OAAO,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,EAAE;YAC/B,KAAK,EAAE,EAAE;YACT,IAAI;YACJ,QAAQ,EAAE,MAAM;YAChB,KAAK,EAAE,EAAE;YACT,MAAM,EAAE,iBAAiB;YACzB,MAAM,EAAE,sBAAU,CAAC,SAAS;YAC5B,iBAAiB,EAAE,IAAI,IAAI,EAAE;YAC7B,QAAQ,EAAE,gBAAI,CAAC,MAAM,CAAC,QAAQ,EAAE,IAAI,CAAC;SACtC,CAAC,CAAA;QAEF,UAAU,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;KACpB;SAAM;QACL,uBAAuB;QACvB,OAAO,MAAM,UAAU,CAAC,IAAI,iCACvB,YAAY,KACf,IAAI,EAAE,WAAW,EACjB,KAAK,EAAE,EAAE,EACT,MAAM,EAAE,iBAAiB,EACzB,OAAO,EAAE,IAAI,IACb,CAAA;KACH;AACH,CAAC;AA1ED,wCA0EC","sourcesContent":["import fetch from 'node-fetch'\n\nimport { User, UserStatus } from '@things-factory/auth-base'\nimport { getAccessToken } from './get-access-token'\n\nexport async function syncAllUserInfo(context: ResolverContext) {\n const accessToken = await getAccessToken()\n\n if (!accessToken) {\n throw new Error('Failed to obtain access token')\n }\n\n const latestData = await fetch('https://graph.microsoft.com/v1.0/users', {\n headers: {\n Authorization: `Bearer ${accessToken}`\n }\n }).then(res => res.json())\n\n latestData.value\n .filter(({ mail }) => mail)\n .forEach(async user => {\n await updateUserInfo(user, context)\n })\n}\n\nexport async function updateUserInfo(userInfo, context: ResolverContext) {\n const { tx, domain, user } = context.state\n\n // {\n // \"id\": \"d290f1ee-6c54-4b01-90e6-d701748f0851\",\n // \"businessPhones\": [\n // \"+1 412 555 0109\"\n // ],\n // \"displayName\": \"John Doe\",\n // \"givenName\": \"John\",\n // \"jobTitle\": \"Developer\",\n // \"mail\": \"john.doe@contoso.com\",\n // \"mobilePhone\": \"+1 412 555 0109\",\n // \"officeLocation\": \"Floor 2\",\n // \"preferredLanguage\": \"en-US\",\n // \"surname\": \"Doe\",\n // \"userPrincipalName\": \"john.doe@contoso.com\"\n // }\n const {\n id,\n businessPhones,\n displayName,\n givenName,\n surname,\n jobTitle,\n mail,\n mobilePhone,\n officeLocation,\n preferredLanguage,\n userPricipalName\n } = userInfo\n const repository = tx.getRepository(User)\n\n // 1. 사용자를 찾는다.(email 정보로)\n const existingUser = await repository.findOne({\n where: { email: mail },\n relations: ['domains']\n })\n\n if (!existingUser) {\n // 2. 사용자가 없다면, 생성한다.\n const salt = User.generateSalt()\n\n /* normally they don't login with this password. */\n const password = salt\n\n return await repository.save({\n id,\n name: displayName,\n email: mail,\n creator: user,\n updater: user,\n domains: domain ? [domain] : [],\n roles: [],\n salt,\n userType: 'user',\n ssoId: id,\n locale: preferredLanguage,\n status: UserStatus.ACTIVATED,\n passwordUpdatedAt: new Date(),\n password: User.encode(password, salt)\n })\n\n repository.save({})\n } else {\n // 3. 사용자가 있다면, 업데이트한다.\n return await repository.save({\n ...existingUser,\n name: displayName,\n ssoId: id,\n locale: preferredLanguage,\n updater: user\n })\n }\n}\n"]}
|
package/dist-server/index.js
CHANGED
|
@@ -2,5 +2,6 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const tslib_1 = require("tslib");
|
|
4
4
|
tslib_1.__exportStar(require("./middlewares"), exports);
|
|
5
|
+
tslib_1.__exportStar(require("./service"), exports);
|
|
5
6
|
require("./routes");
|
|
6
7
|
//# sourceMappingURL=index.js.map
|
package/dist-server/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../server/index.ts"],"names":[],"mappings":";;;AAAA,wDAA6B;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../server/index.ts"],"names":[],"mappings":";;;AAAA,wDAA6B;AAC7B,oDAAyB;AAEzB,oBAAiB","sourcesContent":["export * from './middlewares'\nexport * from './service'\n\nimport './routes'\n"]}
|
|
@@ -6,18 +6,4 @@ const koa_router_1 = tslib_1.__importDefault(require("koa-router"));
|
|
|
6
6
|
const koa_passport_1 = tslib_1.__importDefault(require("koa-passport"));
|
|
7
7
|
exports.authAzureADRouter = new koa_router_1.default();
|
|
8
8
|
exports.authAzureADRouter.post('/auth/callback-azure-ad', koa_passport_1.default.authenticate('azuread-openidconnect', { failureRedirect: '/auth/signin', successRedirect: '/auth/checkin' }));
|
|
9
|
-
// authAzureADRouter.post('/auth/callback-azure-ad', azureADMiddleware, async (context, next) => {
|
|
10
|
-
// const { request, t } = context
|
|
11
|
-
// const { token, domain } = context.state
|
|
12
|
-
// const { body: reqBody, header } = request
|
|
13
|
-
// // if (!accepts(header.accept, ['text/html', '*/*'])) {
|
|
14
|
-
// // context.body = token
|
|
15
|
-
// // return
|
|
16
|
-
// // }
|
|
17
|
-
// var redirectTo = `/auth/checkin${domain ? '/' + domain.subdomain : ''}?redirect_to=${encodeURIComponent(
|
|
18
|
-
// reqBody.redirectTo || '/'
|
|
19
|
-
// )}`
|
|
20
|
-
// setAccessTokenCookie(context, token)
|
|
21
|
-
// context.redirect(redirectTo)
|
|
22
|
-
// })
|
|
23
9
|
//# sourceMappingURL=auth-azure-ad-router.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth-azure-ad-router.js","sourceRoot":"","sources":["../../server/router/auth-azure-ad-router.ts"],"names":[],"mappings":";;;;AAAA,oEAA+B;AAE/B,wEAAmC;AAGtB,QAAA,iBAAiB,GAAG,IAAI,oBAAM,EAAE,CAAA;AAE7C,yBAAiB,CAAC,IAAI,CACpB,yBAAyB,EACzB,sBAAQ,CAAC,YAAY,CAAC,uBAAuB,EAAE,EAAE,eAAe,EAAE,cAAc,EAAE,eAAe,EAAE,eAAe,EAAE,CAAC,CACtH,CAAA
|
|
1
|
+
{"version":3,"file":"auth-azure-ad-router.js","sourceRoot":"","sources":["../../server/router/auth-azure-ad-router.ts"],"names":[],"mappings":";;;;AAAA,oEAA+B;AAE/B,wEAAmC;AAGtB,QAAA,iBAAiB,GAAG,IAAI,oBAAM,EAAE,CAAA;AAE7C,yBAAiB,CAAC,IAAI,CACpB,yBAAyB,EACzB,sBAAQ,CAAC,YAAY,CAAC,uBAAuB,EAAE,EAAE,eAAe,EAAE,cAAc,EAAE,eAAe,EAAE,eAAe,EAAE,CAAC,CACtH,CAAA","sourcesContent":["import Router from 'koa-router'\n\nimport passport from 'koa-passport'\nimport { azureADMiddleware } from '../middlewares'\n\nexport const authAzureADRouter = new Router()\n\nauthAzureADRouter.post(\n '/auth/callback-azure-ad',\n passport.authenticate('azuread-openidconnect', { failureRedirect: '/auth/signin', successRedirect: '/auth/checkin' })\n)\n"]}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.authAzureADWebhookRouter = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const koa_router_1 = tslib_1.__importDefault(require("koa-router"));
|
|
6
|
+
const node_fetch_1 = tslib_1.__importDefault(require("node-fetch"));
|
|
7
|
+
const shell_1 = require("@things-factory/shell");
|
|
8
|
+
const sync_user_info_1 = require("../controllers/sync-user-info");
|
|
9
|
+
const get_access_token_1 = require("../controllers/get-access-token");
|
|
10
|
+
const subscribe_users_change_1 = require("../controllers/subscribe-users-change");
|
|
11
|
+
exports.authAzureADWebhookRouter = new koa_router_1.default();
|
|
12
|
+
exports.authAzureADWebhookRouter.post('/webhook/azure-ad-users', async (context) => {
|
|
13
|
+
const accessToken = await (0, get_access_token_1.getAccessToken)();
|
|
14
|
+
const notifications = context.request.body.value;
|
|
15
|
+
const clientState = context.request.body.clientState;
|
|
16
|
+
if (clientState !== (0, subscribe_users_change_1.getClientState)()) {
|
|
17
|
+
// clientState 값이 일치하지 않으면 알림 무시 또는 오류 처리
|
|
18
|
+
context.status = 401; // unauthorized
|
|
19
|
+
context.body = 'Invalid clientState';
|
|
20
|
+
return;
|
|
21
|
+
}
|
|
22
|
+
for (const notification of notifications) {
|
|
23
|
+
const userId = notification.resourceData.id;
|
|
24
|
+
try {
|
|
25
|
+
const userResponse = await (0, node_fetch_1.default)(`https://graph.microsoft.com/v1.0/users/${userId}`, {
|
|
26
|
+
headers: {
|
|
27
|
+
Authorization: `Bearer ${accessToken}`
|
|
28
|
+
}
|
|
29
|
+
});
|
|
30
|
+
if (!userResponse.ok) {
|
|
31
|
+
throw new Error(`Failed to fetch user data: ${userResponse.statusText}`);
|
|
32
|
+
}
|
|
33
|
+
const userInfo = await userResponse.json();
|
|
34
|
+
// {
|
|
35
|
+
// "@odata.context": "https://graph.microsoft.com/v1.0/$metadata#users/$entity",
|
|
36
|
+
// "businessPhones": ["+1 412 555 0109"],
|
|
37
|
+
// "displayName": "Megan Bowen",
|
|
38
|
+
// "givenName": "Megan",
|
|
39
|
+
// "jobTitle": "Auditor",
|
|
40
|
+
// "mail": "MeganB@M365x214355.onmicrosoft.com",
|
|
41
|
+
// "mobilePhone": "+1 412 555 0109",
|
|
42
|
+
// "officeLocation": "12/1110",
|
|
43
|
+
// "preferredLanguage": "en-US",
|
|
44
|
+
// "surname": "Bowen",
|
|
45
|
+
// "userPrincipalName": "MeganB@M365x214355.onmicrosoft.com",
|
|
46
|
+
// "id": "48d31887-5fad-4d73-a9f5-3c356e68a038"
|
|
47
|
+
// }
|
|
48
|
+
// webhook 호출로부터 호출한 tenant를 알 수 있다면, 매핑된 도메인 정보를 포함할 수 있을 것 같은데..
|
|
49
|
+
return await (0, shell_1.getDataSource)('tx').transaction(async (tx) => {
|
|
50
|
+
const wrap = context.app.createContext(context.req || {}, context.res || {});
|
|
51
|
+
wrap.state = Object.assign(Object.assign({}, context.state), { domain: null, tx });
|
|
52
|
+
wrap.t = context.t;
|
|
53
|
+
return await (0, sync_user_info_1.updateUserInfo)(userInfo, wrap);
|
|
54
|
+
});
|
|
55
|
+
}
|
|
56
|
+
catch (error) {
|
|
57
|
+
console.error('Error fetching user data from Microsoft Graph:', error);
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
context.status = 202;
|
|
61
|
+
});
|
|
62
|
+
//# sourceMappingURL=auth-azure-ad-webhook-router.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"auth-azure-ad-webhook-router.js","sourceRoot":"","sources":["../../server/router/auth-azure-ad-webhook-router.ts"],"names":[],"mappings":";;;;AAAA,oEAA+B;AAC/B,oEAA8B;AAE9B,iDAAqD;AAErD,kEAA8D;AAC9D,sEAAgE;AAChE,kFAAsE;AAEzD,QAAA,wBAAwB,GAAG,IAAI,oBAAM,EAAE,CAAA;AASpD,gCAAwB,CAAC,IAAI,CAAC,yBAAyB,EAAE,KAAK,EAAC,OAAO,EAAC,EAAE;IACvE,MAAM,WAAW,GAAG,MAAM,IAAA,iCAAc,GAAE,CAAA;IAC1C,MAAM,aAAa,GAAmB,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,KAAK,CAAA;IAChE,MAAM,WAAW,GAAG,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,WAAW,CAAA;IAEpD,IAAI,WAAW,KAAK,IAAA,uCAAc,GAAE,EAAE;QACpC,yCAAyC;QACzC,OAAO,CAAC,MAAM,GAAG,GAAG,CAAA,CAAC,eAAe;QACpC,OAAO,CAAC,IAAI,GAAG,qBAAqB,CAAA;QACpC,OAAM;KACP;IAED,KAAK,MAAM,YAAY,IAAI,aAAa,EAAE;QACxC,MAAM,MAAM,GAAG,YAAY,CAAC,YAAY,CAAC,EAAE,CAAA;QAE3C,IAAI;YACF,MAAM,YAAY,GAAG,MAAM,IAAA,oBAAK,EAAC,0CAA0C,MAAM,EAAE,EAAE;gBACnF,OAAO,EAAE;oBACP,aAAa,EAAE,UAAU,WAAW,EAAE;iBACvC;aACF,CAAC,CAAA;YAEF,IAAI,CAAC,YAAY,CAAC,EAAE,EAAE;gBACpB,MAAM,IAAI,KAAK,CAAC,8BAA8B,YAAY,CAAC,UAAU,EAAE,CAAC,CAAA;aACzE;YAED,MAAM,QAAQ,GAAG,MAAM,YAAY,CAAC,IAAI,EAAE,CAAA;YAE1C,IAAI;YACJ,kFAAkF;YAClF,2CAA2C;YAC3C,kCAAkC;YAClC,0BAA0B;YAC1B,2BAA2B;YAC3B,kDAAkD;YAClD,sCAAsC;YACtC,iCAAiC;YACjC,kCAAkC;YAClC,wBAAwB;YACxB,+DAA+D;YAC/D,iDAAiD;YACjD,IAAI;YAEJ,kEAAkE;YAElE,OAAO,MAAM,IAAA,qBAAa,EAAC,IAAI,CAAC,CAAC,WAAW,CAAC,KAAK,EAAC,EAAE,EAAC,EAAE;gBACtD,MAAM,IAAI,GAAG,OAAO,CAAC,GAAG,CAAC,aAAa,CAAC,OAAO,CAAC,GAAG,IAAI,EAAE,EAAE,OAAO,CAAC,GAAG,IAAI,EAAE,CAAC,CAAA;gBAE5E,IAAI,CAAC,KAAK,mCACL,OAAO,CAAC,KAAK,KAChB,MAAM,EAAE,IAAI,EACZ,EAAE,GACH,CAAA;gBACD,IAAI,CAAC,CAAC,GAAG,OAAO,CAAC,CAAC,CAAA;gBAElB,OAAO,MAAM,IAAA,+BAAc,EAAC,QAAQ,EAAE,IAAI,CAAC,CAAA;YAC7C,CAAC,CAAC,CAAA;SACH;QAAC,OAAO,KAAK,EAAE;YACd,OAAO,CAAC,KAAK,CAAC,gDAAgD,EAAE,KAAK,CAAC,CAAA;SACvE;KACF;IAED,OAAO,CAAC,MAAM,GAAG,GAAG,CAAA;AACtB,CAAC,CAAC,CAAA","sourcesContent":["import Router from 'koa-router'\nimport fetch from 'node-fetch'\n\nimport { getDataSource } from '@things-factory/shell'\n\nimport { updateUserInfo } from '../controllers/sync-user-info'\nimport { getAccessToken } from '../controllers/get-access-token'\nimport { getClientState } from '../controllers/subscribe-users-change'\n\nexport const authAzureADWebhookRouter = new Router()\n\n// Microsoft Graph에서 발송되는 알림을 처리하기 위한 타입 정의\ninterface Notification {\n resourceData: {\n id: string\n }\n}\n\nauthAzureADWebhookRouter.post('/webhook/azure-ad-users', async context => {\n const accessToken = await getAccessToken()\n const notifications: Notification[] = context.request.body.value\n const clientState = context.request.body.clientState\n\n if (clientState !== getClientState()) {\n // clientState 값이 일치하지 않으면 알림 무시 또는 오류 처리\n context.status = 401 // unauthorized\n context.body = 'Invalid clientState'\n return\n }\n\n for (const notification of notifications) {\n const userId = notification.resourceData.id\n\n try {\n const userResponse = await fetch(`https://graph.microsoft.com/v1.0/users/${userId}`, {\n headers: {\n Authorization: `Bearer ${accessToken}`\n }\n })\n\n if (!userResponse.ok) {\n throw new Error(`Failed to fetch user data: ${userResponse.statusText}`)\n }\n\n const userInfo = await userResponse.json()\n\n // {\n // \"@odata.context\": \"https://graph.microsoft.com/v1.0/$metadata#users/$entity\",\n // \"businessPhones\": [\"+1 412 555 0109\"],\n // \"displayName\": \"Megan Bowen\",\n // \"givenName\": \"Megan\",\n // \"jobTitle\": \"Auditor\",\n // \"mail\": \"MeganB@M365x214355.onmicrosoft.com\",\n // \"mobilePhone\": \"+1 412 555 0109\",\n // \"officeLocation\": \"12/1110\",\n // \"preferredLanguage\": \"en-US\",\n // \"surname\": \"Bowen\",\n // \"userPrincipalName\": \"MeganB@M365x214355.onmicrosoft.com\",\n // \"id\": \"48d31887-5fad-4d73-a9f5-3c356e68a038\"\n // }\n\n // webhook 호출로부터 호출한 tenant를 알 수 있다면, 매핑된 도메인 정보를 포함할 수 있을 것 같은데..\n\n return await getDataSource('tx').transaction(async tx => {\n const wrap = context.app.createContext(context.req || {}, context.res || {})\n\n wrap.state = {\n ...context.state,\n domain: null,\n tx\n }\n wrap.t = context.t\n\n return await updateUserInfo(userInfo, wrap)\n })\n } catch (error) {\n console.error('Error fetching user data from Microsoft Graph:', error)\n }\n }\n\n context.status = 202\n})\n"]}
|
|
@@ -2,4 +2,5 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const tslib_1 = require("tslib");
|
|
4
4
|
tslib_1.__exportStar(require("./auth-azure-ad-router"), exports);
|
|
5
|
+
tslib_1.__exportStar(require("./auth-azure-ad-webhook-router"), exports);
|
|
5
6
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../server/router/index.ts"],"names":[],"mappings":";;;AAAA,iEAAsC","sourcesContent":["export * from './auth-azure-ad-router'\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../server/router/index.ts"],"names":[],"mappings":";;;AAAA,iEAAsC;AACtC,yEAA8C","sourcesContent":["export * from './auth-azure-ad-router'\nexport * from './auth-azure-ad-webhook-router'\n"]}
|
package/dist-server/routes.js
CHANGED
|
@@ -10,6 +10,7 @@ if (SSOAzureADConfig) {
|
|
|
10
10
|
});
|
|
11
11
|
process.on('bootstrap-module-domain-public-route', (app, domainPublicRouter) => {
|
|
12
12
|
domainPublicRouter.use(router_1.authAzureADRouter.routes(), router_1.authAzureADRouter.allowedMethods());
|
|
13
|
+
domainPublicRouter.use(router_1.authAzureADWebhookRouter.routes(), router_1.authAzureADWebhookRouter.allowedMethods());
|
|
13
14
|
});
|
|
14
15
|
}
|
|
15
16
|
//# sourceMappingURL=routes.js.map
|