@azure/msal-browser 3.13.0 → 3.15.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/app/IPublicClientApplication.d.ts +2 -1
- package/dist/app/IPublicClientApplication.d.ts.map +1 -1
- package/dist/app/IPublicClientApplication.mjs +4 -1
- package/dist/app/IPublicClientApplication.mjs.map +1 -1
- package/dist/app/PublicClientApplication.d.ts +17 -0
- package/dist/app/PublicClientApplication.d.ts.map +1 -1
- package/dist/app/PublicClientApplication.mjs +37 -9
- package/dist/app/PublicClientApplication.mjs.map +1 -1
- package/dist/app/PublicClientNext.d.ts +3 -0
- package/dist/app/PublicClientNext.d.ts.map +1 -1
- package/dist/app/PublicClientNext.mjs +4 -1
- package/dist/app/PublicClientNext.mjs.map +1 -1
- package/dist/broker/nativeBroker/NativeMessageHandler.mjs +1 -1
- package/dist/broker/nativeBroker/NativeStatusCodes.mjs +1 -1
- package/dist/cache/AccountManager.d.ts +49 -0
- package/dist/cache/AccountManager.d.ts.map +1 -0
- package/dist/cache/AccountManager.mjs +131 -0
- package/dist/cache/AccountManager.mjs.map +1 -0
- package/dist/cache/AsyncMemoryStorage.mjs +1 -1
- package/dist/cache/BrowserCacheManager.d.ts.map +1 -1
- package/dist/cache/BrowserCacheManager.mjs +9 -2
- package/dist/cache/BrowserCacheManager.mjs.map +1 -1
- package/dist/cache/BrowserStorage.mjs +1 -1
- package/dist/cache/DatabaseStorage.mjs +1 -1
- package/dist/cache/MemoryStorage.mjs +1 -1
- package/dist/cache/TokenCache.mjs +1 -1
- package/dist/config/Configuration.d.ts +3 -1
- package/dist/config/Configuration.d.ts.map +1 -1
- package/dist/config/Configuration.mjs +1 -1
- package/dist/config/Configuration.mjs.map +1 -1
- package/dist/controllers/ControllerFactory.d.ts.map +1 -1
- package/dist/controllers/ControllerFactory.mjs +10 -12
- package/dist/controllers/ControllerFactory.mjs.map +1 -1
- package/dist/controllers/NestedAppAuthController.d.ts +118 -10
- package/dist/controllers/NestedAppAuthController.d.ts.map +1 -1
- package/dist/controllers/NestedAppAuthController.mjs +227 -83
- package/dist/controllers/NestedAppAuthController.mjs.map +1 -1
- package/dist/controllers/StandardController.d.ts.map +1 -1
- package/dist/controllers/StandardController.mjs +98 -115
- package/dist/controllers/StandardController.mjs.map +1 -1
- package/dist/controllers/UnknownOperatingContextController.mjs +1 -1
- package/dist/crypto/BrowserCrypto.mjs +1 -1
- package/dist/crypto/CryptoOps.mjs +1 -1
- package/dist/crypto/PkceGenerator.mjs +1 -1
- package/dist/crypto/SignedHttpRequest.mjs +1 -1
- package/dist/encode/Base64Decode.mjs +1 -1
- package/dist/encode/Base64Encode.mjs +1 -1
- package/dist/error/BrowserAuthError.mjs +1 -1
- package/dist/error/BrowserAuthErrorCodes.mjs +1 -1
- package/dist/error/BrowserConfigurationAuthError.mjs +1 -1
- package/dist/error/BrowserConfigurationAuthErrorCodes.mjs +1 -1
- package/dist/error/NativeAuthError.mjs +1 -1
- package/dist/error/NativeAuthErrorCodes.mjs +1 -1
- package/dist/error/NestedAppAuthError.mjs +1 -1
- package/dist/event/EventHandler.mjs +1 -1
- package/dist/event/EventMessage.mjs +1 -1
- package/dist/event/EventType.mjs +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.mjs +2 -2
- package/dist/interaction_client/BaseInteractionClient.mjs +1 -1
- package/dist/interaction_client/HybridSpaAuthorizationCodeClient.mjs +1 -1
- package/dist/interaction_client/NativeInteractionClient.mjs +1 -1
- package/dist/interaction_client/PopupClient.mjs +1 -1
- package/dist/interaction_client/RedirectClient.d.ts +4 -5
- package/dist/interaction_client/RedirectClient.d.ts.map +1 -1
- package/dist/interaction_client/RedirectClient.mjs +5 -8
- package/dist/interaction_client/RedirectClient.mjs.map +1 -1
- package/dist/interaction_client/SilentAuthCodeClient.mjs +1 -1
- package/dist/interaction_client/SilentCacheClient.mjs +1 -1
- package/dist/interaction_client/SilentIframeClient.mjs +1 -1
- package/dist/interaction_client/SilentRefreshClient.mjs +1 -1
- package/dist/interaction_client/StandardInteractionClient.mjs +1 -1
- package/dist/interaction_handler/InteractionHandler.mjs +1 -1
- package/dist/interaction_handler/RedirectHandler.mjs +1 -1
- package/dist/interaction_handler/SilentHandler.mjs +1 -1
- package/dist/naa/BridgeAccountContext.d.ts +13 -0
- package/dist/naa/BridgeAccountContext.d.ts.map +1 -0
- package/dist/naa/BridgeCapabilities.d.ts +1 -1
- package/dist/naa/BridgeCapabilities.d.ts.map +1 -1
- package/dist/naa/BridgeError.mjs +1 -1
- package/dist/naa/BridgeProxy.d.ts +3 -2
- package/dist/naa/BridgeProxy.d.ts.map +1 -1
- package/dist/naa/BridgeProxy.mjs +9 -7
- package/dist/naa/BridgeProxy.mjs.map +1 -1
- package/dist/naa/BridgeRequestEnvelope.d.ts +1 -1
- package/dist/naa/BridgeRequestEnvelope.d.ts.map +1 -1
- package/dist/naa/BridgeStatusCode.mjs +1 -1
- package/dist/naa/IBridgeProxy.d.ts +2 -2
- package/dist/naa/IBridgeProxy.d.ts.map +1 -1
- package/dist/naa/InitContext.d.ts +2 -0
- package/dist/naa/InitContext.d.ts.map +1 -1
- package/dist/naa/mapping/NestedAppAuthAdapter.d.ts +12 -2
- package/dist/naa/mapping/NestedAppAuthAdapter.d.ts.map +1 -1
- package/dist/naa/mapping/NestedAppAuthAdapter.mjs +43 -6
- package/dist/naa/mapping/NestedAppAuthAdapter.mjs.map +1 -1
- package/dist/navigation/NavigationClient.mjs +1 -1
- package/dist/network/FetchClient.mjs +1 -1
- package/dist/operatingcontext/BaseOperatingContext.mjs +1 -1
- package/dist/operatingcontext/{TeamsAppOperatingContext.d.ts → NestedAppOperatingContext.d.ts} +8 -6
- package/dist/operatingcontext/NestedAppOperatingContext.d.ts.map +1 -0
- package/dist/operatingcontext/{TeamsAppOperatingContext.mjs → NestedAppOperatingContext.mjs} +21 -35
- package/dist/operatingcontext/NestedAppOperatingContext.mjs.map +1 -0
- package/dist/operatingcontext/StandardOperatingContext.d.ts.map +1 -1
- package/dist/operatingcontext/StandardOperatingContext.mjs +1 -1
- package/dist/operatingcontext/StandardOperatingContext.mjs.map +1 -1
- package/dist/operatingcontext/UnknownOperatingContext.d.ts +5 -5
- package/dist/operatingcontext/UnknownOperatingContext.d.ts.map +1 -1
- package/dist/operatingcontext/UnknownOperatingContext.mjs +8 -8
- package/dist/operatingcontext/UnknownOperatingContext.mjs.map +1 -1
- package/dist/packageMetadata.d.ts +1 -1
- package/dist/packageMetadata.mjs +2 -2
- package/dist/request/RequestHelpers.mjs +1 -1
- package/dist/response/ResponseHandler.mjs +1 -1
- package/dist/telemetry/BrowserPerformanceClient.mjs +1 -1
- package/dist/telemetry/BrowserPerformanceMeasurement.mjs +1 -1
- package/dist/utils/BrowserConstants.mjs +1 -1
- package/dist/utils/BrowserProtocolUtils.mjs +1 -1
- package/dist/utils/BrowserUtils.d.ts +3 -0
- package/dist/utils/BrowserUtils.d.ts.map +1 -1
- package/dist/utils/BrowserUtils.mjs +2 -1
- package/dist/utils/BrowserUtils.mjs.map +1 -1
- package/lib/msal-browser.cjs +10568 -10231
- package/lib/msal-browser.cjs.map +1 -1
- package/lib/msal-browser.js +10568 -10231
- package/lib/msal-browser.js.map +1 -1
- package/lib/msal-browser.min.js +69 -68
- package/package.json +6 -4
- package/src/app/IPublicClientApplication.ts +5 -0
- package/src/app/PublicClientApplication.ts +43 -8
- package/src/app/PublicClientNext.ts +3 -0
- package/src/cache/AccountManager.ts +184 -0
- package/src/cache/BrowserCacheManager.ts +11 -2
- package/src/config/Configuration.ts +3 -1
- package/src/controllers/ControllerFactory.ts +9 -14
- package/src/controllers/NestedAppAuthController.ts +375 -82
- package/src/controllers/StandardController.ts +125 -149
- package/src/index.ts +5 -1
- package/src/interaction_client/RedirectClient.ts +6 -12
- package/src/naa/BridgeAccountContext.ts +17 -0
- package/src/naa/BridgeCapabilities.ts +2 -1
- package/src/naa/BridgeProxy.ts +11 -6
- package/src/naa/BridgeRequestEnvelope.ts +1 -6
- package/src/naa/IBridgeProxy.ts +2 -2
- package/src/naa/InitContext.ts +2 -0
- package/src/naa/mapping/NestedAppAuthAdapter.ts +68 -2
- package/src/operatingcontext/{TeamsAppOperatingContext.ts → NestedAppOperatingContext.ts} +23 -31
- package/src/operatingcontext/StandardOperatingContext.ts +1 -0
- package/src/operatingcontext/UnknownOperatingContext.ts +8 -7
- package/src/packageMetadata.ts +1 -1
- package/src/utils/BrowserUtils.ts +4 -1
- package/dist/operatingcontext/TeamsAppOperatingContext.d.ts.map +0 -1
- package/dist/operatingcontext/TeamsAppOperatingContext.mjs.map +0 -1
package/src/naa/IBridgeProxy.ts
CHANGED
|
@@ -3,14 +3,14 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { AccountInfo } from "./AccountInfo";
|
|
7
6
|
import { AuthResult } from "./AuthResult";
|
|
7
|
+
import { AccountContext } from "./BridgeAccountContext";
|
|
8
8
|
import { BridgeCapabilities } from "./BridgeCapabilities";
|
|
9
9
|
import { TokenRequest } from "./TokenRequest";
|
|
10
10
|
|
|
11
11
|
export interface IBridgeProxy {
|
|
12
12
|
getTokenInteractive(request: TokenRequest): Promise<AuthResult>;
|
|
13
13
|
getTokenSilent(request: TokenRequest): Promise<AuthResult>;
|
|
14
|
-
getActiveAccount(): Promise<AccountInfo>;
|
|
15
14
|
getHostCapabilities(): BridgeCapabilities | null;
|
|
15
|
+
getAccountContext(): AccountContext | null;
|
|
16
16
|
}
|
package/src/naa/InitContext.ts
CHANGED
|
@@ -4,9 +4,11 @@
|
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
6
|
import { BridgeCapabilities } from "./BridgeCapabilities";
|
|
7
|
+
import { AccountContext } from "./BridgeAccountContext";
|
|
7
8
|
|
|
8
9
|
export interface InitContext {
|
|
9
10
|
capabilities?: BridgeCapabilities;
|
|
10
11
|
sdkName: string;
|
|
11
12
|
sdkVersion: string;
|
|
13
|
+
accountContext?: AccountContext;
|
|
12
14
|
}
|
|
@@ -24,6 +24,11 @@ import {
|
|
|
24
24
|
StringUtils,
|
|
25
25
|
createClientAuthError,
|
|
26
26
|
OIDC_DEFAULT_SCOPES,
|
|
27
|
+
AccountInfo,
|
|
28
|
+
IdTokenEntity,
|
|
29
|
+
AccessTokenEntity,
|
|
30
|
+
TenantProfile,
|
|
31
|
+
buildTenantProfileFromIdTokenClaims,
|
|
27
32
|
} from "@azure/msal-common";
|
|
28
33
|
import { isBridgeError } from "../BridgeError";
|
|
29
34
|
import { BridgeStatusCode } from "../BridgeStatusCode";
|
|
@@ -110,6 +115,7 @@ export class NestedAppAuthAdapter {
|
|
|
110
115
|
);
|
|
111
116
|
const account = this.fromNaaAccountInfo(
|
|
112
117
|
response.account,
|
|
118
|
+
response.token.id_token,
|
|
113
119
|
idTokenClaims
|
|
114
120
|
);
|
|
115
121
|
const scopes = response.token.scope || request.scope;
|
|
@@ -123,7 +129,7 @@ export class NestedAppAuthAdapter {
|
|
|
123
129
|
idToken: response.token.id_token,
|
|
124
130
|
idTokenClaims,
|
|
125
131
|
accessToken: response.token.access_token,
|
|
126
|
-
fromCache:
|
|
132
|
+
fromCache: false,
|
|
127
133
|
expiresOn: expiresOn,
|
|
128
134
|
tokenType:
|
|
129
135
|
request.authenticationScheme || AuthenticationScheme.BEARER,
|
|
@@ -159,6 +165,7 @@ export class NestedAppAuthAdapter {
|
|
|
159
165
|
*/
|
|
160
166
|
public fromNaaAccountInfo(
|
|
161
167
|
fromAccount: NaaAccountInfo,
|
|
168
|
+
idToken?: string,
|
|
162
169
|
idTokenClaims?: TokenClaims
|
|
163
170
|
): MsalAccountInfo {
|
|
164
171
|
const effectiveIdTokenClaims =
|
|
@@ -183,6 +190,14 @@ export class NestedAppAuthAdapter {
|
|
|
183
190
|
|
|
184
191
|
const name = fromAccount.name || effectiveIdTokenClaims?.name;
|
|
185
192
|
|
|
193
|
+
const tenantProfiles = new Map<string, TenantProfile>();
|
|
194
|
+
|
|
195
|
+
const tenantProfile = buildTenantProfileFromIdTokenClaims(
|
|
196
|
+
homeAccountId,
|
|
197
|
+
effectiveIdTokenClaims
|
|
198
|
+
);
|
|
199
|
+
tenantProfiles.set(tenantId, tenantProfile);
|
|
200
|
+
|
|
186
201
|
const account: MsalAccountInfo = {
|
|
187
202
|
homeAccountId,
|
|
188
203
|
environment: fromAccount.environment,
|
|
@@ -190,8 +205,9 @@ export class NestedAppAuthAdapter {
|
|
|
190
205
|
username,
|
|
191
206
|
localAccountId,
|
|
192
207
|
name,
|
|
193
|
-
idToken:
|
|
208
|
+
idToken: idToken,
|
|
194
209
|
idTokenClaims: effectiveIdTokenClaims,
|
|
210
|
+
tenantProfiles,
|
|
195
211
|
};
|
|
196
212
|
|
|
197
213
|
return account;
|
|
@@ -249,4 +265,54 @@ export class NestedAppAuthAdapter {
|
|
|
249
265
|
return new AuthError("unknown_error", "An unknown error occurred");
|
|
250
266
|
}
|
|
251
267
|
}
|
|
268
|
+
|
|
269
|
+
/**
|
|
270
|
+
* Returns an AuthenticationResult from the given cache items
|
|
271
|
+
*
|
|
272
|
+
* @param account
|
|
273
|
+
* @param idToken
|
|
274
|
+
* @param accessToken
|
|
275
|
+
* @param reqTimestamp
|
|
276
|
+
* @returns
|
|
277
|
+
*/
|
|
278
|
+
public toAuthenticationResultFromCache(
|
|
279
|
+
account: AccountInfo,
|
|
280
|
+
idToken: IdTokenEntity,
|
|
281
|
+
accessToken: AccessTokenEntity,
|
|
282
|
+
request: SilentRequest,
|
|
283
|
+
correlationId: string
|
|
284
|
+
): AuthenticationResult {
|
|
285
|
+
if (!idToken || !accessToken) {
|
|
286
|
+
throw createClientAuthError(ClientAuthErrorCodes.nullOrEmptyToken);
|
|
287
|
+
}
|
|
288
|
+
|
|
289
|
+
const idTokenClaims = AuthToken.extractTokenClaims(
|
|
290
|
+
idToken.secret,
|
|
291
|
+
this.crypto.base64Decode
|
|
292
|
+
);
|
|
293
|
+
|
|
294
|
+
const scopes = accessToken.target || request.scopes.join(" ");
|
|
295
|
+
|
|
296
|
+
const authenticationResult: AuthenticationResult = {
|
|
297
|
+
authority: accessToken.environment || account.environment,
|
|
298
|
+
uniqueId: account.localAccountId,
|
|
299
|
+
tenantId: account.tenantId,
|
|
300
|
+
scopes: scopes.split(" "),
|
|
301
|
+
account,
|
|
302
|
+
idToken: idToken.secret,
|
|
303
|
+
idTokenClaims: idTokenClaims || {},
|
|
304
|
+
accessToken: accessToken.secret,
|
|
305
|
+
fromCache: true,
|
|
306
|
+
expiresOn: new Date(Number(accessToken.expiresOn) * 1000),
|
|
307
|
+
tokenType:
|
|
308
|
+
request.authenticationScheme || AuthenticationScheme.BEARER,
|
|
309
|
+
correlationId,
|
|
310
|
+
extExpiresOn: new Date(
|
|
311
|
+
Number(accessToken.extendedExpiresOn) * 1000
|
|
312
|
+
),
|
|
313
|
+
state: request.state,
|
|
314
|
+
};
|
|
315
|
+
|
|
316
|
+
return authenticationResult;
|
|
317
|
+
}
|
|
252
318
|
}
|
|
@@ -6,11 +6,11 @@
|
|
|
6
6
|
import { BaseOperatingContext } from "./BaseOperatingContext";
|
|
7
7
|
import { IBridgeProxy } from "../naa/IBridgeProxy";
|
|
8
8
|
import { BridgeProxy } from "../naa/BridgeProxy";
|
|
9
|
-
import {
|
|
9
|
+
import { AccountContext } from "../naa/BridgeAccountContext";
|
|
10
10
|
|
|
11
|
-
export class
|
|
11
|
+
export class NestedAppOperatingContext extends BaseOperatingContext {
|
|
12
12
|
protected bridgeProxy: IBridgeProxy | undefined = undefined;
|
|
13
|
-
protected
|
|
13
|
+
protected accountContext: AccountContext | null = null;
|
|
14
14
|
|
|
15
15
|
/*
|
|
16
16
|
* TODO: Once we have determine the bundling code return here to specify the name of the bundle
|
|
@@ -21,7 +21,7 @@ export class TeamsAppOperatingContext extends BaseOperatingContext {
|
|
|
21
21
|
/**
|
|
22
22
|
* Unique identifier for the operating context
|
|
23
23
|
*/
|
|
24
|
-
static readonly ID: string = "
|
|
24
|
+
static readonly ID: string = "NestedAppOperatingContext";
|
|
25
25
|
|
|
26
26
|
/**
|
|
27
27
|
* Return the module name. Intended for use with import() to enable dynamic import
|
|
@@ -29,28 +29,25 @@ export class TeamsAppOperatingContext extends BaseOperatingContext {
|
|
|
29
29
|
* @returns
|
|
30
30
|
*/
|
|
31
31
|
getModuleName(): string {
|
|
32
|
-
return
|
|
32
|
+
return NestedAppOperatingContext.MODULE_NAME;
|
|
33
33
|
}
|
|
34
|
+
|
|
34
35
|
/**
|
|
35
36
|
* Returns the unique identifier for this operating context
|
|
36
37
|
* @returns string
|
|
37
38
|
*/
|
|
38
39
|
getId(): string {
|
|
39
|
-
return
|
|
40
|
+
return NestedAppOperatingContext.ID;
|
|
40
41
|
}
|
|
41
42
|
|
|
43
|
+
/**
|
|
44
|
+
* Returns the current BridgeProxy
|
|
45
|
+
* @returns IBridgeProxy | undefined
|
|
46
|
+
*/
|
|
42
47
|
getBridgeProxy(): IBridgeProxy | undefined {
|
|
43
48
|
return this.bridgeProxy;
|
|
44
49
|
}
|
|
45
50
|
|
|
46
|
-
getActiveAccount(): AccountInfo | undefined {
|
|
47
|
-
return this.activeAccount;
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
setActiveAccount(account: AccountInfo): void {
|
|
51
|
-
this.activeAccount = account;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
51
|
/**
|
|
55
52
|
* Checks whether the operating context is available.
|
|
56
53
|
* Confirms that the code is running a browser rather. This is required.
|
|
@@ -61,31 +58,26 @@ export class TeamsAppOperatingContext extends BaseOperatingContext {
|
|
|
61
58
|
* TODO: Add implementation to check for presence of inject Nested App Auth Bridge JavaScript interface
|
|
62
59
|
*
|
|
63
60
|
*/
|
|
61
|
+
|
|
64
62
|
try {
|
|
65
63
|
if (typeof window !== "undefined") {
|
|
66
64
|
const bridgeProxy: IBridgeProxy = await BridgeProxy.create();
|
|
67
65
|
/*
|
|
68
|
-
* Because we want single sign on we
|
|
69
|
-
*
|
|
70
|
-
* this.
|
|
66
|
+
* Because we want single sign on we expect the host app to provide the account context
|
|
67
|
+
* with a min set of params that can be used to identify the account
|
|
68
|
+
* this.account = nestedApp.getAccountByFilter(bridgeProxy.getAccountContext());
|
|
71
69
|
*/
|
|
72
|
-
|
|
73
|
-
if (bridgeProxy.getHostCapabilities()?.queryAccount) {
|
|
74
|
-
this.activeAccount =
|
|
75
|
-
await bridgeProxy.getActiveAccount();
|
|
76
|
-
}
|
|
77
|
-
} catch (e) {
|
|
78
|
-
this.activeAccount = undefined;
|
|
79
|
-
}
|
|
70
|
+
this.accountContext = bridgeProxy.getAccountContext();
|
|
80
71
|
this.bridgeProxy = bridgeProxy;
|
|
81
72
|
this.available = bridgeProxy !== undefined;
|
|
82
|
-
} else {
|
|
83
|
-
this.available = false;
|
|
84
73
|
}
|
|
85
|
-
} catch (
|
|
86
|
-
this.
|
|
87
|
-
|
|
88
|
-
|
|
74
|
+
} catch (ex) {
|
|
75
|
+
this.logger.infoPii(
|
|
76
|
+
`Could not initialize Nested App Auth bridge (${ex})`
|
|
77
|
+
);
|
|
89
78
|
}
|
|
79
|
+
|
|
80
|
+
this.logger.info(`Nested App Auth Bridge available: ${this.available}`);
|
|
81
|
+
return this.available;
|
|
90
82
|
}
|
|
91
83
|
}
|
|
@@ -17,6 +17,14 @@ export class UnknownOperatingContext extends BaseOperatingContext {
|
|
|
17
17
|
*/
|
|
18
18
|
static readonly ID: string = "UnknownOperatingContext";
|
|
19
19
|
|
|
20
|
+
/**
|
|
21
|
+
* Returns the unique identifier for this operating context
|
|
22
|
+
* @returns string
|
|
23
|
+
*/
|
|
24
|
+
getId(): string {
|
|
25
|
+
return UnknownOperatingContext.ID;
|
|
26
|
+
}
|
|
27
|
+
|
|
20
28
|
/**
|
|
21
29
|
* Return the module name. Intended for use with import() to enable dynamic import
|
|
22
30
|
* of the implementation associated with this operating context
|
|
@@ -25,13 +33,6 @@ export class UnknownOperatingContext extends BaseOperatingContext {
|
|
|
25
33
|
getModuleName(): string {
|
|
26
34
|
return UnknownOperatingContext.MODULE_NAME;
|
|
27
35
|
}
|
|
28
|
-
/**
|
|
29
|
-
* Returns the unique identifier for this operating context
|
|
30
|
-
* @returns string
|
|
31
|
-
*/
|
|
32
|
-
getId(): string {
|
|
33
|
-
return UnknownOperatingContext.ID;
|
|
34
|
-
}
|
|
35
36
|
|
|
36
37
|
/**
|
|
37
38
|
* Checks whether the operating context is available.
|
package/src/packageMetadata.ts
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { UrlString } from "@azure/msal-common";
|
|
6
|
+
import { UrlString, invoke, invokeAsync } from "@azure/msal-common";
|
|
7
7
|
import {
|
|
8
8
|
createBrowserAuthError,
|
|
9
9
|
BrowserAuthErrorCodes,
|
|
@@ -206,3 +206,6 @@ export function preconnect(authority: string): void {
|
|
|
206
206
|
export function createGuid(): string {
|
|
207
207
|
return BrowserCrypto.createNewGuid();
|
|
208
208
|
}
|
|
209
|
+
|
|
210
|
+
export { invoke };
|
|
211
|
+
export { invokeAsync };
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"TeamsAppOperatingContext.d.ts","sourceRoot":"","sources":["../../src/operatingcontext/TeamsAppOperatingContext.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAC9D,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAEnD,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAEjD,qBAAa,wBAAyB,SAAQ,oBAAoB;IAC9D,SAAS,CAAC,WAAW,EAAE,YAAY,GAAG,SAAS,CAAa;IAC5D,SAAS,CAAC,aAAa,EAAE,WAAW,GAAG,SAAS,CAAa;IAM7D,MAAM,CAAC,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAM;IAEzC;;OAEG;IACH,MAAM,CAAC,QAAQ,CAAC,EAAE,EAAE,MAAM,CAA8B;IAExD;;;;OAIG;IACH,aAAa,IAAI,MAAM;IAGvB;;;OAGG;IACH,KAAK,IAAI,MAAM;IAIf,cAAc,IAAI,YAAY,GAAG,SAAS;IAI1C,gBAAgB,IAAI,WAAW,GAAG,SAAS;IAI3C,gBAAgB,CAAC,OAAO,EAAE,WAAW,GAAG,IAAI;IAI5C;;;;OAIG;IACG,UAAU,IAAI,OAAO,CAAC,OAAO,CAAC;CAgCvC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"TeamsAppOperatingContext.mjs","sources":["../../src/operatingcontext/TeamsAppOperatingContext.ts"],"sourcesContent":[null],"names":[],"mappings":";;;;;AAAA;;;AAGG;AAOG,MAAO,wBAAyB,SAAQ,oBAAoB,CAAA;AAAlE,IAAA,WAAA,GAAA;;QACc,IAAW,CAAA,WAAA,GAA6B,SAAS,CAAC;QAClD,IAAa,CAAA,aAAA,GAA4B,SAAS,CAAC;KA8EhE;AAjEG;;;;AAIG;IACH,aAAa,GAAA;QACT,OAAO,wBAAwB,CAAC,WAAW,CAAC;KAC/C;AACD;;;AAGG;IACH,KAAK,GAAA;QACD,OAAO,wBAAwB,CAAC,EAAE,CAAC;KACtC;IAED,cAAc,GAAA;QACV,OAAO,IAAI,CAAC,WAAW,CAAC;KAC3B;IAED,gBAAgB,GAAA;QACZ,OAAO,IAAI,CAAC,aAAa,CAAC;KAC7B;AAED,IAAA,gBAAgB,CAAC,OAAoB,EAAA;AACjC,QAAA,IAAI,CAAC,aAAa,GAAG,OAAO,CAAC;KAChC;AAED;;;;AAIG;AACH,IAAA,MAAM,UAAU,GAAA;AACZ;;;AAGG;QACH,IAAI;AACA,YAAA,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE;AAC/B,gBAAA,MAAM,WAAW,GAAiB,MAAM,WAAW,CAAC,MAAM,EAAE,CAAC;AAC7D;;;;AAIG;gBACH,IAAI;AACA,oBAAA,IAAI,WAAW,CAAC,mBAAmB,EAAE,EAAE,YAAY,EAAE;AACjD,wBAAA,IAAI,CAAC,aAAa;AACd,4BAAA,MAAM,WAAW,CAAC,gBAAgB,EAAE,CAAC;AAC5C,qBAAA;AACJ,iBAAA;AAAC,gBAAA,OAAO,CAAC,EAAE;AACR,oBAAA,IAAI,CAAC,aAAa,GAAG,SAAS,CAAC;AAClC,iBAAA;AACD,gBAAA,IAAI,CAAC,WAAW,GAAG,WAAW,CAAC;AAC/B,gBAAA,IAAI,CAAC,SAAS,GAAG,WAAW,KAAK,SAAS,CAAC;AAC9C,aAAA;AAAM,iBAAA;AACH,gBAAA,IAAI,CAAC,SAAS,GAAG,KAAK,CAAC;AAC1B,aAAA;AACJ,SAAA;AAAC,QAAA,OAAO,CAAC,EAAE;AACR,YAAA,IAAI,CAAC,SAAS,GAAG,KAAK,CAAC;AAC1B,SAAA;AAAS,gBAAA;YACN,OAAO,IAAI,CAAC,SAAS,CAAC;AACzB,SAAA;KACJ;;AA3ED;;;AAGG;AACa,wBAAW,CAAA,WAAA,GAAW,EAAE,CAAC;AAEzC;;AAEG;AACa,wBAAE,CAAA,EAAA,GAAW,0BAA0B;;;;"}
|