@azure/msal-common 16.1.0 → 16.2.1
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/account/AccountInfo.mjs +1 -1
- package/dist/account/AuthToken.mjs +1 -1
- package/dist/account/CcsCredential.mjs +1 -1
- package/dist/account/ClientInfo.mjs +1 -1
- package/dist/account/TokenClaims.mjs +1 -1
- package/dist/authority/Authority.mjs +1 -1
- package/dist/authority/AuthorityFactory.mjs +1 -1
- package/dist/authority/AuthorityMetadata.mjs +1 -1
- package/dist/authority/AuthorityOptions.mjs +1 -1
- package/dist/authority/AuthorityType.mjs +1 -1
- package/dist/authority/CloudInstanceDiscoveryErrorResponse.mjs +1 -1
- package/dist/authority/CloudInstanceDiscoveryResponse.mjs +1 -1
- package/dist/authority/OpenIdConfigResponse.mjs +1 -1
- package/dist/authority/ProtocolMode.mjs +1 -1
- package/dist/authority/RegionDiscovery.mjs +1 -1
- package/dist/cache/CacheManager.mjs +1 -1
- package/dist/cache/persistence/TokenCacheContext.mjs +1 -1
- package/dist/cache/utils/AccountEntityUtils.mjs +1 -1
- package/dist/cache/utils/CacheHelpers.mjs +1 -1
- package/dist/client/AuthorizationCodeClient.mjs +1 -1
- package/dist/client/RefreshTokenClient.mjs +1 -1
- package/dist/client/SilentFlowClient.mjs +1 -1
- package/dist/config/ClientConfiguration.mjs +1 -1
- package/dist/constants/AADServerParamKeys.mjs +1 -1
- package/dist/crypto/ICrypto.mjs +1 -1
- package/dist/crypto/JoseHeader.mjs +1 -1
- package/dist/crypto/PopTokenGenerator.mjs +1 -1
- package/dist/error/AuthError.mjs +1 -1
- package/dist/error/AuthErrorCodes.mjs +1 -1
- package/dist/error/CacheError.mjs +1 -1
- package/dist/error/CacheErrorCodes.mjs +1 -1
- package/dist/error/ClientAuthError.mjs +1 -1
- package/dist/error/ClientAuthErrorCodes.mjs +1 -1
- package/dist/error/ClientConfigurationError.mjs +1 -1
- package/dist/error/ClientConfigurationErrorCodes.mjs +1 -1
- package/dist/error/InteractionRequiredAuthError.mjs +1 -1
- package/dist/error/InteractionRequiredAuthErrorCodes.mjs +1 -1
- package/dist/error/JoseHeaderError.mjs +1 -1
- package/dist/error/JoseHeaderErrorCodes.mjs +1 -1
- package/dist/error/NetworkError.mjs +1 -1
- package/dist/error/PlatformBrokerError.mjs +1 -1
- package/dist/error/ServerError.mjs +1 -1
- package/dist/index-node.mjs +1 -1
- package/dist/index.mjs +1 -1
- package/dist/logger/Logger.mjs +1 -1
- package/dist/network/INetworkModule.mjs +1 -1
- package/dist/network/RequestThumbprint.mjs +1 -1
- package/dist/network/ThrottlingUtils.mjs +1 -1
- package/dist/packageMetadata.d.ts +1 -1
- package/dist/packageMetadata.mjs +2 -2
- package/dist/protocol/Authorize.mjs +1 -1
- package/dist/protocol/Token.mjs +1 -1
- package/dist/request/AuthenticationHeaderParser.mjs +1 -1
- package/dist/request/RequestParameterBuilder.mjs +1 -1
- package/dist/request/ScopeSet.mjs +1 -1
- package/dist/response/ResponseHandler.d.ts +9 -9
- package/dist/response/ResponseHandler.d.ts.map +1 -1
- package/dist/response/ResponseHandler.mjs +27 -20
- package/dist/response/ResponseHandler.mjs.map +1 -1
- package/dist/telemetry/performance/PerformanceClient.d.ts.map +1 -1
- package/dist/telemetry/performance/PerformanceClient.mjs +59 -12
- package/dist/telemetry/performance/PerformanceClient.mjs.map +1 -1
- package/dist/telemetry/performance/PerformanceEvent.d.ts +94 -0
- package/dist/telemetry/performance/PerformanceEvent.d.ts.map +1 -1
- package/dist/telemetry/performance/PerformanceEvent.mjs +9 -2
- package/dist/telemetry/performance/PerformanceEvent.mjs.map +1 -1
- package/dist/telemetry/performance/PerformanceEvents.mjs +1 -1
- package/dist/telemetry/performance/StubPerformanceClient.mjs +1 -1
- package/dist/telemetry/server/ServerTelemetryManager.mjs +1 -1
- package/dist/url/UrlString.mjs +1 -1
- package/dist/utils/ClientAssertionUtils.mjs +1 -1
- package/dist/utils/Constants.mjs +1 -1
- package/dist/utils/FunctionWrappers.d.ts.map +1 -1
- package/dist/utils/FunctionWrappers.mjs +3 -5
- package/dist/utils/FunctionWrappers.mjs.map +1 -1
- package/dist/utils/ProtocolUtils.mjs +1 -1
- package/dist/utils/StringUtils.mjs +1 -1
- package/dist/utils/TimeUtils.mjs +1 -1
- package/dist/utils/UrlUtils.mjs +1 -1
- package/dist-browser/account/AccountInfo.mjs +1 -1
- package/dist-browser/account/AuthToken.mjs +1 -1
- package/dist-browser/account/CcsCredential.mjs +1 -1
- package/dist-browser/account/ClientInfo.mjs +1 -1
- package/dist-browser/account/TokenClaims.mjs +1 -1
- package/dist-browser/authority/Authority.mjs +1 -1
- package/dist-browser/authority/AuthorityFactory.mjs +1 -1
- package/dist-browser/authority/AuthorityMetadata.mjs +1 -1
- package/dist-browser/authority/AuthorityOptions.mjs +1 -1
- package/dist-browser/authority/AuthorityType.mjs +1 -1
- package/dist-browser/authority/CloudInstanceDiscoveryErrorResponse.mjs +1 -1
- package/dist-browser/authority/CloudInstanceDiscoveryResponse.mjs +1 -1
- package/dist-browser/authority/OpenIdConfigResponse.mjs +1 -1
- package/dist-browser/authority/ProtocolMode.mjs +1 -1
- package/dist-browser/authority/RegionDiscovery.mjs +1 -1
- package/dist-browser/cache/CacheManager.mjs +1 -1
- package/dist-browser/cache/persistence/TokenCacheContext.mjs +1 -1
- package/dist-browser/cache/utils/AccountEntityUtils.mjs +1 -1
- package/dist-browser/cache/utils/CacheHelpers.mjs +1 -1
- package/dist-browser/client/AuthorizationCodeClient.mjs +1 -1
- package/dist-browser/client/RefreshTokenClient.mjs +1 -1
- package/dist-browser/client/SilentFlowClient.mjs +1 -1
- package/dist-browser/config/ClientConfiguration.mjs +1 -1
- package/dist-browser/constants/AADServerParamKeys.mjs +1 -1
- package/dist-browser/crypto/ICrypto.mjs +1 -1
- package/dist-browser/crypto/JoseHeader.mjs +1 -1
- package/dist-browser/crypto/PopTokenGenerator.mjs +1 -1
- package/dist-browser/error/AuthError.mjs +1 -1
- package/dist-browser/error/AuthErrorCodes.mjs +1 -1
- package/dist-browser/error/CacheError.mjs +1 -1
- package/dist-browser/error/CacheErrorCodes.mjs +1 -1
- package/dist-browser/error/ClientAuthError.mjs +1 -1
- package/dist-browser/error/ClientAuthErrorCodes.mjs +1 -1
- package/dist-browser/error/ClientConfigurationError.mjs +1 -1
- package/dist-browser/error/ClientConfigurationErrorCodes.mjs +1 -1
- package/dist-browser/error/InteractionRequiredAuthError.mjs +1 -1
- package/dist-browser/error/InteractionRequiredAuthErrorCodes.mjs +1 -1
- package/dist-browser/error/JoseHeaderError.mjs +1 -1
- package/dist-browser/error/JoseHeaderErrorCodes.mjs +1 -1
- package/dist-browser/error/NetworkError.mjs +1 -1
- package/dist-browser/error/PlatformBrokerError.mjs +1 -1
- package/dist-browser/error/ServerError.mjs +1 -1
- package/dist-browser/index-browser.mjs +1 -1
- package/dist-browser/index.mjs +1 -1
- package/dist-browser/log-strings-mapping.json +7 -3
- package/dist-browser/logger/Logger.mjs +1 -1
- package/dist-browser/network/INetworkModule.mjs +1 -1
- package/dist-browser/network/RequestThumbprint.mjs +1 -1
- package/dist-browser/network/ThrottlingUtils.mjs +1 -1
- package/dist-browser/packageMetadata.d.ts +1 -1
- package/dist-browser/packageMetadata.mjs +2 -2
- package/dist-browser/protocol/Authorize.mjs +1 -1
- package/dist-browser/protocol/Token.mjs +1 -1
- package/dist-browser/request/AuthenticationHeaderParser.mjs +1 -1
- package/dist-browser/request/RequestParameterBuilder.mjs +1 -1
- package/dist-browser/request/ScopeSet.mjs +1 -1
- package/dist-browser/response/ResponseHandler.d.ts +9 -9
- package/dist-browser/response/ResponseHandler.d.ts.map +1 -1
- package/dist-browser/response/ResponseHandler.mjs +27 -20
- package/dist-browser/response/ResponseHandler.mjs.map +1 -1
- package/dist-browser/telemetry/performance/PerformanceClient.d.ts.map +1 -1
- package/dist-browser/telemetry/performance/PerformanceClient.mjs +59 -12
- package/dist-browser/telemetry/performance/PerformanceClient.mjs.map +1 -1
- package/dist-browser/telemetry/performance/PerformanceEvent.d.ts +94 -0
- package/dist-browser/telemetry/performance/PerformanceEvent.d.ts.map +1 -1
- package/dist-browser/telemetry/performance/PerformanceEvent.mjs +9 -2
- package/dist-browser/telemetry/performance/PerformanceEvent.mjs.map +1 -1
- package/dist-browser/telemetry/performance/PerformanceEvents.mjs +1 -1
- package/dist-browser/telemetry/performance/StubPerformanceClient.mjs +1 -1
- package/dist-browser/telemetry/server/ServerTelemetryManager.mjs +1 -1
- package/dist-browser/url/UrlString.mjs +1 -1
- package/dist-browser/utils/ClientAssertionUtils.mjs +1 -1
- package/dist-browser/utils/Constants.mjs +1 -1
- package/dist-browser/utils/FunctionWrappers.d.ts.map +1 -1
- package/dist-browser/utils/FunctionWrappers.mjs +3 -5
- package/dist-browser/utils/FunctionWrappers.mjs.map +1 -1
- package/dist-browser/utils/ProtocolUtils.mjs +1 -1
- package/dist-browser/utils/StringUtils.mjs +1 -1
- package/dist-browser/utils/TimeUtils.mjs +1 -1
- package/dist-browser/utils/UrlUtils.mjs +1 -1
- package/lib/index-browser.cjs +59 -12
- package/lib/index-browser.cjs.map +1 -1
- package/lib/{index-node-C4hhfREr.js → index-node-DualfPC3.js} +142 -129
- package/lib/index-node-DualfPC3.js.map +1 -0
- package/lib/index-node.cjs +2 -2
- package/lib/index.cjs +2 -2
- package/lib/types/packageMetadata.d.ts +1 -1
- package/lib/types/response/ResponseHandler.d.ts +9 -9
- package/lib/types/response/ResponseHandler.d.ts.map +1 -1
- package/lib/types/telemetry/performance/PerformanceClient.d.ts.map +1 -1
- package/lib/types/telemetry/performance/PerformanceEvent.d.ts +94 -0
- package/lib/types/telemetry/performance/PerformanceEvent.d.ts.map +1 -1
- package/lib/types/utils/FunctionWrappers.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/packageMetadata.ts +1 -1
- package/src/response/ResponseHandler.ts +67 -47
- package/src/telemetry/performance/PerformanceClient.ts +62 -10
- package/src/telemetry/performance/PerformanceEvent.ts +114 -0
- package/src/utils/FunctionWrappers.ts +8 -4
- package/lib/index-node-C4hhfREr.js.map +0 -1
|
@@ -243,6 +243,7 @@ export type PerformanceEvent = {
|
|
|
243
243
|
cacheRetentionDays?: number;
|
|
244
244
|
accountCachedBy?: string;
|
|
245
245
|
acntLoggedOut?: boolean;
|
|
246
|
+
cacheMatchedAccounts?: number;
|
|
246
247
|
cacheRtCount?: number;
|
|
247
248
|
cacheIdCount?: number;
|
|
248
249
|
cacheAtCount?: number;
|
|
@@ -261,6 +262,7 @@ export type PerformanceEvent = {
|
|
|
261
262
|
ntwkRtExpiresOnSeconds?: number;
|
|
262
263
|
extRtExpiresOnSeconds?: number;
|
|
263
264
|
rtOffsetSeconds?: number;
|
|
265
|
+
sidFromClaim?: boolean;
|
|
264
266
|
sidFromClaims?: boolean;
|
|
265
267
|
sidFromRequest?: boolean;
|
|
266
268
|
loginHintFromRequest?: boolean;
|
|
@@ -274,6 +276,26 @@ export type PerformanceEvent = {
|
|
|
274
276
|
navigateCallbackResult?: boolean;
|
|
275
277
|
dataBoundary?: DataBoundary;
|
|
276
278
|
logs?: string;
|
|
279
|
+
/**
|
|
280
|
+
* Source of cloud discovery metadata (config, cache, network, hardcoded_values)
|
|
281
|
+
*/
|
|
282
|
+
cloudDiscoverySource?: string;
|
|
283
|
+
/**
|
|
284
|
+
* Source of authority endpoint metadata (config, cache, network, hardcoded_values)
|
|
285
|
+
*/
|
|
286
|
+
authorityEndpointSource?: string;
|
|
287
|
+
/**
|
|
288
|
+
* Number of accounts removed during cache cleanup
|
|
289
|
+
*/
|
|
290
|
+
accountsRemoved?: number;
|
|
291
|
+
/**
|
|
292
|
+
* Number of access tokens removed during cache cleanup
|
|
293
|
+
*/
|
|
294
|
+
accessTokensRemoved?: number;
|
|
295
|
+
/**
|
|
296
|
+
* Number of failures when removing token binding keys
|
|
297
|
+
*/
|
|
298
|
+
removeTokenBindingKeyFailure?: number;
|
|
277
299
|
/**
|
|
278
300
|
* Reason for silent refresh fallback to iframe
|
|
279
301
|
* Format: errorCode or errorCode|subError
|
|
@@ -281,6 +303,72 @@ export type PerformanceEvent = {
|
|
|
281
303
|
* @type {?string}
|
|
282
304
|
*/
|
|
283
305
|
silentRefreshReason?: string;
|
|
306
|
+
/**
|
|
307
|
+
* Whether this request was deduped with another in-flight request
|
|
308
|
+
*/
|
|
309
|
+
deduped?: boolean;
|
|
310
|
+
/**
|
|
311
|
+
* Whether the user has "Keep Me Signed In" enabled
|
|
312
|
+
*/
|
|
313
|
+
kmsi?: boolean;
|
|
314
|
+
/**
|
|
315
|
+
* Whether this event was executed in the background
|
|
316
|
+
*/
|
|
317
|
+
isBackground?: boolean;
|
|
318
|
+
/**
|
|
319
|
+
* Cache migration telemetry — pre-migration counts
|
|
320
|
+
*/
|
|
321
|
+
preMigrateAcntCount?: number;
|
|
322
|
+
preMigrateATCount?: number;
|
|
323
|
+
preMigrateITCount?: number;
|
|
324
|
+
preMigrateRTCount?: number;
|
|
325
|
+
/**
|
|
326
|
+
* Cache migration telemetry — post-migration counts
|
|
327
|
+
*/
|
|
328
|
+
postMigrateAcntCount?: number;
|
|
329
|
+
postMigrateATCount?: number;
|
|
330
|
+
postMigrateITCount?: number;
|
|
331
|
+
postMigrateRTCount?: number;
|
|
332
|
+
/**
|
|
333
|
+
* Cache migration telemetry — old schema counts
|
|
334
|
+
*/
|
|
335
|
+
oldAcntCount?: number;
|
|
336
|
+
oldATCount?: number;
|
|
337
|
+
oldITCount?: number;
|
|
338
|
+
oldRTCount?: number;
|
|
339
|
+
/**
|
|
340
|
+
* Cache migration telemetry — skipped and migrated counts
|
|
341
|
+
*/
|
|
342
|
+
skipATMigrateCount?: number;
|
|
343
|
+
skipITMigrateCount?: number;
|
|
344
|
+
skipRTMigrateCount?: number;
|
|
345
|
+
migratedATCount?: number;
|
|
346
|
+
migratedITCount?: number;
|
|
347
|
+
migratedRTCount?: number;
|
|
348
|
+
/**
|
|
349
|
+
* Cache telemetry — expired, invalid, and removed counts
|
|
350
|
+
*/
|
|
351
|
+
expiredCacheRemovedCount?: number;
|
|
352
|
+
expiredAcntRemovedCount?: number;
|
|
353
|
+
invalidCacheCount?: number;
|
|
354
|
+
/**
|
|
355
|
+
* Encrypted cache telemetry
|
|
356
|
+
*/
|
|
357
|
+
unencryptedCacheCount?: number;
|
|
358
|
+
encryptedCacheCount?: number;
|
|
359
|
+
encryptedCacheExpiredCount?: number;
|
|
360
|
+
encryptedCacheCorruptionCount?: number;
|
|
361
|
+
/**
|
|
362
|
+
* Container for dynamically-named telemetry fields.
|
|
363
|
+
* Fields whose names are constructed at runtime (e.g., "[eventName]CallCount")
|
|
364
|
+
* should be stored here instead of being set as top-level properties.
|
|
365
|
+
* Use the "ext." prefix when calling addFields/incrementFields to automatically
|
|
366
|
+
* route fields to this sub-object.
|
|
367
|
+
*
|
|
368
|
+
* @remarks
|
|
369
|
+
* This property is typed as `Record<string, string | number>`.
|
|
370
|
+
*/
|
|
371
|
+
ext?: Record<string, string | number>;
|
|
284
372
|
};
|
|
285
373
|
export type PerformanceEventContext = {
|
|
286
374
|
dur?: number;
|
|
@@ -292,5 +380,11 @@ export type PerformanceEventStackedContext = PerformanceEventContext & {
|
|
|
292
380
|
name?: string;
|
|
293
381
|
childErr?: string;
|
|
294
382
|
};
|
|
383
|
+
/**
|
|
384
|
+
* Prefix used to mark telemetry field names as dynamic.
|
|
385
|
+
* Fields with this prefix in addFields/incrementFields calls will be routed
|
|
386
|
+
* to the PerformanceEvent.ext sub-object.
|
|
387
|
+
*/
|
|
388
|
+
export declare const EXT_FIELD_PREFIX = "ext.";
|
|
295
389
|
export declare const IntFields: ReadonlySet<string>;
|
|
296
390
|
//# sourceMappingURL=PerformanceEvent.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PerformanceEvent.d.ts","sourceRoot":"","sources":["../../../../src/telemetry/performance/PerformanceEvent.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,C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src/utils/FunctionWrappers.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAC7C,OAAO,EAAE,kBAAkB,EAAE,MAAM,gDAAgD,CAAC;AAEpF;;;;;;;;;;GAUG;AAEH,eAAO,MAAM,MAAM,+DAEJ,MAAM,UACT,MAAM,mBACG,kBAAkB,iBACpB,MAAM,
|
|
1
|
+
{"version":3,"file":"FunctionWrappers.d.ts","sourceRoot":"","sources":["../../../src/utils/FunctionWrappers.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAC7C,OAAO,EAAE,kBAAkB,EAAE,MAAM,gDAAgD,CAAC;AAEpF;;;;;;;;;;GAUG;AAEH,eAAO,MAAM,MAAM,+DAEJ,MAAM,UACT,MAAM,mBACG,kBAAkB,iBACpB,MAAM,sBAsCxB,CAAC;AAEF;;;;;;;;;;;GAWG;AAEH,eAAO,MAAM,WAAW,wEAET,MAAM,UACT,MAAM,mBACG,kBAAkB,iBACpB,MAAM,+BA6CxB,CAAC"}
|
package/package.json
CHANGED
package/src/packageMetadata.ts
CHANGED
|
@@ -3,36 +3,11 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import { ServerAuthorizationTokenResponse } from "./ServerAuthorizationTokenResponse.js";
|
|
7
|
-
import { ICrypto } from "../crypto/ICrypto.js";
|
|
8
6
|
import {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
import { ServerError } from "../error/ServerError.js";
|
|
14
|
-
import { ScopeSet } from "../request/ScopeSet.js";
|
|
15
|
-
import { AuthenticationResult } from "./AuthenticationResult.js";
|
|
16
|
-
import { AccountEntity } from "../cache/entities/AccountEntity.js";
|
|
17
|
-
import { Authority } from "../authority/Authority.js";
|
|
18
|
-
import { IdTokenEntity } from "../cache/entities/IdTokenEntity.js";
|
|
19
|
-
import { AccessTokenEntity } from "../cache/entities/AccessTokenEntity.js";
|
|
20
|
-
import { RefreshTokenEntity } from "../cache/entities/RefreshTokenEntity.js";
|
|
21
|
-
import {
|
|
22
|
-
InteractionRequiredAuthError,
|
|
23
|
-
isInteractionRequiredError,
|
|
24
|
-
} from "../error/InteractionRequiredAuthError.js";
|
|
25
|
-
import { CacheRecord } from "../cache/entities/CacheRecord.js";
|
|
26
|
-
import { CacheManager } from "../cache/CacheManager.js";
|
|
27
|
-
import * as ProtocolUtils from "../utils/ProtocolUtils.js";
|
|
28
|
-
import * as Constants from "../utils/Constants.js";
|
|
29
|
-
import { PopTokenGenerator } from "../crypto/PopTokenGenerator.js";
|
|
30
|
-
import { AppMetadataEntity } from "../cache/entities/AppMetadataEntity.js";
|
|
31
|
-
import { ICachePlugin } from "../cache/interface/ICachePlugin.js";
|
|
32
|
-
import { TokenCacheContext } from "../cache/persistence/TokenCacheContext.js";
|
|
33
|
-
import { ISerializableTokenCache } from "../cache/interface/ISerializableTokenCache.js";
|
|
34
|
-
import { AuthorizationCodePayload } from "./AuthorizationCodePayload.js";
|
|
35
|
-
import { BaseAuthRequest } from "../request/BaseAuthRequest.js";
|
|
7
|
+
AccountInfo,
|
|
8
|
+
buildTenantProfile,
|
|
9
|
+
updateAccountTenantProfileData,
|
|
10
|
+
} from "../account/AccountInfo.js";
|
|
36
11
|
import {
|
|
37
12
|
checkMaxAge,
|
|
38
13
|
extractTokenClaims,
|
|
@@ -42,16 +17,41 @@ import {
|
|
|
42
17
|
TokenClaims,
|
|
43
18
|
getTenantIdFromIdTokenClaims,
|
|
44
19
|
} from "../account/TokenClaims.js";
|
|
45
|
-
import {
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
} from "../
|
|
50
|
-
import
|
|
51
|
-
import
|
|
20
|
+
import { Authority } from "../authority/Authority.js";
|
|
21
|
+
import { CacheManager } from "../cache/CacheManager.js";
|
|
22
|
+
import { AccessTokenEntity } from "../cache/entities/AccessTokenEntity.js";
|
|
23
|
+
import { AccountEntity } from "../cache/entities/AccountEntity.js";
|
|
24
|
+
import { AppMetadataEntity } from "../cache/entities/AppMetadataEntity.js";
|
|
25
|
+
import { CacheRecord } from "../cache/entities/CacheRecord.js";
|
|
26
|
+
import { IdTokenEntity } from "../cache/entities/IdTokenEntity.js";
|
|
27
|
+
import { RefreshTokenEntity } from "../cache/entities/RefreshTokenEntity.js";
|
|
28
|
+
import { ICachePlugin } from "../cache/interface/ICachePlugin.js";
|
|
29
|
+
import { ISerializableTokenCache } from "../cache/interface/ISerializableTokenCache.js";
|
|
30
|
+
import { TokenCacheContext } from "../cache/persistence/TokenCacheContext.js";
|
|
52
31
|
import * as AccountEntityUtils from "../cache/utils/AccountEntityUtils.js";
|
|
32
|
+
import * as CacheHelpers from "../cache/utils/CacheHelpers.js";
|
|
33
|
+
import { ICrypto } from "../crypto/ICrypto.js";
|
|
34
|
+
import { PopTokenGenerator } from "../crypto/PopTokenGenerator.js";
|
|
35
|
+
import {
|
|
36
|
+
ClientAuthErrorCodes,
|
|
37
|
+
createClientAuthError,
|
|
38
|
+
} from "../error/ClientAuthError.js";
|
|
39
|
+
import {
|
|
40
|
+
InteractionRequiredAuthError,
|
|
41
|
+
isInteractionRequiredError,
|
|
42
|
+
} from "../error/InteractionRequiredAuthError.js";
|
|
43
|
+
import { ServerError } from "../error/ServerError.js";
|
|
44
|
+
import { Logger } from "../logger/Logger.js";
|
|
45
|
+
import { BaseAuthRequest } from "../request/BaseAuthRequest.js";
|
|
46
|
+
import { ScopeSet } from "../request/ScopeSet.js";
|
|
53
47
|
import { IPerformanceClient } from "../telemetry/performance/IPerformanceClient.js";
|
|
48
|
+
import * as Constants from "../utils/Constants.js";
|
|
49
|
+
import * as ProtocolUtils from "../utils/ProtocolUtils.js";
|
|
54
50
|
import { RequestStateObject } from "../utils/StateTypes.js";
|
|
51
|
+
import * as TimeUtils from "../utils/TimeUtils.js";
|
|
52
|
+
import { AuthenticationResult } from "./AuthenticationResult.js";
|
|
53
|
+
import { AuthorizationCodePayload } from "./AuthorizationCodePayload.js";
|
|
54
|
+
import { ServerAuthorizationTokenResponse } from "./ServerAuthorizationTokenResponse.js";
|
|
55
55
|
|
|
56
56
|
/**
|
|
57
57
|
* Class that handles response parsing.
|
|
@@ -398,7 +398,8 @@ export class ResponseHandler {
|
|
|
398
398
|
claimsTenantId,
|
|
399
399
|
authCodePayload,
|
|
400
400
|
undefined, // nativeAccountId
|
|
401
|
-
this.logger
|
|
401
|
+
this.logger,
|
|
402
|
+
this.performanceClient
|
|
402
403
|
);
|
|
403
404
|
}
|
|
404
405
|
|
|
@@ -638,21 +639,40 @@ export function buildAccountToCache(
|
|
|
638
639
|
claimsTenantId?: string | null,
|
|
639
640
|
authCodePayload?: AuthorizationCodePayload,
|
|
640
641
|
nativeAccountId?: string,
|
|
641
|
-
logger?: Logger
|
|
642
|
+
logger?: Logger,
|
|
643
|
+
performanceClient?: IPerformanceClient
|
|
642
644
|
): AccountEntity {
|
|
643
645
|
logger?.verbose("setCachedAccount called", correlationId);
|
|
644
646
|
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
647
|
+
/*
|
|
648
|
+
* Check if base account is already cached. Filter by homeAccountId (identifies
|
|
649
|
+
* the user's home identity) and environment (identifies the cloud) — the two
|
|
650
|
+
* tenant-agnostic properties that uniquely locate a base AccountEntity.
|
|
651
|
+
*/
|
|
652
|
+
const accountEnvironment = environment || authority.getPreferredCache();
|
|
653
|
+
const matchedAccounts = cacheStorage.getAccountsFilteredBy(
|
|
654
|
+
{ homeAccountId, environment: accountEnvironment },
|
|
655
|
+
correlationId
|
|
656
|
+
);
|
|
657
|
+
performanceClient?.addFields(
|
|
658
|
+
{ cacheMatchedAccounts: matchedAccounts.length },
|
|
659
|
+
correlationId
|
|
660
|
+
);
|
|
661
|
+
|
|
662
|
+
if (matchedAccounts.length > 1) {
|
|
663
|
+
/*
|
|
664
|
+
* Base accounts are expected to be unique for a given homeAccountId in normal cache usage.
|
|
665
|
+
* If multiple matches exist, ignore the cache hit rather than arbitrarily choosing one.
|
|
666
|
+
*/
|
|
667
|
+
logger?.warning(
|
|
668
|
+
"Multiple base accounts matched homeAccountId. Ignoring cached account and creating a new base account.",
|
|
669
|
+
correlationId
|
|
670
|
+
);
|
|
654
671
|
}
|
|
655
672
|
|
|
673
|
+
const cachedAccount =
|
|
674
|
+
matchedAccounts.length === 1 ? matchedAccounts[0] : null;
|
|
675
|
+
|
|
656
676
|
const baseAccount =
|
|
657
677
|
cachedAccount ||
|
|
658
678
|
AccountEntityUtils.createAccountEntity(
|
|
@@ -11,6 +11,7 @@ import {
|
|
|
11
11
|
PerformanceCallbackFunction,
|
|
12
12
|
} from "./IPerformanceClient.js";
|
|
13
13
|
import {
|
|
14
|
+
EXT_FIELD_PREFIX,
|
|
14
15
|
IntFields,
|
|
15
16
|
PerformanceEvent,
|
|
16
17
|
PerformanceEventContext,
|
|
@@ -453,9 +454,15 @@ export abstract class PerformanceClient implements IPerformanceClient {
|
|
|
453
454
|
addError(error, this.logger, rootEvent);
|
|
454
455
|
}
|
|
455
456
|
|
|
456
|
-
// Add sub-measurement attribute to root event.
|
|
457
|
+
// Add sub-measurement attribute to root event's ext field.
|
|
457
458
|
if (!isRoot) {
|
|
458
|
-
rootEvent
|
|
459
|
+
rootEvent.ext = {
|
|
460
|
+
...rootEvent.ext,
|
|
461
|
+
...event.ext,
|
|
462
|
+
};
|
|
463
|
+
rootEvent.ext[event.name + "DurationMs"] = Math.floor(
|
|
464
|
+
event.durationMs
|
|
465
|
+
);
|
|
459
466
|
return { ...rootEvent };
|
|
460
467
|
}
|
|
461
468
|
|
|
@@ -521,10 +528,36 @@ export abstract class PerformanceClient implements IPerformanceClient {
|
|
|
521
528
|
): void {
|
|
522
529
|
const event = this.eventsByCorrelationId.get(correlationId);
|
|
523
530
|
if (event) {
|
|
524
|
-
|
|
531
|
+
const staticFields: { [key: string]: {} | undefined } = {};
|
|
532
|
+
const dynamicFields: Record<string, string | number> = {};
|
|
533
|
+
|
|
534
|
+
for (const key in fields) {
|
|
535
|
+
if (key.startsWith(EXT_FIELD_PREFIX)) {
|
|
536
|
+
const dynamicKey = key.slice(EXT_FIELD_PREFIX.length);
|
|
537
|
+
const value = fields[key];
|
|
538
|
+
if (
|
|
539
|
+
typeof value === "string" ||
|
|
540
|
+
typeof value === "number"
|
|
541
|
+
) {
|
|
542
|
+
dynamicFields[dynamicKey] = value;
|
|
543
|
+
}
|
|
544
|
+
} else {
|
|
545
|
+
staticFields[key] = fields[key];
|
|
546
|
+
}
|
|
547
|
+
}
|
|
548
|
+
|
|
549
|
+
const updatedEvent: PerformanceEvent = {
|
|
525
550
|
...event,
|
|
526
|
-
...
|
|
527
|
-
}
|
|
551
|
+
...staticFields,
|
|
552
|
+
};
|
|
553
|
+
if (Object.keys(dynamicFields).length) {
|
|
554
|
+
updatedEvent.ext = {
|
|
555
|
+
...updatedEvent.ext,
|
|
556
|
+
...dynamicFields,
|
|
557
|
+
};
|
|
558
|
+
}
|
|
559
|
+
|
|
560
|
+
this.eventsByCorrelationId.set(correlationId, updatedEvent);
|
|
528
561
|
} else {
|
|
529
562
|
this.logger.trace(
|
|
530
563
|
"PerformanceClient: Event not found for",
|
|
@@ -545,12 +578,29 @@ export abstract class PerformanceClient implements IPerformanceClient {
|
|
|
545
578
|
const event = this.eventsByCorrelationId.get(correlationId);
|
|
546
579
|
if (event) {
|
|
547
580
|
for (const counter in fields) {
|
|
548
|
-
if (
|
|
549
|
-
event
|
|
550
|
-
|
|
551
|
-
|
|
581
|
+
if (counter.startsWith(EXT_FIELD_PREFIX)) {
|
|
582
|
+
event.ext = event.ext || {};
|
|
583
|
+
// Route to ext sub-object
|
|
584
|
+
const dynamicKey = counter.slice(EXT_FIELD_PREFIX.length);
|
|
585
|
+
const currentValue = event.ext[dynamicKey];
|
|
586
|
+
if (currentValue === undefined) {
|
|
587
|
+
event.ext[dynamicKey] = 0;
|
|
588
|
+
} else if (isNaN(Number(currentValue))) {
|
|
589
|
+
return;
|
|
590
|
+
}
|
|
591
|
+
event.ext[dynamicKey] =
|
|
592
|
+
(Number(event.ext[dynamicKey]) || 0) +
|
|
593
|
+
(fields[counter] ?? 0);
|
|
594
|
+
} else {
|
|
595
|
+
/* eslint-disable custom-msal/no-dynamic-telemetry-fields -- internal dispatching of static fields by name */
|
|
596
|
+
if (!event.hasOwnProperty(counter)) {
|
|
597
|
+
event[counter] = 0;
|
|
598
|
+
} else if (isNaN(Number(event[counter]))) {
|
|
599
|
+
return;
|
|
600
|
+
}
|
|
601
|
+
event[counter] += fields[counter];
|
|
602
|
+
/* eslint-enable custom-msal/no-dynamic-telemetry-fields */
|
|
552
603
|
}
|
|
553
|
-
event[counter] += fields[counter];
|
|
554
604
|
}
|
|
555
605
|
} else {
|
|
556
606
|
this.logger.trace(
|
|
@@ -674,9 +724,11 @@ export abstract class PerformanceClient implements IPerformanceClient {
|
|
|
674
724
|
*/
|
|
675
725
|
private truncateIntegralFields(event: PerformanceEvent): void {
|
|
676
726
|
this.intFields.forEach((key) => {
|
|
727
|
+
/* eslint-disable custom-msal/no-dynamic-telemetry-fields -- internal truncation of known integer fields */
|
|
677
728
|
if (key in event && typeof event[key] === "number") {
|
|
678
729
|
event[key] = Math.floor(event[key]);
|
|
679
730
|
}
|
|
731
|
+
/* eslint-enable custom-msal/no-dynamic-telemetry-fields */
|
|
680
732
|
});
|
|
681
733
|
}
|
|
682
734
|
|
|
@@ -294,6 +294,9 @@ export type PerformanceEvent = {
|
|
|
294
294
|
accountCachedBy?: string;
|
|
295
295
|
acntLoggedOut?: boolean;
|
|
296
296
|
|
|
297
|
+
// Number of cached accounts matched by homeAccountId in buildAccountToCache
|
|
298
|
+
cacheMatchedAccounts?: number;
|
|
299
|
+
|
|
297
300
|
// Number of tokens in the cache to be reported when cache quota is exceeded
|
|
298
301
|
cacheRtCount?: number;
|
|
299
302
|
cacheIdCount?: number;
|
|
@@ -321,6 +324,8 @@ export type PerformanceEvent = {
|
|
|
321
324
|
extRtExpiresOnSeconds?: number;
|
|
322
325
|
rtOffsetSeconds?: number;
|
|
323
326
|
|
|
327
|
+
sidFromClaim?: boolean;
|
|
328
|
+
// Backward-compatible alias for sidFromClaim
|
|
324
329
|
sidFromClaims?: boolean;
|
|
325
330
|
sidFromRequest?: boolean;
|
|
326
331
|
loginHintFromRequest?: boolean;
|
|
@@ -344,6 +349,31 @@ export type PerformanceEvent = {
|
|
|
344
349
|
// Hashed logs in the format [millis1,hash1;millis2,hash2;...]
|
|
345
350
|
logs?: string;
|
|
346
351
|
|
|
352
|
+
/**
|
|
353
|
+
* Source of cloud discovery metadata (config, cache, network, hardcoded_values)
|
|
354
|
+
*/
|
|
355
|
+
cloudDiscoverySource?: string;
|
|
356
|
+
|
|
357
|
+
/**
|
|
358
|
+
* Source of authority endpoint metadata (config, cache, network, hardcoded_values)
|
|
359
|
+
*/
|
|
360
|
+
authorityEndpointSource?: string;
|
|
361
|
+
|
|
362
|
+
/**
|
|
363
|
+
* Number of accounts removed during cache cleanup
|
|
364
|
+
*/
|
|
365
|
+
accountsRemoved?: number;
|
|
366
|
+
|
|
367
|
+
/**
|
|
368
|
+
* Number of access tokens removed during cache cleanup
|
|
369
|
+
*/
|
|
370
|
+
accessTokensRemoved?: number;
|
|
371
|
+
|
|
372
|
+
/**
|
|
373
|
+
* Number of failures when removing token binding keys
|
|
374
|
+
*/
|
|
375
|
+
removeTokenBindingKeyFailure?: number;
|
|
376
|
+
|
|
347
377
|
/**
|
|
348
378
|
* Reason for silent refresh fallback to iframe
|
|
349
379
|
* Format: errorCode or errorCode|subError
|
|
@@ -351,6 +381,82 @@ export type PerformanceEvent = {
|
|
|
351
381
|
* @type {?string}
|
|
352
382
|
*/
|
|
353
383
|
silentRefreshReason?: string;
|
|
384
|
+
|
|
385
|
+
/**
|
|
386
|
+
* Whether this request was deduped with another in-flight request
|
|
387
|
+
*/
|
|
388
|
+
deduped?: boolean;
|
|
389
|
+
|
|
390
|
+
/**
|
|
391
|
+
* Whether the user has "Keep Me Signed In" enabled
|
|
392
|
+
*/
|
|
393
|
+
kmsi?: boolean;
|
|
394
|
+
|
|
395
|
+
/**
|
|
396
|
+
* Whether this event was executed in the background
|
|
397
|
+
*/
|
|
398
|
+
isBackground?: boolean;
|
|
399
|
+
|
|
400
|
+
/**
|
|
401
|
+
* Cache migration telemetry — pre-migration counts
|
|
402
|
+
*/
|
|
403
|
+
preMigrateAcntCount?: number;
|
|
404
|
+
preMigrateATCount?: number;
|
|
405
|
+
preMigrateITCount?: number;
|
|
406
|
+
preMigrateRTCount?: number;
|
|
407
|
+
|
|
408
|
+
/**
|
|
409
|
+
* Cache migration telemetry — post-migration counts
|
|
410
|
+
*/
|
|
411
|
+
postMigrateAcntCount?: number;
|
|
412
|
+
postMigrateATCount?: number;
|
|
413
|
+
postMigrateITCount?: number;
|
|
414
|
+
postMigrateRTCount?: number;
|
|
415
|
+
|
|
416
|
+
/**
|
|
417
|
+
* Cache migration telemetry — old schema counts
|
|
418
|
+
*/
|
|
419
|
+
oldAcntCount?: number;
|
|
420
|
+
oldATCount?: number;
|
|
421
|
+
oldITCount?: number;
|
|
422
|
+
oldRTCount?: number;
|
|
423
|
+
|
|
424
|
+
/**
|
|
425
|
+
* Cache migration telemetry — skipped and migrated counts
|
|
426
|
+
*/
|
|
427
|
+
skipATMigrateCount?: number;
|
|
428
|
+
skipITMigrateCount?: number;
|
|
429
|
+
skipRTMigrateCount?: number;
|
|
430
|
+
migratedATCount?: number;
|
|
431
|
+
migratedITCount?: number;
|
|
432
|
+
migratedRTCount?: number;
|
|
433
|
+
|
|
434
|
+
/**
|
|
435
|
+
* Cache telemetry — expired, invalid, and removed counts
|
|
436
|
+
*/
|
|
437
|
+
expiredCacheRemovedCount?: number;
|
|
438
|
+
expiredAcntRemovedCount?: number;
|
|
439
|
+
invalidCacheCount?: number;
|
|
440
|
+
|
|
441
|
+
/**
|
|
442
|
+
* Encrypted cache telemetry
|
|
443
|
+
*/
|
|
444
|
+
unencryptedCacheCount?: number;
|
|
445
|
+
encryptedCacheCount?: number;
|
|
446
|
+
encryptedCacheExpiredCount?: number;
|
|
447
|
+
encryptedCacheCorruptionCount?: number;
|
|
448
|
+
|
|
449
|
+
/**
|
|
450
|
+
* Container for dynamically-named telemetry fields.
|
|
451
|
+
* Fields whose names are constructed at runtime (e.g., "[eventName]CallCount")
|
|
452
|
+
* should be stored here instead of being set as top-level properties.
|
|
453
|
+
* Use the "ext." prefix when calling addFields/incrementFields to automatically
|
|
454
|
+
* route fields to this sub-object.
|
|
455
|
+
*
|
|
456
|
+
* @remarks
|
|
457
|
+
* This property is typed as `Record<string, string | number>`.
|
|
458
|
+
*/
|
|
459
|
+
ext?: Record<string, string | number>;
|
|
354
460
|
};
|
|
355
461
|
|
|
356
462
|
export type PerformanceEventContext = {
|
|
@@ -365,6 +471,13 @@ export type PerformanceEventStackedContext = PerformanceEventContext & {
|
|
|
365
471
|
childErr?: string;
|
|
366
472
|
};
|
|
367
473
|
|
|
474
|
+
/**
|
|
475
|
+
* Prefix used to mark telemetry field names as dynamic.
|
|
476
|
+
* Fields with this prefix in addFields/incrementFields calls will be routed
|
|
477
|
+
* to the PerformanceEvent.ext sub-object.
|
|
478
|
+
*/
|
|
479
|
+
export const EXT_FIELD_PREFIX = "ext.";
|
|
480
|
+
|
|
368
481
|
export const IntFields: ReadonlySet<string> = new Set([
|
|
369
482
|
"accessTokenSize",
|
|
370
483
|
"durationMs",
|
|
@@ -389,4 +502,5 @@ export const IntFields: ReadonlySet<string> = new Set([
|
|
|
389
502
|
"currRefreshCount",
|
|
390
503
|
"expiredCacheRemovedCount",
|
|
391
504
|
"upgradedCacheCount",
|
|
505
|
+
"cacheMatchedAccounts",
|
|
392
506
|
]);
|
|
@@ -33,8 +33,10 @@ export const invoke = <T extends Array<any>, U>(
|
|
|
33
33
|
);
|
|
34
34
|
if (correlationId) {
|
|
35
35
|
// Track number of times this API is called in a single request
|
|
36
|
-
|
|
37
|
-
|
|
36
|
+
telemetryClient.incrementFields(
|
|
37
|
+
{ [`ext.${eventName}CallCount`]: 1 },
|
|
38
|
+
correlationId
|
|
39
|
+
);
|
|
38
40
|
}
|
|
39
41
|
try {
|
|
40
42
|
const result = callback(...args);
|
|
@@ -89,8 +91,10 @@ export const invokeAsync = <T extends Array<any>, U>(
|
|
|
89
91
|
);
|
|
90
92
|
if (correlationId) {
|
|
91
93
|
// Track number of times this API is called in a single request
|
|
92
|
-
|
|
93
|
-
|
|
94
|
+
telemetryClient.incrementFields(
|
|
95
|
+
{ [`ext.${eventName}CallCount`]: 1 },
|
|
96
|
+
correlationId
|
|
97
|
+
);
|
|
94
98
|
}
|
|
95
99
|
return callback(...args)
|
|
96
100
|
.then((response) => {
|