opencode-m365-copilot 0.2.1 → 0.3.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.
@@ -1,9 +1,9 @@
1
- import { E as __toESM, T as __require, w as __commonJSMin } from "./server-DDD-Hlhx.mjs";
1
+ import { A as __require, j as __toESM, k as __commonJSMin } from "./server-DuHBfcPQ.mjs";
2
2
  import { randomUUID } from "node:crypto";
3
3
  import http from "http";
4
4
  import crypto, { createHash as createHash$1 } from "crypto";
5
5
  //#region node_modules/@azure/msal-node/dist/cache/serializer/Serializer.mjs
6
- /*! @azure/msal-node v5.5.0 2026-08-04 */
6
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
7
7
  /**
8
8
  * This class serializes cache entities to be saved into in-memory object types defined internally
9
9
  * @internal
@@ -143,7 +143,7 @@ var Serializer = class {
143
143
  };
144
144
  //#endregion
145
145
  //#region node_modules/@azure/msal-common/dist/constants/AADServerParamKeys.mjs
146
- /*! @azure/msal-common v16.12.0 2026-08-04 */
146
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
147
147
  const CLIENT_ID = "client_id";
148
148
  const REDIRECT_URI = "redirect_uri";
149
149
  const RESPONSE_TYPE = "response_type";
@@ -190,13 +190,12 @@ const CLI_DATA = "clidata";
190
190
  const ATTRIBUTE_TOKENS = "attribute_tokens";
191
191
  //#endregion
192
192
  //#region node_modules/@azure/msal-common/dist/utils/Constants.mjs
193
- /*! @azure/msal-common v16.12.0 2026-08-04 */
193
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
194
194
  const SKU = "msal.js.common";
195
195
  const DEFAULT_AUTHORITY = "https://login.microsoftonline.com/common/";
196
196
  const DEFAULT_AUTHORITY_HOST = "login.microsoftonline.com";
197
197
  const DEFAULT_COMMON_TENANT = "common";
198
198
  const ADFS = "adfs";
199
- const DSTS = "dstsv2";
200
199
  const AAD_INSTANCE_DISCOVERY_ENDPT = `${DEFAULT_AUTHORITY}discovery/instance?api-version=1.1&authorization_endpoint=`;
201
200
  const CIAM_AUTH_URL = ".ciamlogin.com";
202
201
  const AAD_TENANT_DOMAIN_SUFFIX = ".onmicrosoft.com";
@@ -227,6 +226,7 @@ const OIDC_SCOPES = [...OIDC_DEFAULT_SCOPES, EMAIL_SCOPE];
227
226
  const HeaderNames = {
228
227
  CONTENT_TYPE: "Content-Type",
229
228
  CONTENT_LENGTH: "Content-Length",
229
+ DPOP: "DPoP",
230
230
  RETRY_AFTER: "Retry-After",
231
231
  CCS_HEADER: "X-AnchorMailbox",
232
232
  WWWAuthenticate: "WWW-Authenticate",
@@ -250,7 +250,8 @@ const ClaimsRequestKeys = {
250
250
  XMS_CC: "xms_cc",
251
251
  ID_TOKEN: "id_token",
252
252
  SIGNIN_STATE: "signin_state",
253
- LOGIN_HINT: "login_hint"
253
+ LOGIN_HINT: "login_hint",
254
+ TENANT_REGION_SUB_SCOPE: "tenant_region_sub_scope"
254
255
  };
255
256
  /**
256
257
  * we considered making this "enum" in the request instead of string, however it looks like the allowed list of
@@ -337,6 +338,7 @@ const SERVER_TELEM_UNKNOWN_ERROR = "unknown_error";
337
338
  const AuthenticationScheme = {
338
339
  BEARER: "Bearer",
339
340
  POP: "pop",
341
+ DPOP: "DPoP",
340
342
  SSH: "ssh-cert"
341
343
  };
342
344
  const DEFAULT_MAX_THROTTLE_TIME_SECONDS = 3600;
@@ -378,6 +380,12 @@ const CacheOutcome = {
378
380
  CACHED_ACCESS_TOKEN_EXPIRED: "3",
379
381
  PROACTIVELY_REFRESHED: "4"
380
382
  };
383
+ const JsonWebTokenTypes = {
384
+ Jwt: "JWT",
385
+ Jwk: "JWK",
386
+ Pop: "pop",
387
+ Dpop: "dpop+jwt"
388
+ };
381
389
  const EncodingTypes = {
382
390
  BASE64: "base64",
383
391
  HEX: "hex",
@@ -385,7 +393,7 @@ const EncodingTypes = {
385
393
  };
386
394
  //#endregion
387
395
  //#region node_modules/@azure/msal-common/dist/error/AuthError.mjs
388
- /*! @azure/msal-common v16.12.0 2026-08-04 */
396
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
389
397
  function getDefaultErrorMessage(code) {
390
398
  return `See https://aka.ms/msal.js.errors#${code} for details`;
391
399
  }
@@ -410,7 +418,7 @@ function createAuthError(code, correlationId, additionalMessage) {
410
418
  }
411
419
  //#endregion
412
420
  //#region node_modules/@azure/msal-common/dist/error/ClientAuthError.mjs
413
- /*! @azure/msal-common v16.12.0 2026-08-04 */
421
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
414
422
  /**
415
423
  * ClientAuthErrorMessage class containing string constants used by error codes and messages.
416
424
  */
@@ -429,7 +437,7 @@ function createClientAuthError(errorCode, correlationId, additionalMessage) {
429
437
  }
430
438
  //#endregion
431
439
  //#region node_modules/@azure/msal-common/dist/error/ClientAuthErrorCodes.mjs
432
- /*! @azure/msal-common v16.12.0 2026-08-04 */
440
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
433
441
  const clientInfoDecodingError = "client_info_decoding_error";
434
442
  const clientInfoEmptyError = "client_info_empty_error";
435
443
  const tokenParsingError = "token_parsing_error";
@@ -450,6 +458,7 @@ const noAccountInSilentRequest = "no_account_in_silent_request";
450
458
  const invalidCacheRecord = "invalid_cache_record";
451
459
  const invalidCacheEnvironment = "invalid_cache_environment";
452
460
  const noCryptoObject = "no_crypto_object";
461
+ const dpopTokenTypeMismatch = "dpop_token_type_mismatch";
453
462
  const tokenRefreshRequired = "token_refresh_required";
454
463
  const tokenClaimsCnfRequiredForSignedJwt = "token_claims_cnf_required_for_signedjwt";
455
464
  const endSessionEndpointNotSupported = "end_session_endpoint_not_supported";
@@ -459,7 +468,7 @@ const resourceParameterRequired = "resource_parameter_required";
459
468
  const misplacedResourceParam = "misplaced_resource_parameter";
460
469
  //#endregion
461
470
  //#region node_modules/@azure/msal-common/dist/account/ClientInfo.mjs
462
- /*! @azure/msal-common v16.12.0 2026-08-04 */
471
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
463
472
  /**
464
473
  * Function to build a client info object from server clientInfo string
465
474
  * @param rawClientInfo
@@ -488,7 +497,7 @@ function buildClientInfoFromHomeAccountId(homeAccountId) {
488
497
  }
489
498
  //#endregion
490
499
  //#region node_modules/@azure/msal-common/dist/account/AuthToken.mjs
491
- /*! @azure/msal-common v16.12.0 2026-08-04 */
500
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
492
501
  /**
493
502
  * Extract token by decoding the rawToken
494
503
  *
@@ -540,7 +549,7 @@ function getJWSPayload(authToken, correlationId) {
540
549
  }
541
550
  //#endregion
542
551
  //#region node_modules/@azure/msal-common/dist/account/AccountInfo.mjs
543
- /*! @azure/msal-common v16.12.0 2026-08-04 */
552
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
544
553
  /**
545
554
  * Returns true if tenantId matches the utid portion of homeAccountId
546
555
  * @param tenantId
@@ -617,19 +626,18 @@ function updateAccountTenantProfileData(baseAccountInfo, tenantProfile, idTokenC
617
626
  }
618
627
  //#endregion
619
628
  //#region node_modules/@azure/msal-common/dist/authority/AuthorityType.mjs
620
- /*! @azure/msal-common v16.12.0 2026-08-04 */
629
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
621
630
  /**
622
631
  * Authority types supported by MSAL.
623
632
  */
624
633
  const AuthorityType = {
625
634
  Default: 0,
626
635
  Adfs: 1,
627
- Dsts: 2,
628
636
  Ciam: 3
629
637
  };
630
638
  //#endregion
631
639
  //#region node_modules/@azure/msal-common/dist/account/TokenClaims.mjs
632
- /*! @azure/msal-common v16.12.0 2026-08-04 */
640
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
633
641
  /**
634
642
  * Gets tenantId from available ID token claims to set as credential realm with the following precedence:
635
643
  * 1. tid - if the token is acquired from an Azure AD tenant tid will be present
@@ -645,7 +653,7 @@ function getTenantIdFromIdTokenClaims(idTokenClaims) {
645
653
  }
646
654
  //#endregion
647
655
  //#region node_modules/@azure/msal-common/dist/authority/ProtocolMode.mjs
648
- /*! @azure/msal-common v16.12.0 2026-08-04 */
656
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
649
657
  /**
650
658
  * Protocol modes supported by MSAL.
651
659
  */
@@ -666,7 +674,7 @@ const ProtocolMode = {
666
674
  };
667
675
  //#endregion
668
676
  //#region node_modules/@azure/msal-common/dist/cache/utils/AccountEntityUtils.mjs
669
- /*! @azure/msal-common v16.12.0 2026-08-04 */
677
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
670
678
  /**
671
679
  * Returns the AccountInfo interface for this account.
672
680
  * @internal
@@ -743,7 +751,7 @@ function createAccountEntity(accountDetails, authority, correlationId, base64Dec
743
751
  * @param authType
744
752
  */
745
753
  function generateHomeAccountId(serverClientInfo, authType, logger, cryptoObj, correlationId, idTokenClaims) {
746
- if (!(authType === AuthorityType.Adfs || authType === AuthorityType.Dsts)) {
754
+ if (authType !== AuthorityType.Adfs) {
747
755
  if (serverClientInfo) try {
748
756
  const clientInfo = buildClientInfo(serverClientInfo, cryptoObj.base64Decode);
749
757
  if (clientInfo.uid && clientInfo.utid) return `${clientInfo.uid}.${clientInfo.utid}`;
@@ -763,11 +771,11 @@ function isAccountEntity(entity) {
763
771
  }
764
772
  //#endregion
765
773
  //#region node_modules/@azure/msal-common/dist/error/AuthErrorCodes.mjs
766
- /*! @azure/msal-common v16.12.0 2026-08-04 */
774
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
767
775
  const postRequestFailed = "post_request_failed";
768
776
  //#endregion
769
777
  //#region node_modules/@azure/msal-common/dist/error/ClientConfigurationError.mjs
770
- /*! @azure/msal-common v16.12.0 2026-08-04 */
778
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
771
779
  /**
772
780
  * Error thrown when there is an error in configuration of the MSAL.js library.
773
781
  */
@@ -783,7 +791,7 @@ function createClientConfigurationError(errorCode, correlationId) {
783
791
  }
784
792
  //#endregion
785
793
  //#region node_modules/@azure/msal-common/dist/error/ClientConfigurationErrorCodes.mjs
786
- /*! @azure/msal-common v16.12.0 2026-08-04 */
794
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
787
795
  const redirectUriEmpty = "redirect_uri_empty";
788
796
  const authorityUriInsecure = "authority_uri_insecure";
789
797
  const urlParseError = "url_parse_error";
@@ -799,15 +807,19 @@ const untrustedAuthority = "untrusted_authority";
799
807
  const missingSshJwk = "missing_ssh_jwk";
800
808
  const issuerValidationFailed = "issuer_validation_failed";
801
809
  const invalidResponseMode = "invalid_response_mode";
810
+ const invalidDpopHtm = "invalid_dpop_htm";
811
+ const invalidDpopHtu = "invalid_dpop_htu";
812
+ const invalidDpopNonce = "invalid_dpop_nonce";
813
+ const dpopMissingResourceContext = "dpop_missing_resource_context";
802
814
  //#endregion
803
815
  //#region node_modules/@azure/msal-common/dist/authority/OpenIdConfigResponse.mjs
804
- /*! @azure/msal-common v16.12.0 2026-08-04 */
816
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
805
817
  function isOpenIdConfigResponse(response) {
806
818
  return response.hasOwnProperty("authorization_endpoint") && response.hasOwnProperty("token_endpoint") && response.hasOwnProperty("issuer") && response.hasOwnProperty("jwks_uri");
807
819
  }
808
820
  //#endregion
809
821
  //#region node_modules/@azure/msal-common/dist/utils/StringUtils.mjs
810
- /*! @azure/msal-common v16.12.0 2026-08-04 */
822
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
811
823
  /**
812
824
  * @hidden
813
825
  */
@@ -877,7 +889,7 @@ var StringUtils = class {
877
889
  };
878
890
  //#endregion
879
891
  //#region node_modules/@azure/msal-common/dist/url/UrlString.mjs
880
- /*! @azure/msal-common v16.12.0 2026-08-04 */
892
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
881
893
  /**
882
894
  * Url object class which can perform various transformations on url strings.
883
895
  */
@@ -984,13 +996,10 @@ var UrlString = class UrlString {
984
996
  };
985
997
  //#endregion
986
998
  //#region node_modules/@azure/msal-common/dist/authority/AuthorityMetadata.mjs
987
- /*! @azure/msal-common v16.12.0 2026-08-04 */
999
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
988
1000
  const endpointHosts = [
989
1001
  { host: "login.microsoftonline.com" },
990
- {
991
- host: "login.chinacloudapi.cn",
992
- issuerHost: "login.partner.microsoftonline.cn"
993
- },
1002
+ { host: "login.partner.microsoftonline.cn" },
994
1003
  { host: "login.microsoftonline.us" },
995
1004
  { host: "login.sovcloud-identity.fr" },
996
1005
  { host: "login.sovcloud-identity.de" },
@@ -1055,15 +1064,6 @@ const rawMetdataJSON = {
1055
1064
  preferred_network: "login.sovcloud-identity.sg",
1056
1065
  preferred_cache: "login.sovcloud-identity.sg",
1057
1066
  aliases: ["login.sovcloud-identity.sg"]
1058
- },
1059
- {
1060
- preferred_network: "login.windows-ppe.net",
1061
- preferred_cache: "login.windows-ppe.net",
1062
- aliases: [
1063
- "login.windows-ppe.net",
1064
- "sts.windows-ppe.net",
1065
- "login.microsoft-ppe.com"
1066
- ]
1067
1067
  }
1068
1068
  ] }
1069
1069
  };
@@ -1127,30 +1127,29 @@ function getCloudDiscoveryMetadataFromNetworkResponse(response, authorityHost) {
1127
1127
  }
1128
1128
  //#endregion
1129
1129
  //#region node_modules/@azure/msal-common/dist/authority/AuthorityOptions.mjs
1130
- /*! @azure/msal-common v16.12.0 2026-08-04 */
1130
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
1131
1131
  const AzureCloudInstance = {
1132
1132
  None: "none",
1133
1133
  AzurePublic: "https://login.microsoftonline.com",
1134
- AzurePpe: "https://login.windows-ppe.net",
1135
1134
  AzureChina: "https://login.chinacloudapi.cn",
1136
1135
  AzureGermany: "https://login.microsoftonline.de",
1137
1136
  AzureUsGovernment: "https://login.microsoftonline.us"
1138
1137
  };
1139
1138
  //#endregion
1140
1139
  //#region node_modules/@azure/msal-common/dist/authority/CloudInstanceDiscoveryResponse.mjs
1141
- /*! @azure/msal-common v16.12.0 2026-08-04 */
1140
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
1142
1141
  function isCloudInstanceDiscoveryResponse(response) {
1143
1142
  return response.hasOwnProperty("tenant_discovery_endpoint") && response.hasOwnProperty("metadata");
1144
1143
  }
1145
1144
  //#endregion
1146
1145
  //#region node_modules/@azure/msal-common/dist/authority/CloudInstanceDiscoveryErrorResponse.mjs
1147
- /*! @azure/msal-common v16.12.0 2026-08-04 */
1146
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
1148
1147
  function isCloudInstanceDiscoveryErrorResponse(response) {
1149
1148
  return response.hasOwnProperty("error") && response.hasOwnProperty("error_description");
1150
1149
  }
1151
1150
  //#endregion
1152
1151
  //#region node_modules/@azure/msal-common/dist/telemetry/performance/PerformanceEvents.mjs
1153
- /*! @azure/msal-common v16.12.0 2026-08-04 */
1152
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
1154
1153
  /**
1155
1154
  * Time spent sending/waiting for the response of a request to the token endpoint
1156
1155
  */
@@ -1209,7 +1208,7 @@ const RegionDiscoveryGetCurrentVersion = "regionDiscoveryGetCurrentVersion";
1209
1208
  const CacheManagerGetRefreshToken = "cacheManagerGetRefreshToken";
1210
1209
  //#endregion
1211
1210
  //#region node_modules/@azure/msal-common/dist/utils/FunctionWrappers.mjs
1212
- /*! @azure/msal-common v16.12.0 2026-08-04 */
1211
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
1213
1212
  /**
1214
1213
  * Wraps a function with a performance measurement.
1215
1214
  * Usage: invoke(functionToCall, performanceClient, "EventName", "correlationId")(...argsToPassToFunction)
@@ -1278,7 +1277,7 @@ const invokeAsync = (callback, eventName, logger, telemetryClient, correlationId
1278
1277
  };
1279
1278
  //#endregion
1280
1279
  //#region node_modules/@azure/msal-common/dist/authority/RegionDiscovery.mjs
1281
- /*! @azure/msal-common v16.12.0 2026-08-04 */
1280
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
1282
1281
  var RegionDiscovery = class RegionDiscovery {
1283
1282
  constructor(networkInterface, logger, performanceClient, correlationId) {
1284
1283
  this.networkInterface = networkInterface;
@@ -1349,7 +1348,7 @@ var RegionDiscovery = class RegionDiscovery {
1349
1348
  RegionDiscovery.IMDS_OPTIONS = { headers: { Metadata: "true" } };
1350
1349
  //#endregion
1351
1350
  //#region node_modules/@azure/msal-common/dist/utils/TimeUtils.mjs
1352
- /*! @azure/msal-common v16.12.0 2026-08-04 */
1351
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
1353
1352
  /**
1354
1353
  * Utility functions for managing date and time operations.
1355
1354
  */
@@ -1394,7 +1393,7 @@ function delay(t, value) {
1394
1393
  }
1395
1394
  //#endregion
1396
1395
  //#region node_modules/@azure/msal-common/dist/cache/utils/CacheHelpers.mjs
1397
- /*! @azure/msal-common v16.12.0 2026-08-04 */
1396
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
1398
1397
  /**
1399
1398
  * Create IdTokenEntity
1400
1399
  * @param homeAccountId
@@ -1441,14 +1440,19 @@ function createAccessTokenEntity(homeAccountId, environment, accessToken, client
1441
1440
  };
1442
1441
  if (userAssertionHash) atEntity.userAssertionHash = userAssertionHash;
1443
1442
  if (refreshOn) atEntity.refreshOn = refreshOn.toString();
1443
+ const normalizedTokenType = atEntity.tokenType?.toLowerCase();
1444
1444
  if (atEntity.tokenType?.toLowerCase() !== AuthenticationScheme.BEARER.toLowerCase()) {
1445
1445
  atEntity.credentialType = CredentialType.ACCESS_TOKEN_WITH_AUTH_SCHEME;
1446
- switch (atEntity.tokenType) {
1446
+ switch (normalizedTokenType) {
1447
1447
  case AuthenticationScheme.POP:
1448
1448
  const tokenClaims = extractTokenClaims(accessToken, base64Decode, correlationId);
1449
1449
  if (!tokenClaims?.cnf?.kid) throw createClientAuthError(tokenClaimsCnfRequiredForSignedJwt, correlationId);
1450
1450
  atEntity.keyId = tokenClaims.cnf.kid;
1451
1451
  break;
1452
+ case "dpop":
1453
+ if (!keyId) throw createClientAuthError(keyIdMissing, correlationId);
1454
+ atEntity.keyId = keyId;
1455
+ break;
1452
1456
  case AuthenticationScheme.SSH: atEntity.keyId = keyId;
1453
1457
  }
1454
1458
  }
@@ -1589,7 +1593,7 @@ function serializeAttributeTokens(attributeTokens) {
1589
1593
  }
1590
1594
  //#endregion
1591
1595
  //#region node_modules/@azure/msal-common/dist/authority/Authority.mjs
1592
- /*! @azure/msal-common v16.12.0 2026-08-04 */
1596
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
1593
1597
  /**
1594
1598
  * The authority class validates the authority URIs used by the user, and retrieves the OpenID Configuration Data from the
1595
1599
  * endpoint. It will store the pertinent config data in this object for use during token calls.
@@ -1623,7 +1627,6 @@ var Authority = class Authority {
1623
1627
  const pathSegments = authorityUri.PathSegments;
1624
1628
  if (pathSegments.length) switch (pathSegments[0].toLowerCase()) {
1625
1629
  case ADFS: return AuthorityType.Adfs;
1626
- case DSTS: return AuthorityType.Dsts;
1627
1630
  }
1628
1631
  return AuthorityType.Default;
1629
1632
  }
@@ -2324,7 +2327,7 @@ function buildStaticAuthorityOptions(authOptions) {
2324
2327
  }
2325
2328
  //#endregion
2326
2329
  //#region node_modules/@azure/msal-common/dist/authority/AuthorityFactory.mjs
2327
- /*! @azure/msal-common v16.12.0 2026-08-04 */
2330
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
2328
2331
  /**
2329
2332
  * Create an authority object of the correct type based on the url
2330
2333
  * Performs basic authority validation - checks to see if the authority is of a valid type (i.e. aad, b2c, adfs)
@@ -2351,7 +2354,7 @@ async function createDiscoveredInstance(authorityUri, networkClient, cacheManage
2351
2354
  }
2352
2355
  //#endregion
2353
2356
  //#region node_modules/@azure/msal-common/dist/request/ScopeSet.mjs
2354
- /*! @azure/msal-common v16.12.0 2026-08-04 */
2357
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
2355
2358
  /**
2356
2359
  * The ScopeSet class creates a set of scopes. Scopes are case-insensitive, unique values, so the Set object in JS makes
2357
2360
  * the most sense to implement for this class. All scopes are trimmed and converted to lower case strings in intersection and union functions
@@ -2503,7 +2506,7 @@ var ScopeSet = class ScopeSet {
2503
2506
  };
2504
2507
  //#endregion
2505
2508
  //#region node_modules/@azure/msal-common/dist/request/RequestParameterBuilder.mjs
2506
- /*! @azure/msal-common v16.12.0 2026-08-04 */
2509
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
2507
2510
  function instrumentBrokerParams(parameters, correlationId, performanceClient) {
2508
2511
  if (!correlationId) return;
2509
2512
  const clientId = parameters.get(CLIENT_ID);
@@ -2755,11 +2758,13 @@ function addExtraParameters(parameters, extraParams) {
2755
2758
  }
2756
2759
  /**
2757
2760
  * Default optional idToken claims requested on all auth requests.
2758
- * signin_state enables KMSI detection; login_hint enables login hint propagation.
2761
+ * signin_state enables KMSI detection; login_hint enables login hint propagation;
2762
+ * tenant_region_sub_scope identifies the sovereign enclave a tenant belongs to.
2759
2763
  */
2760
2764
  const DEFAULT_ID_TOKEN_CLAIMS = {
2761
2765
  [ClaimsRequestKeys.SIGNIN_STATE]: { essential: false },
2762
- [ClaimsRequestKeys.LOGIN_HINT]: { essential: false }
2766
+ [ClaimsRequestKeys.LOGIN_HINT]: { essential: false },
2767
+ [ClaimsRequestKeys.TENANT_REGION_SUB_SCOPE]: { essential: false }
2763
2768
  };
2764
2769
  /**
2765
2770
  * Parses a claims JSON string into an object, throwing a ClientConfigurationError
@@ -2776,7 +2781,7 @@ function parseClaims(claims, correlationId = "") {
2776
2781
  } catch (e) {
2777
2782
  throw createClientConfigurationError(invalidClaims, correlationId);
2778
2783
  }
2779
- if (!isPlainObject(parsed)) throw createClientConfigurationError(invalidClaims, correlationId);
2784
+ if (!isPlainObject$1(parsed)) throw createClientConfigurationError(invalidClaims, correlationId);
2780
2785
  return parsed;
2781
2786
  }
2782
2787
  /**
@@ -2784,7 +2789,7 @@ function parseClaims(claims, correlationId = "") {
2784
2789
  * @param value - The value to test
2785
2790
  * @returns True when value is a plain object that can be deep-merged
2786
2791
  */
2787
- function isPlainObject(value) {
2792
+ function isPlainObject$1(value) {
2788
2793
  return typeof value === "object" && value !== null && !Array.isArray(value);
2789
2794
  }
2790
2795
  /**
@@ -2801,7 +2806,7 @@ function deepMergeClaims(baseClaims, claimsToMerge) {
2801
2806
  const merged = { ...baseClaims };
2802
2807
  for (const [key, mergeInValue] of Object.entries(claimsToMerge)) {
2803
2808
  const baseValue = merged[key];
2804
- if (isPlainObject(baseValue) && isPlainObject(mergeInValue)) merged[key] = deepMergeClaims(baseValue, mergeInValue);
2809
+ if (isPlainObject$1(baseValue) && isPlainObject$1(mergeInValue)) merged[key] = deepMergeClaims(baseValue, mergeInValue);
2805
2810
  else merged[key] = mergeInValue;
2806
2811
  }
2807
2812
  return merged;
@@ -2809,8 +2814,8 @@ function deepMergeClaims(baseClaims, claimsToMerge) {
2809
2814
  /**
2810
2815
  * Parses claims JSON, optionally deep-merges a second client-originated claims string
2811
2816
  * (`claimsToMerge`, e.g. `claimsFromClient`) with precedence on conflicting keys, merges
2812
- * default optional idToken claims (signin_state, login_hint), and appends client
2813
- * capabilities (xms_cc) to the access_token section.
2817
+ * default optional idToken claims (signin_state, login_hint, tenant_region_sub_scope), and appends client
2818
+ * capabilities (xms_cc) to the access_token section
2814
2819
  * Does not overwrite idToken claims already specified by the caller.
2815
2820
  * @param claims - Existing claims JSON string from the request (may be undefined)
2816
2821
  * @param clientCapabilities - Client capabilities array from configuration
@@ -2910,7 +2915,7 @@ function addAttributeTokens(parameters, attributeTokens) {
2910
2915
  }
2911
2916
  //#endregion
2912
2917
  //#region node_modules/@azure/msal-common/dist/utils/UrlUtils.mjs
2913
- /*! @azure/msal-common v16.12.0 2026-08-04 */
2918
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
2914
2919
  /**
2915
2920
  * Parses hash string from given string. Returns empty string if no hash symbol is found.
2916
2921
  * @param hashString
@@ -2946,7 +2951,15 @@ function mapToQueryString(parameters) {
2946
2951
  }
2947
2952
  //#endregion
2948
2953
  //#region node_modules/@azure/msal-common/dist/crypto/ICrypto.mjs
2949
- /*! @azure/msal-common v16.12.0 2026-08-04 */
2954
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
2955
+ /**
2956
+ * Shared JOSE algorithm literals used by MSAL package internals.
2957
+ * @internal
2958
+ */
2959
+ const JsonWebTokenAlgorithms = {
2960
+ ES256: "ES256",
2961
+ RS256: "RS256"
2962
+ };
2950
2963
  /**
2951
2964
  * Default crypto implementation used when a platform-specific implementation has
2952
2965
  * not been provided.
@@ -2967,25 +2980,41 @@ const DEFAULT_CRYPTO_IMPLEMENTATION = {
2967
2980
  encodeKid: () => {
2968
2981
  throw createClientAuthError(methodNotImplemented, "");
2969
2982
  },
2970
- async getPublicKeyThumbprint() {
2971
- throw createClientAuthError(methodNotImplemented, "");
2983
+ async removeTokenBindingKey(kid, correlationId) {
2984
+ throw createClientAuthError(methodNotImplemented, correlationId);
2972
2985
  },
2973
- async removeTokenBindingKey() {
2974
- throw createClientAuthError(methodNotImplemented, "");
2986
+ async clearKeystore(correlationId) {
2987
+ throw createClientAuthError(methodNotImplemented, correlationId);
2975
2988
  },
2976
- async clearKeystore() {
2977
- throw createClientAuthError(methodNotImplemented, "");
2978
- },
2979
- async signJwt() {
2980
- throw createClientAuthError(methodNotImplemented, "");
2989
+ async signTokenBindingJwt(header, payload, kid, correlationId) {
2990
+ throw createClientAuthError(methodNotImplemented, correlationId);
2981
2991
  },
2982
2992
  async hashString() {
2983
2993
  throw createClientAuthError(methodNotImplemented, "");
2984
2994
  }
2985
2995
  };
2986
2996
  //#endregion
2997
+ //#region node_modules/@azure/msal-common/dist/crypto/ITokenBindingKeyManager.mjs
2998
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
2999
+ /**
3000
+ * Default token-binding key manager used when a platform-specific implementation
3001
+ * has not been provided.
3002
+ * @internal
3003
+ */
3004
+ const DEFAULT_TOKEN_BINDING_KEY_MANAGER = {
3005
+ async provisionTokenBindingKey(request) {
3006
+ throw createClientAuthError(methodNotImplemented, request.correlationId);
3007
+ },
3008
+ async removeTokenBindingKey(_kid, correlationId) {
3009
+ throw createClientAuthError(methodNotImplemented, correlationId);
3010
+ },
3011
+ async getTokenBindingPublicKeyJwk(_kid, correlationId) {
3012
+ throw createClientAuthError(methodNotImplemented, correlationId);
3013
+ }
3014
+ };
3015
+ //#endregion
2987
3016
  //#region node_modules/@azure/msal-common/dist/logger/Logger.mjs
2988
- /*! @azure/msal-common v16.12.0 2026-08-04 */
3017
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
2989
3018
  /**
2990
3019
  * Log message level.
2991
3020
  */
@@ -3216,17 +3245,17 @@ var Logger = class Logger {
3216
3245
  };
3217
3246
  //#endregion
3218
3247
  //#region node_modules/@azure/msal-common/dist/packageMetadata.mjs
3219
- /*! @azure/msal-common v16.12.0 2026-08-04 */
3248
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
3220
3249
  const name$1 = "@azure/msal-common";
3221
- const version$1 = "16.12.0";
3250
+ const version$1 = "16.14.0";
3222
3251
  //#endregion
3223
3252
  //#region node_modules/@azure/msal-common/dist/error/CacheErrorCodes.mjs
3224
- /*! @azure/msal-common v16.12.0 2026-08-04 */
3253
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
3225
3254
  const cacheQuotaExceeded = "cache_quota_exceeded";
3226
3255
  const cacheErrorUnknown = "cache_error_unknown";
3227
3256
  //#endregion
3228
3257
  //#region node_modules/@azure/msal-common/dist/error/CacheError.mjs
3229
- /*! @azure/msal-common v16.12.0 2026-08-04 */
3258
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
3230
3259
  /**
3231
3260
  * Error thrown when there is an error with the cache
3232
3261
  */
@@ -3252,15 +3281,16 @@ function createCacheError(e) {
3252
3281
  }
3253
3282
  //#endregion
3254
3283
  //#region node_modules/@azure/msal-common/dist/cache/CacheManager.mjs
3255
- /*! @azure/msal-common v16.12.0 2026-08-04 */
3284
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
3256
3285
  /**
3257
3286
  * Interface class which implement cache storage functions used by MSAL to perform validity checks, and store tokens.
3258
3287
  * @internal
3259
3288
  */
3260
3289
  var CacheManager = class {
3261
- constructor(clientId, cryptoImpl, logger, performanceClient, staticAuthorityOptions) {
3290
+ constructor(clientId, cryptoImpl, logger, performanceClient, staticAuthorityOptions, tokenBindingKeyManager) {
3262
3291
  this.clientId = clientId;
3263
3292
  this.cryptoImpl = cryptoImpl;
3293
+ this.tokenBindingKeyManager = tokenBindingKeyManager;
3264
3294
  this.commonLogger = logger.clone(name$1, version$1);
3265
3295
  this.staticAuthorityOptions = staticAuthorityOptions;
3266
3296
  this.performanceClient = performanceClient;
@@ -3457,10 +3487,7 @@ var CacheManager = class {
3457
3487
  if (!!filter.familyId && !this.matchFamilyId(entity, filter.familyId)) return false;
3458
3488
  if (!!filter.target && !this.matchTarget(entity, filter.target, correlationId)) return false;
3459
3489
  if (entity.credentialType === CredentialType.ACCESS_TOKEN_WITH_AUTH_SCHEME) {
3460
- if (!!filter.tokenType && !this.matchTokenType(entity, filter.tokenType)) return false;
3461
- if (filter.tokenType === AuthenticationScheme.SSH) {
3462
- if (filter.keyId && !this.matchKeyId(entity, filter.keyId)) return false;
3463
- }
3490
+ if (!this.matchAccessTokenWithAuthScheme(entity, filter)) return false;
3464
3491
  }
3465
3492
  const entityComponents = entity.additionalCacheKeyComponents;
3466
3493
  const filterComponents = filter.additionalCacheKeyComponents;
@@ -3562,13 +3589,15 @@ var CacheManager = class {
3562
3589
  if (!credential) return;
3563
3590
  this.removeItem(key, correlationId);
3564
3591
  this.performanceClient.incrementFields({ accessTokensRemoved: 1 }, correlationId);
3565
- if (credential.credentialType.toLowerCase() === CredentialType.ACCESS_TOKEN_WITH_AUTH_SCHEME.toLowerCase()) {
3566
- if (credential.tokenType === AuthenticationScheme.POP) {
3592
+ if (credential.credentialType.toLowerCase() === CredentialType.ACCESS_TOKEN_WITH_AUTH_SCHEME.toLowerCase()) switch (credential.tokenType?.toLowerCase()) {
3593
+ case AuthenticationScheme.POP:
3594
+ case AuthenticationScheme.DPOP.toLowerCase(): {
3567
3595
  const kid = credential.keyId;
3568
- if (kid) this.cryptoImpl.removeTokenBindingKey(kid, correlationId).catch(() => {
3569
- this.commonLogger.error(`Failed to remove token binding key '${kid}'`, correlationId);
3596
+ if (kid) this.tokenBindingKeyManager.removeTokenBindingKey(kid, correlationId).catch(() => {
3597
+ this.commonLogger.error("Failed to remove token binding key", correlationId);
3570
3598
  this.performanceClient?.incrementFields({ removeTokenBindingKeyFailure: 1 }, correlationId);
3571
3599
  });
3600
+ break;
3572
3601
  }
3573
3602
  }
3574
3603
  }
@@ -3696,7 +3725,7 @@ var CacheManager = class {
3696
3725
  realm: targetRealm || account.tenantId,
3697
3726
  target: scopes,
3698
3727
  tokenType: authScheme,
3699
- keyId: request.sshKid,
3728
+ keyId: authScheme === AuthenticationScheme.SSH ? request.sshKid : void 0,
3700
3729
  additionalCacheKeyComponents
3701
3730
  };
3702
3731
  const accessTokenKeys = tokenKeys && tokenKeys.accessToken || this.getTokenKeys().accessToken;
@@ -3974,7 +4003,20 @@ var CacheManager = class {
3974
4003
  * @param tokenType
3975
4004
  */
3976
4005
  matchTokenType(entity, tokenType) {
3977
- return !!(entity.tokenType && entity.tokenType === tokenType);
4006
+ return !!(entity.tokenType && entity.tokenType.toLowerCase() === tokenType.toLowerCase());
4007
+ }
4008
+ matchAccessTokenWithAuthScheme(entity, filter) {
4009
+ const normalizedFilterTokenType = filter.tokenType?.toLowerCase();
4010
+ if (!!filter.tokenType && !this.matchTokenType(entity, filter.tokenType)) return false;
4011
+ switch (normalizedFilterTokenType) {
4012
+ case "dpop":
4013
+ case AuthenticationScheme.SSH: return this.matchKeyBoundAccessToken(entity, filter);
4014
+ default: return true;
4015
+ }
4016
+ }
4017
+ matchKeyBoundAccessToken(entity, filter) {
4018
+ if (!filter.keyId) return true;
4019
+ return this.matchKeyId(entity, filter.keyId);
3978
4020
  }
3979
4021
  /**
3980
4022
  * Returns true if the credential's keyId matches the one in the request, false otherwise
@@ -4088,7 +4130,7 @@ var DefaultStorageClass = class extends CacheManager {
4088
4130
  };
4089
4131
  //#endregion
4090
4132
  //#region node_modules/@azure/msal-common/dist/telemetry/performance/PerformanceEvent.mjs
4091
- /*! @azure/msal-common v16.12.0 2026-08-04 */
4133
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4092
4134
  /**
4093
4135
  * State of the performance event.
4094
4136
  *
@@ -4102,7 +4144,7 @@ const PerformanceEventStatus = {
4102
4144
  };
4103
4145
  //#endregion
4104
4146
  //#region node_modules/@azure/msal-common/dist/telemetry/performance/StubPerformanceClient.mjs
4105
- /*! @azure/msal-common v16.12.0 2026-08-04 */
4147
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4106
4148
  var StubPerformanceClient = class {
4107
4149
  generateId() {
4108
4150
  return "callback-id";
@@ -4144,7 +4186,7 @@ var StubPerformanceClient = class {
4144
4186
  };
4145
4187
  //#endregion
4146
4188
  //#region node_modules/@azure/msal-common/dist/config/ClientConfiguration.mjs
4147
- /*! @azure/msal-common v16.12.0 2026-08-04 */
4189
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4148
4190
  const DEFAULT_SYSTEM_OPTIONS$1 = {
4149
4191
  tokenRenewalOffsetSeconds: 300,
4150
4192
  preventCorsPreflight: false
@@ -4189,11 +4231,12 @@ const DEFAULT_TELEMETRY_OPTIONS$1 = { application: {
4189
4231
  * @returns Configuration
4190
4232
  * @internal
4191
4233
  */
4192
- function buildClientConfiguration({ authOptions: userAuthOptions, systemOptions: userSystemOptions, loggerOptions: userLoggerOption, storageInterface: storageImplementation, networkInterface: networkImplementation, cryptoInterface: cryptoImplementation, clientCredentials, libraryInfo, telemetry, serverTelemetryManager, persistencePlugin, serializableCache }) {
4234
+ function buildClientConfiguration({ authOptions: userAuthOptions, systemOptions: userSystemOptions, loggerOptions: userLoggerOption, storageInterface: storageImplementation, networkInterface: networkImplementation, cryptoInterface: cryptoImplementation, tokenBindingKeyManager, clientCredentials, libraryInfo, telemetry, serverTelemetryManager, persistencePlugin, serializableCache }) {
4193
4235
  const loggerOptions = {
4194
4236
  ...DEFAULT_LOGGER_IMPLEMENTATION,
4195
4237
  ...userLoggerOption
4196
4238
  };
4239
+ const resolvedTokenBindingKeyManager = tokenBindingKeyManager || DEFAULT_TOKEN_BINDING_KEY_MANAGER;
4197
4240
  return {
4198
4241
  authOptions: buildAuthOptions(userAuthOptions),
4199
4242
  systemOptions: {
@@ -4201,9 +4244,10 @@ function buildClientConfiguration({ authOptions: userAuthOptions, systemOptions:
4201
4244
  ...userSystemOptions
4202
4245
  },
4203
4246
  loggerOptions,
4204
- storageInterface: storageImplementation || new DefaultStorageClass(userAuthOptions.clientId, DEFAULT_CRYPTO_IMPLEMENTATION, new Logger(loggerOptions, "@azure/msal-common", "16.12.0"), new StubPerformanceClient()),
4247
+ storageInterface: storageImplementation || new DefaultStorageClass(userAuthOptions.clientId, DEFAULT_CRYPTO_IMPLEMENTATION, new Logger(loggerOptions, "@azure/msal-common", "16.14.0"), new StubPerformanceClient(), void 0, resolvedTokenBindingKeyManager),
4205
4248
  networkInterface: networkImplementation || DEFAULT_NETWORK_IMPLEMENTATION,
4206
4249
  cryptoInterface: cryptoImplementation || DEFAULT_CRYPTO_IMPLEMENTATION,
4250
+ tokenBindingKeyManager: resolvedTokenBindingKeyManager,
4207
4251
  clientCredentials: clientCredentials || DEFAULT_CLIENT_CREDENTIALS,
4208
4252
  libraryInfo: {
4209
4253
  ...DEFAULT_LIBRARY_INFO,
@@ -4240,7 +4284,7 @@ function isOidcProtocolMode(config) {
4240
4284
  }
4241
4285
  //#endregion
4242
4286
  //#region node_modules/@azure/msal-common/dist/cache/persistence/TokenCacheContext.mjs
4243
- /*! @azure/msal-common v16.12.0 2026-08-04 */
4287
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4244
4288
  /**
4245
4289
  * This class instance helps track the memory changes facilitating
4246
4290
  * decisions to read from and write to the persistent cache
@@ -4263,13 +4307,101 @@ function isOidcProtocolMode(config) {
4263
4307
  }
4264
4308
  };
4265
4309
  //#endregion
4310
+ //#region node_modules/@azure/msal-common/dist/error/JoseHeaderError.mjs
4311
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4312
+ /**
4313
+ * Error thrown when there is an error in the client code running on the browser.
4314
+ */
4315
+ var JoseHeaderError = class JoseHeaderError extends AuthError {
4316
+ constructor(errorCode, correlationId, errorMessage) {
4317
+ super(errorCode, correlationId, errorMessage);
4318
+ this.name = "JoseHeaderError";
4319
+ Object.setPrototypeOf(this, JoseHeaderError.prototype);
4320
+ }
4321
+ };
4322
+ /** Returns JoseHeaderError object */
4323
+ function createJoseHeaderError(code, correlationId) {
4324
+ return new JoseHeaderError(code, correlationId);
4325
+ }
4326
+ //#endregion
4327
+ //#region node_modules/@azure/msal-common/dist/utils/ObjectUtils.mjs
4328
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4329
+ /**
4330
+ * Checks whether a value is a plain JSON-like object.
4331
+ * Allows objects with null prototypes, but rejects arrays and object subclasses.
4332
+ */
4333
+ function isPlainObject(value) {
4334
+ if (typeof value !== "object" || value === null || Object.prototype.toString.call(value) !== "[object Object]") return false;
4335
+ if (Object.getPrototypeOf(value) === null) return true;
4336
+ let proto = value;
4337
+ while (Object.getPrototypeOf(proto) !== null) proto = Object.getPrototypeOf(proto);
4338
+ return Object.getPrototypeOf(value) === proto;
4339
+ }
4340
+ //#endregion
4341
+ //#region node_modules/@azure/msal-common/dist/error/JoseHeaderErrorCodes.mjs
4342
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4343
+ const missingKidError = "missing_kid_error";
4344
+ const missingAlgError = "missing_alg_error";
4345
+ const missingJwkError = "missing_jwk_error";
4346
+ const invalidJwkError = "invalid_jwk_error";
4347
+ //#endregion
4348
+ //#region node_modules/@azure/msal-common/dist/crypto/JoseHeader.mjs
4349
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4350
+ /** @internal */
4351
+ var JoseHeader = class JoseHeader {
4352
+ constructor(options, correlationId) {
4353
+ if (typeof options.alg !== "string" || !options.alg) throw createJoseHeaderError(missingAlgError, correlationId);
4354
+ this.typ = options.typ;
4355
+ this.alg = options.alg;
4356
+ this.kid = options.kid;
4357
+ this.jwk = options.jwk;
4358
+ }
4359
+ /**
4360
+ * Builds SignedHttpRequest formatted JOSE Header from the
4361
+ * JOSE Header options provided or previously set on the object.
4362
+ * Throws if keyId or algorithm aren't provided since they are required for Access Token Binding.
4363
+ * @param shrHeaderOptions
4364
+ * @param correlationId
4365
+ * @returns
4366
+ */
4367
+ static getShrHeader(shrHeaderOptions, correlationId) {
4368
+ if (!shrHeaderOptions.kid) throw createJoseHeaderError(missingKidError, correlationId);
4369
+ if (!shrHeaderOptions.alg) throw createJoseHeaderError(missingAlgError, correlationId);
4370
+ return new JoseHeader({
4371
+ typ: shrHeaderOptions.typ || JsonWebTokenTypes.Pop,
4372
+ kid: shrHeaderOptions.kid,
4373
+ alg: shrHeaderOptions.alg
4374
+ }, correlationId);
4375
+ }
4376
+ /**
4377
+ * Builds a DPoP formatted JOSE Header from the JOSE Header options provided.
4378
+ * Throws if public JWK or algorithm aren't provided since they are required for DPoP.
4379
+ * @param dpopHeaderOptions
4380
+ * @param correlationId
4381
+ * @returns
4382
+ */
4383
+ static getDpopHeader(dpopHeaderOptions, correlationId) {
4384
+ if (!isPlainObject(dpopHeaderOptions.jwk)) throw createJoseHeaderError(missingJwkError, correlationId);
4385
+ if (!dpopHeaderOptions.alg) throw createJoseHeaderError(missingAlgError, correlationId);
4386
+ if (Object.keys(dpopHeaderOptions.jwk).length === 0) throw createJoseHeaderError(invalidJwkError, correlationId);
4387
+ return new JoseHeader({
4388
+ typ: JsonWebTokenTypes.Dpop,
4389
+ alg: dpopHeaderOptions.alg,
4390
+ jwk: dpopHeaderOptions.jwk
4391
+ }, correlationId);
4392
+ }
4393
+ };
4394
+ //#endregion
4266
4395
  //#region node_modules/@azure/msal-common/dist/crypto/PopTokenGenerator.mjs
4267
- /*! @azure/msal-common v16.12.0 2026-08-04 */
4396
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4268
4397
  const KeyLocation = { SW: "sw" };
4398
+ const SHR_TOKEN_BINDING_KEY_TYPE = "shr";
4399
+ const SHR_TOKEN_BINDING_KEY_ALGORITHM = JsonWebTokenAlgorithms.RS256;
4269
4400
  /** @internal */
4270
4401
  var PopTokenGenerator = class {
4271
- constructor(cryptoUtils, performanceClient) {
4402
+ constructor(cryptoUtils, tokenBindingKeyManager, performanceClient) {
4272
4403
  this.cryptoUtils = cryptoUtils;
4404
+ this.tokenBindingKeyManager = tokenBindingKeyManager;
4273
4405
  this.performanceClient = performanceClient;
4274
4406
  }
4275
4407
  /**
@@ -4293,7 +4425,11 @@ var PopTokenGenerator = class {
4293
4425
  */
4294
4426
  async generateKid(request) {
4295
4427
  return {
4296
- kid: await this.cryptoUtils.getPublicKeyThumbprint(request),
4428
+ kid: await this.tokenBindingKeyManager.provisionTokenBindingKey({
4429
+ correlationId: request.correlationId,
4430
+ tokenBindingKeyType: SHR_TOKEN_BINDING_KEY_TYPE,
4431
+ tokenBindingKeyAlgorithm: SHR_TOKEN_BINDING_KEY_ALGORITHM
4432
+ }),
4297
4433
  xms_ksl: KeyLocation.SW
4298
4434
  };
4299
4435
  }
@@ -4317,7 +4453,15 @@ var PopTokenGenerator = class {
4317
4453
  async signPayload(payload, keyId, request, claims) {
4318
4454
  const { resourceRequestMethod, resourceRequestUri, shrClaims, shrNonce, shrOptions } = request;
4319
4455
  const resourceUrlComponents = (resourceRequestUri ? new UrlString(resourceRequestUri, request.correlationId) : void 0)?.getUrlComponents();
4320
- return this.cryptoUtils.signJwt({
4456
+ const publicKeyJwk = await this.tokenBindingKeyManager.getTokenBindingPublicKeyJwk(keyId, request.correlationId);
4457
+ const encodedKeyIdThumbprint = this.cryptoUtils.base64UrlEncode(JSON.stringify({ kid: keyId }));
4458
+ const shrAlgorithm = shrOptions?.header?.alg || publicKeyJwk.alg || SHR_TOKEN_BINDING_KEY_ALGORITHM;
4459
+ const shrHeader = JoseHeader.getShrHeader({
4460
+ ...shrOptions?.header,
4461
+ alg: shrAlgorithm,
4462
+ kid: encodedKeyIdThumbprint
4463
+ }, request.correlationId);
4464
+ const shrPayload = {
4321
4465
  at: payload,
4322
4466
  ts: nowSeconds(),
4323
4467
  m: resourceRequestMethod?.toUpperCase(),
@@ -4326,13 +4470,140 @@ var PopTokenGenerator = class {
4326
4470
  p: resourceUrlComponents?.AbsolutePath,
4327
4471
  q: resourceUrlComponents?.QueryString ? [[], resourceUrlComponents.QueryString] : void 0,
4328
4472
  client_claims: shrClaims || void 0,
4329
- ...claims
4330
- }, keyId, shrOptions, request.correlationId);
4473
+ ...claims,
4474
+ cnf: { jwk: publicKeyJwk }
4475
+ };
4476
+ return this.cryptoUtils.signTokenBindingJwt(shrHeader, shrPayload, keyId, request.correlationId);
4477
+ }
4478
+ };
4479
+ //#endregion
4480
+ //#region node_modules/@azure/msal-common/dist/crypto/DpopProofGenerator.mjs
4481
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4482
+ const DPOP_HTM_REGEX = /^[!#$%&'*+\-.^_`|~0-9A-Za-z]+$/;
4483
+ const DPOP_TOKEN_BINDING_KEY_TYPE = "dpop";
4484
+ const DPOP_JWT_HEADER_ALGORITHM = JsonWebTokenAlgorithms.ES256;
4485
+ function buildProofHeader(publicJwk, correlationId) {
4486
+ return JoseHeader.getDpopHeader({
4487
+ alg: DPOP_JWT_HEADER_ALGORITHM,
4488
+ jwk: publicJwk
4489
+ }, correlationId);
4490
+ }
4491
+ function normalizeHtm(htm, correlationId) {
4492
+ if (typeof htm !== "string" || !DPOP_HTM_REGEX.test(htm)) throw createClientConfigurationError(invalidDpopHtm, correlationId);
4493
+ return htm.toUpperCase();
4494
+ }
4495
+ /**
4496
+ * Normalizes a URL for use as the DPoP htu claim.
4497
+ * Per RFC 9449 §4.2, htu is the target URI without query and fragment components.
4498
+ * WHATWG URL serialization handles RFC 3986 syntax- and scheme-based normalization
4499
+ * such as lowercasing scheme/host and eliding default ports.
4500
+ */
4501
+ function normalizeHtu(url, correlationId) {
4502
+ let parsedUrl;
4503
+ try {
4504
+ parsedUrl = new URL(url);
4505
+ } catch {
4506
+ throw createClientConfigurationError(urlParseError, correlationId);
4507
+ }
4508
+ if (!/^https:\/\//i.test(url) || parsedUrl.protocol !== "https:" || parsedUrl.username || parsedUrl.password) throw createClientConfigurationError(invalidDpopHtu, correlationId);
4509
+ parsedUrl.search = "";
4510
+ parsedUrl.hash = "";
4511
+ return parsedUrl.href;
4512
+ }
4513
+ function validateDpopNonce(nonce, correlationId) {
4514
+ if (nonce !== void 0 && nonce.trim().length === 0) throw createClientConfigurationError(invalidDpopNonce, correlationId);
4515
+ }
4516
+ /**
4517
+ * Builds RFC 9449 DPoP proof JWT payloads for token-endpoint and
4518
+ * resource-endpoint proof bindings.
4519
+ *
4520
+ * Not exported from any public package entry point.
4521
+ * This helper is internal-only until DPoP is wired into acquisition flows
4522
+ * in a subsequent work item.
4523
+ *
4524
+ * DPoP proofs do not contain SHR fields (at, ts, m, u, p, q).
4525
+ * @internal
4526
+ */
4527
+ var DpopProofGenerator = class {
4528
+ constructor(cryptoUtils, tokenBindingKeyManager) {
4529
+ this.cryptoUtils = cryptoUtils;
4530
+ this.tokenBindingKeyManager = tokenBindingKeyManager;
4531
+ }
4532
+ /**
4533
+ * Provisions a fresh DPoP key and returns the RFC 7638 JWK thumbprint used
4534
+ * as `dpop_jkt`.
4535
+ */
4536
+ async generateJkt(correlationId = "") {
4537
+ return this.tokenBindingKeyManager.provisionTokenBindingKey({
4538
+ tokenBindingKeyType: DPOP_TOKEN_BINDING_KEY_TYPE,
4539
+ tokenBindingKeyAlgorithm: DPOP_JWT_HEADER_ALGORITHM,
4540
+ correlationId
4541
+ });
4542
+ }
4543
+ /**
4544
+ * Builds RFC 9449 claims for a token-endpoint DPoP proof.
4545
+ * - htm is always "POST" because token endpoint requests use HTTP POST (RFC 9449 §5).
4546
+ * - htu is the normalized token endpoint URI (query and fragment stripped).
4547
+ * - jti is a fresh CSPRNG-backed unique identifier for every proof.
4548
+ */
4549
+ buildTokenProofClaims(params, correlationId = "") {
4550
+ validateDpopNonce(params.nonce, correlationId);
4551
+ const claims = {
4552
+ jti: this.cryptoUtils.createNewGuid(),
4553
+ htm: "POST",
4554
+ htu: normalizeHtu(params.tokenEndpoint, correlationId),
4555
+ iat: nowSeconds()
4556
+ };
4557
+ if (params.nonce !== void 0) claims.nonce = params.nonce;
4558
+ return claims;
4559
+ }
4560
+ /**
4561
+ * Builds and signs a compact DPoP proof JWT for a token-endpoint request.
4562
+ */
4563
+ async generateTokenProof(params, keyId, correlationId = "") {
4564
+ return this.generateProof(this.buildTokenProofClaims(params, correlationId), keyId, correlationId);
4565
+ }
4566
+ /**
4567
+ * Builds RFC 9449 claims for a resource-endpoint DPoP proof.
4568
+ * - htm is uppercased per RFC 9449 §4.2.
4569
+ * - htu is the normalized resource URI (query and fragment stripped).
4570
+ * - ath is the base64url-encoded SHA-256 hash of the ASCII access token.
4571
+ * - jti is a fresh CSPRNG-backed unique identifier for every proof.
4572
+ */
4573
+ buildResourceProofClaims(params, correlationId = "") {
4574
+ validateDpopNonce(params.nonce, correlationId);
4575
+ const claims = {
4576
+ jti: this.cryptoUtils.createNewGuid(),
4577
+ htm: normalizeHtm(params.htm, correlationId),
4578
+ htu: normalizeHtu(params.htu, correlationId),
4579
+ ath: params.ath,
4580
+ iat: nowSeconds()
4581
+ };
4582
+ if (params.nonce !== void 0) claims.nonce = params.nonce;
4583
+ return claims;
4584
+ }
4585
+ /**
4586
+ * Builds and signs a compact DPoP proof JWT for a resource request.
4587
+ */
4588
+ async generateResourceProof(params, keyId, correlationId = "") {
4589
+ const { htu, htm, nonce } = params;
4590
+ if (!htu || !htm) throw createClientConfigurationError(dpopMissingResourceContext, correlationId);
4591
+ const ath = await this.cryptoUtils.hashString(params.accessToken);
4592
+ return this.generateProof(this.buildResourceProofClaims({
4593
+ htu,
4594
+ htm,
4595
+ ath,
4596
+ nonce
4597
+ }, correlationId), keyId, correlationId);
4598
+ }
4599
+ async generateProof(claims, keyId, correlationId) {
4600
+ const publicJwk = await this.tokenBindingKeyManager.getTokenBindingPublicKeyJwk(keyId, correlationId);
4601
+ return this.cryptoUtils.signTokenBindingJwt(buildProofHeader(publicJwk, correlationId), claims, keyId, correlationId);
4331
4602
  }
4332
4603
  };
4333
4604
  //#endregion
4334
4605
  //#region node_modules/@azure/msal-common/dist/error/InteractionRequiredAuthErrorCodes.mjs
4335
- /*! @azure/msal-common v16.12.0 2026-08-04 */
4606
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4336
4607
  /**
4337
4608
  * MSAL-defined interaction required error code indicating no tokens are found in cache.
4338
4609
  * @public
@@ -4345,7 +4616,7 @@ const noTokensFound = "no_tokens_found";
4345
4616
  const refreshTokenExpired = "refresh_token_expired";
4346
4617
  //#endregion
4347
4618
  //#region node_modules/@azure/msal-common/dist/error/InteractionRequiredAuthError.mjs
4348
- /*! @azure/msal-common v16.12.0 2026-08-04 */
4619
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4349
4620
  /**
4350
4621
  * InteractionRequiredServerErrorMessage contains string constants used by error codes and messages returned by the server indicating interaction is required
4351
4622
  */
@@ -4403,7 +4674,7 @@ function createInteractionRequiredAuthError(errorCode, correlationId, errorMessa
4403
4674
  }
4404
4675
  //#endregion
4405
4676
  //#region node_modules/@azure/msal-common/dist/error/ServerError.mjs
4406
- /*! @azure/msal-common v16.12.0 2026-08-04 */
4677
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4407
4678
  /**
4408
4679
  * Error thrown when there is an error with the server code, for example, unavailability.
4409
4680
  */
@@ -4418,7 +4689,7 @@ var ServerError = class ServerError extends AuthError {
4418
4689
  };
4419
4690
  //#endregion
4420
4691
  //#region node_modules/@azure/msal-common/dist/utils/ProtocolUtils.mjs
4421
- /*! @azure/msal-common v16.12.0 2026-08-04 */
4692
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4422
4693
  /**
4423
4694
  * Parses the state into the RequestStateObject, which contains the LibraryState info and the state passed by the user.
4424
4695
  * @param base64Decode
@@ -4444,16 +4715,17 @@ function parseRequestState(base64Decode, state, correlationId) {
4444
4715
  }
4445
4716
  //#endregion
4446
4717
  //#region node_modules/@azure/msal-common/dist/response/ResponseHandler.mjs
4447
- /*! @azure/msal-common v16.12.0 2026-08-04 */
4718
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4448
4719
  /**
4449
4720
  * Class that handles response parsing.
4450
4721
  * @internal
4451
4722
  */
4452
4723
  var ResponseHandler = class ResponseHandler {
4453
- constructor(clientId, cacheStorage, cryptoObj, logger, performanceClient, serializableCache, persistencePlugin) {
4724
+ constructor(clientId, cacheStorage, cryptoObj, logger, performanceClient, serializableCache, persistencePlugin, tokenBindingKeyManager = DEFAULT_TOKEN_BINDING_KEY_MANAGER) {
4454
4725
  this.clientId = clientId;
4455
4726
  this.cacheStorage = cacheStorage;
4456
4727
  this.cryptoObj = cryptoObj;
4728
+ this.tokenBindingKeyManager = tokenBindingKeyManager;
4457
4729
  this.logger = logger;
4458
4730
  this.performanceClient = performanceClient;
4459
4731
  this.serializableCache = serializableCache;
@@ -4497,7 +4769,14 @@ var ResponseHandler = class ResponseHandler {
4497
4769
  this.homeAccountIdentifier = generateHomeAccountId(serverTokenResponse.client_info || "", authority.authorityType, this.logger, this.cryptoObj, request.correlationId, idTokenClaims);
4498
4770
  let requestStateObj;
4499
4771
  if (!!authCodePayload && !!authCodePayload.state) requestStateObj = parseRequestState(this.cryptoObj.base64Decode, authCodePayload.state, request.correlationId);
4500
- serverTokenResponse.key_id = serverTokenResponse.key_id || request.sshKid || void 0;
4772
+ serverTokenResponse.key_id = serverTokenResponse.key_id || request.dpopJkt || request.sshKid || void 0;
4773
+ if (request.authenticationScheme === AuthenticationScheme.DPOP) {
4774
+ if (serverTokenResponse.token_type?.toLowerCase() !== AuthenticationScheme.DPOP.toLowerCase()) {
4775
+ this.performanceClient?.addFields({ dpopTokenTypeMismatch: serverTokenResponse.token_type }, request.correlationId);
4776
+ throw createClientAuthError(dpopTokenTypeMismatch, request.correlationId);
4777
+ }
4778
+ serverTokenResponse.token_type = AuthenticationScheme.DPOP;
4779
+ }
4501
4780
  const attributeTokenPartition = serializeAttributeTokens(request.attributeTokens);
4502
4781
  const cacheKeyComponents = additionalCacheKeyComponents ?? (attributeTokenPartition ? { attribute_tokens: attributeTokenPartition } : void 0);
4503
4782
  const cacheRecord = this.generateCacheRecord(serverTokenResponse, authority, reqTimestamp, request, idTokenClaims, userAssertionHash, authCodePayload, cacheKeyComponents);
@@ -4515,7 +4794,12 @@ var ResponseHandler = class ResponseHandler {
4515
4794
  }, request.correlationId).length < 1) {
4516
4795
  this.logger.warning("Account used to refresh tokens not in persistence, refreshed tokens will not be stored in the cache", request.correlationId);
4517
4796
  this.performanceClient?.addFields({ acntLoggedOut: true }, request.correlationId);
4518
- return await ResponseHandler.generateAuthenticationResult(this.cryptoObj, authority, cacheRecord, false, request, this.performanceClient, idTokenClaims, requestStateObj, void 0, serverRequestId);
4797
+ return await ResponseHandler.generateAuthenticationResult(this.cryptoObj, authority, cacheRecord, false, request, this.performanceClient, {
4798
+ idTokenClaims,
4799
+ requestState: requestStateObj,
4800
+ requestId: serverRequestId,
4801
+ tokenBindingKeyManager: this.tokenBindingKeyManager
4802
+ });
4519
4803
  }
4520
4804
  }
4521
4805
  await this.cacheStorage.saveCacheRecord(cacheRecord, request.correlationId, isKmsi(idTokenClaims || {}), apiId, request.storeInCache);
@@ -4525,7 +4809,13 @@ var ResponseHandler = class ResponseHandler {
4525
4809
  await this.persistencePlugin.afterCacheAccess(cacheContext);
4526
4810
  }
4527
4811
  }
4528
- return ResponseHandler.generateAuthenticationResult(this.cryptoObj, authority, cacheRecord, false, request, this.performanceClient, idTokenClaims, requestStateObj, serverTokenResponse, serverRequestId);
4812
+ return ResponseHandler.generateAuthenticationResult(this.cryptoObj, authority, cacheRecord, false, request, this.performanceClient, {
4813
+ idTokenClaims,
4814
+ requestState: requestStateObj,
4815
+ serverTokenResponse,
4816
+ requestId: serverRequestId,
4817
+ tokenBindingKeyManager: this.tokenBindingKeyManager
4818
+ });
4529
4819
  }
4530
4820
  /**
4531
4821
  * Generates CacheRecord
@@ -4589,20 +4879,31 @@ var ResponseHandler = class ResponseHandler {
4589
4879
  * @param fromTokenCache
4590
4880
  * @param stateString
4591
4881
  */
4592
- static async generateAuthenticationResult(cryptoObj, authority, cacheRecord, fromTokenCache, request, performanceClient, idTokenClaims, requestState, serverTokenResponse, requestId) {
4882
+ static async generateAuthenticationResult(cryptoObj, authority, cacheRecord, fromTokenCache, request, performanceClient, options = {}) {
4883
+ const { idTokenClaims, requestState, serverTokenResponse, requestId, tokenBindingKeyManager = DEFAULT_TOKEN_BINDING_KEY_MANAGER } = options;
4593
4884
  let accessToken = "";
4594
4885
  let responseScopes = [];
4595
4886
  let expiresOn = null;
4596
4887
  let extExpiresOn;
4597
4888
  let refreshOn;
4598
4889
  let familyId = "";
4890
+ let dpopProof;
4599
4891
  if (cacheRecord.accessToken) {
4892
+ const accessTokenType = cacheRecord.accessToken.tokenType?.toLowerCase();
4600
4893
  if (cacheRecord.accessToken.tokenType === AuthenticationScheme.POP && !request.popKid) {
4601
- const popTokenGenerator = new PopTokenGenerator(cryptoObj, performanceClient);
4894
+ const popTokenGenerator = new PopTokenGenerator(cryptoObj, tokenBindingKeyManager, performanceClient);
4602
4895
  const { secret, keyId } = cacheRecord.accessToken;
4603
4896
  if (!keyId) throw createClientAuthError(keyIdMissing, request.correlationId);
4604
4897
  accessToken = await popTokenGenerator.signPopToken(secret, keyId, request);
4605
4898
  } else accessToken = cacheRecord.accessToken.secret;
4899
+ if (accessTokenType === AuthenticationScheme.DPOP.toLowerCase()) {
4900
+ if (!cacheRecord.accessToken.keyId) throw createClientAuthError(keyIdMissing, request.correlationId);
4901
+ dpopProof = await new DpopProofGenerator(cryptoObj, tokenBindingKeyManager).generateResourceProof({
4902
+ htu: request.resourceRequestUri,
4903
+ htm: request.resourceRequestMethod,
4904
+ accessToken: cacheRecord.accessToken.secret
4905
+ }, cacheRecord.accessToken.keyId, request.correlationId);
4906
+ }
4606
4907
  responseScopes = ScopeSet.fromString(cacheRecord.accessToken.target, request.correlationId).asArray();
4607
4908
  expiresOn = toDateFromSeconds(cacheRecord.accessToken.expiresOn);
4608
4909
  extExpiresOn = toDateFromSeconds(cacheRecord.accessToken.extendedExpiresOn);
@@ -4611,6 +4912,8 @@ var ResponseHandler = class ResponseHandler {
4611
4912
  if (cacheRecord.appMetadata) familyId = cacheRecord.appMetadata.familyId === "1" ? "1" : "";
4612
4913
  const uid = idTokenClaims?.oid || idTokenClaims?.sub || "";
4613
4914
  const tid = idTokenClaims?.tid || "";
4915
+ const regionSubScope = idTokenClaims?.tenant_region_sub_scope;
4916
+ if (typeof regionSubScope === "string") performanceClient?.addFields({ regionSubScope }, request.correlationId);
4614
4917
  if (serverTokenResponse?.spa_accountid && !!cacheRecord.account) {
4615
4918
  cacheRecord.account.nativeAccountId = serverTokenResponse?.spa_accountid;
4616
4919
  const targetTenantId = tid || cacheRecord.account.realm;
@@ -4629,6 +4932,7 @@ var ResponseHandler = class ResponseHandler {
4629
4932
  idToken: cacheRecord?.idToken?.secret || "",
4630
4933
  idTokenClaims: idTokenClaims || {},
4631
4934
  accessToken,
4935
+ dpopProof,
4632
4936
  fromCache: fromTokenCache,
4633
4937
  expiresOn,
4634
4938
  extExpiresOn,
@@ -4636,7 +4940,7 @@ var ResponseHandler = class ResponseHandler {
4636
4940
  correlationId: request.correlationId,
4637
4941
  requestId: requestId || "",
4638
4942
  familyId,
4639
- tokenType: cacheRecord.accessToken?.tokenType || "",
4943
+ tokenType: cacheRecord.accessToken?.tokenType?.toLowerCase() === AuthenticationScheme.DPOP.toLowerCase() ? AuthenticationScheme.DPOP : cacheRecord.accessToken?.tokenType || "",
4640
4944
  state: requestState ? requestState.userRequestState : "",
4641
4945
  cloudGraphHostName: cacheRecord.account?.cloudGraphHostName || "",
4642
4946
  msGraphHost: cacheRecord.account?.msGraphHost || "",
@@ -4677,14 +4981,14 @@ function buildAccountToCache(cacheStorage, authority, homeAccountId, base64Decod
4677
4981
  }
4678
4982
  //#endregion
4679
4983
  //#region node_modules/@azure/msal-common/dist/account/CcsCredential.mjs
4680
- /*! @azure/msal-common v16.12.0 2026-08-04 */
4984
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4681
4985
  const CcsCredentialType = {
4682
4986
  HOME_ACCOUNT_ID: "home_account_id",
4683
4987
  UPN: "UPN"
4684
4988
  };
4685
4989
  //#endregion
4686
4990
  //#region node_modules/@azure/msal-common/dist/utils/ClientAssertionUtils.mjs
4687
- /*! @azure/msal-common v16.12.0 2026-08-04 */
4991
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4688
4992
  async function getClientAssertion(clientAssertion, clientId, tokenEndpoint, fmiPath) {
4689
4993
  if (typeof clientAssertion === "string") return clientAssertion;
4690
4994
  else return clientAssertion({
@@ -4695,7 +4999,7 @@ async function getClientAssertion(clientAssertion, clientId, tokenEndpoint, fmiP
4695
4999
  }
4696
5000
  //#endregion
4697
5001
  //#region node_modules/@azure/msal-common/dist/network/RequestThumbprint.mjs
4698
- /*! @azure/msal-common v16.12.0 2026-08-04 */
5002
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4699
5003
  function getRequestThumbprint(clientId, request, homeAccountId) {
4700
5004
  return {
4701
5005
  clientId,
@@ -4715,7 +5019,7 @@ function getRequestThumbprint(clientId, request, homeAccountId) {
4715
5019
  }
4716
5020
  //#endregion
4717
5021
  //#region node_modules/@azure/msal-common/dist/network/ThrottlingUtils.mjs
4718
- /*! @azure/msal-common v16.12.0 2026-08-04 */
5022
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4719
5023
  /** @internal */
4720
5024
  var ThrottlingUtils = class ThrottlingUtils {
4721
5025
  /**
@@ -4791,7 +5095,7 @@ var ThrottlingUtils = class ThrottlingUtils {
4791
5095
  };
4792
5096
  //#endregion
4793
5097
  //#region node_modules/@azure/msal-common/dist/error/NetworkError.mjs
4794
- /*! @azure/msal-common v16.12.0 2026-08-04 */
5098
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4795
5099
  /**
4796
5100
  * Represents network related errors
4797
5101
  */
@@ -4818,7 +5122,7 @@ function createNetworkError(error, httpStatus, responseHeaders, additionalError)
4818
5122
  }
4819
5123
  //#endregion
4820
5124
  //#region node_modules/@azure/msal-common/dist/protocol/Token.mjs
4821
- /*! @azure/msal-common v16.12.0 2026-08-04 */
5125
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4822
5126
  /**
4823
5127
  * Creates default headers for requests to token endpoint
4824
5128
  */
@@ -4839,6 +5143,17 @@ function createTokenRequestHeaders(logger, preventCorsPreflight, ccsCred) {
4839
5143
  return headers;
4840
5144
  }
4841
5145
  /**
5146
+ * Adds the DPoP proof header for token endpoint requests when DPoP is requested.
5147
+ * @internal
5148
+ */
5149
+ async function addDpopTokenProofHeader(headers, request, tokenEndpoint, cryptoUtils, tokenBindingKeyManager) {
5150
+ if (request.authenticationScheme !== AuthenticationScheme.DPOP) return;
5151
+ const dpopProofGenerator = new DpopProofGenerator(cryptoUtils, tokenBindingKeyManager);
5152
+ const keyId = request.dpopJkt;
5153
+ if (!keyId?.trim()) throw createClientAuthError(keyIdMissing, request.correlationId);
5154
+ headers[HeaderNames.DPOP] = await dpopProofGenerator.generateTokenProof({ tokenEndpoint }, keyId, request.correlationId);
5155
+ }
5156
+ /**
4842
5157
  * Creates query string for the /token request
4843
5158
  * @param request
4844
5159
  */
@@ -4913,7 +5228,7 @@ async function sendPostRequest(thumbprint, tokenEndpoint, options, correlationId
4913
5228
  }
4914
5229
  //#endregion
4915
5230
  //#region node_modules/@azure/msal-common/dist/client/AuthorizationCodeClient.mjs
4916
- /*! @azure/msal-common v16.12.0 2026-08-04 */
5231
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
4917
5232
  /**
4918
5233
  * Oauth2.0 Authorization Code client
4919
5234
  * @internal
@@ -4942,7 +5257,7 @@ var AuthorizationCodeClient = class {
4942
5257
  const reqTimestamp = nowSeconds();
4943
5258
  const response = await invokeAsync(this.executeTokenRequest.bind(this), AuthClientExecuteTokenRequest, this.logger, this.performanceClient, request.correlationId)(this.authority, request, this.serverTelemetryManager);
4944
5259
  const requestId = response.headers?.[HeaderNames.X_MS_REQUEST_ID];
4945
- const responseHandler = new ResponseHandler(this.config.authOptions.clientId, this.cacheManager, this.cryptoUtils, this.logger, this.performanceClient, this.config.serializableCache, this.config.persistencePlugin);
5260
+ const responseHandler = new ResponseHandler(this.config.authOptions.clientId, this.cacheManager, this.cryptoUtils, this.logger, this.performanceClient, this.config.serializableCache, this.config.persistencePlugin, this.config.tokenBindingKeyManager);
4946
5261
  responseHandler.validateTokenResponse(response.body, request.correlationId);
4947
5262
  return invokeAsync(responseHandler.handleServerTokenResponse.bind(responseHandler), HandleServerTokenResponse, this.logger, this.performanceClient, request.correlationId)(response.body, this.authority, reqTimestamp, request, apiId, authCodePayload, void 0, void 0, void 0, requestId);
4948
5263
  }
@@ -4976,6 +5291,7 @@ var AuthorizationCodeClient = class {
4976
5291
  this.logger.verbose(`Could not parse client info for CCS Header: '${e}'`, request.correlationId);
4977
5292
  }
4978
5293
  const headers = createTokenRequestHeaders(this.logger, this.config.systemOptions.preventCorsPreflight, ccsCredential || request.ccsCredential);
5294
+ await addDpopTokenProofHeader(headers, request, endpoint, this.cryptoUtils, this.config.tokenBindingKeyManager);
4979
5295
  const thumbprint = getRequestThumbprint(this.config.authOptions.clientId, request);
4980
5296
  return invokeAsync(executePostToTokenEndpoint, AuthorizationCodeClientExecutePostToTokenEndpoint, this.logger, this.performanceClient, request.correlationId)(endpoint, requestBody, headers, thumbprint, request.correlationId, this.cacheManager, this.networkClient, this.logger, this.performanceClient, serverTelemetryManager);
4981
5297
  }
@@ -5008,7 +5324,7 @@ var AuthorizationCodeClient = class {
5008
5324
  addGrantType(parameters, GrantType.AUTHORIZATION_CODE_GRANT);
5009
5325
  addClientInfo(parameters);
5010
5326
  if (request.authenticationScheme === AuthenticationScheme.POP) {
5011
- const popTokenGenerator = new PopTokenGenerator(this.cryptoUtils, this.performanceClient);
5327
+ const popTokenGenerator = new PopTokenGenerator(this.cryptoUtils, this.config.tokenBindingKeyManager, this.performanceClient);
5012
5328
  let reqCnfData;
5013
5329
  if (!request.popKid) reqCnfData = (await invokeAsync(popTokenGenerator.generateCnf.bind(popTokenGenerator), PopTokenGenerateCnf, this.logger, this.performanceClient, request.correlationId)(request, this.logger)).reqCnfString;
5014
5330
  else reqCnfData = this.cryptoUtils.encodeKid(request.popKid);
@@ -5072,7 +5388,7 @@ var AuthorizationCodeClient = class {
5072
5388
  };
5073
5389
  //#endregion
5074
5390
  //#region node_modules/@azure/msal-common/dist/protocol/Authorize.mjs
5075
- /*! @azure/msal-common v16.12.0 2026-08-04 */
5391
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
5076
5392
  /**
5077
5393
  * Returns map of parameters that are applicable to all calls to /authorize whether using PKCE or EAR
5078
5394
  * @param config
@@ -5183,7 +5499,7 @@ function extractLoginHint(account) {
5183
5499
  }
5184
5500
  //#endregion
5185
5501
  //#region node_modules/@azure/msal-common/dist/client/RefreshTokenClient.mjs
5186
- /*! @azure/msal-common v16.12.0 2026-08-04 */
5502
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
5187
5503
  const DEFAULT_REFRESH_TOKEN_EXPIRATION_OFFSET_SECONDS = 300;
5188
5504
  /**
5189
5505
  * OAuth2.0 refresh token client
@@ -5204,7 +5520,7 @@ var RefreshTokenClient = class {
5204
5520
  const reqTimestamp = nowSeconds();
5205
5521
  const response = await invokeAsync(this.executeTokenRequest.bind(this), RefreshTokenClientExecuteTokenRequest, this.logger, this.performanceClient, request.correlationId)(request, this.authority);
5206
5522
  const requestId = response.headers?.[HeaderNames.X_MS_REQUEST_ID];
5207
- const responseHandler = new ResponseHandler(this.config.authOptions.clientId, this.cacheManager, this.cryptoUtils, this.logger, this.performanceClient, this.config.serializableCache, this.config.persistencePlugin);
5523
+ const responseHandler = new ResponseHandler(this.config.authOptions.clientId, this.cacheManager, this.cryptoUtils, this.logger, this.performanceClient, this.config.serializableCache, this.config.persistencePlugin, this.config.tokenBindingKeyManager);
5208
5524
  responseHandler.validateTokenResponse(response.body, request.correlationId);
5209
5525
  return invokeAsync(responseHandler.handleServerTokenResponse.bind(responseHandler), HandleServerTokenResponse, this.logger, this.performanceClient, request.correlationId)(response.body, this.authority, reqTimestamp, request, apiId, void 0, void 0, true, request.forceCache, requestId);
5210
5526
  }
@@ -5249,6 +5565,7 @@ var RefreshTokenClient = class {
5249
5565
  type: CcsCredentialType.HOME_ACCOUNT_ID
5250
5566
  }
5251
5567
  };
5568
+ if (refreshTokenRequest.authenticationScheme === AuthenticationScheme.DPOP && !refreshTokenRequest.dpopJkt) refreshTokenRequest.dpopJkt = await new DpopProofGenerator(this.cryptoUtils, this.config.tokenBindingKeyManager).generateJkt(request.correlationId);
5252
5569
  try {
5253
5570
  return await invokeAsync(this.acquireToken.bind(this), RefreshTokenClientAcquireToken, this.logger, this.performanceClient, request.correlationId)(refreshTokenRequest, apiId);
5254
5571
  } catch (e) {
@@ -5272,6 +5589,7 @@ var RefreshTokenClient = class {
5272
5589
  const endpoint = UrlString.appendQueryString(authority.tokenEndpoint, queryParametersString);
5273
5590
  const requestBody = await invokeAsync(this.createTokenRequestBody.bind(this), RefreshTokenClientCreateTokenRequestBody, this.logger, this.performanceClient, request.correlationId)(request);
5274
5591
  const headers = createTokenRequestHeaders(this.logger, this.config.systemOptions.preventCorsPreflight, request.ccsCredential);
5592
+ await addDpopTokenProofHeader(headers, request, endpoint, this.cryptoUtils, this.config.tokenBindingKeyManager);
5275
5593
  const thumbprint = getRequestThumbprint(this.config.authOptions.clientId, request);
5276
5594
  return invokeAsync(executePostToTokenEndpoint, RefreshTokenClientExecutePostToTokenEndpoint, this.logger, this.performanceClient, request.correlationId)(endpoint, requestBody, headers, thumbprint, request.correlationId, this.cacheManager, this.networkClient, this.logger, this.performanceClient, this.serverTelemetryManager);
5277
5595
  }
@@ -5300,7 +5618,7 @@ var RefreshTokenClient = class {
5300
5618
  addClientAssertionType(parameters, clientAssertion.assertionType);
5301
5619
  }
5302
5620
  if (request.authenticationScheme === AuthenticationScheme.POP) {
5303
- const popTokenGenerator = new PopTokenGenerator(this.cryptoUtils, this.performanceClient);
5621
+ const popTokenGenerator = new PopTokenGenerator(this.cryptoUtils, this.config.tokenBindingKeyManager, this.performanceClient);
5304
5622
  let reqCnfData;
5305
5623
  if (!request.popKid) reqCnfData = (await invokeAsync(popTokenGenerator.generateCnf.bind(popTokenGenerator), PopTokenGenerateCnf, this.logger, this.performanceClient, request.correlationId)(request, this.logger)).reqCnfString;
5306
5624
  else reqCnfData = this.cryptoUtils.encodeKid(request.popKid);
@@ -5328,7 +5646,7 @@ var RefreshTokenClient = class {
5328
5646
  };
5329
5647
  //#endregion
5330
5648
  //#region node_modules/@azure/msal-common/dist/telemetry/server/ServerTelemetryManager.mjs
5331
- /*! @azure/msal-common v16.12.0 2026-08-04 */
5649
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
5332
5650
  const skuGroupSeparator = ",";
5333
5651
  const skuValueSeparator = "|";
5334
5652
  function makeExtraSkuString(params) {
@@ -5523,7 +5841,7 @@ var ServerTelemetryManager = class ServerTelemetryManager {
5523
5841
  };
5524
5842
  //#endregion
5525
5843
  //#region node_modules/@azure/msal-common/dist/client/SilentFlowClient.mjs
5526
- /*! @azure/msal-common v16.12.0 2026-08-04 */
5844
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
5527
5845
  /** @internal */
5528
5846
  var SilentFlowClient = class {
5529
5847
  constructor(configuration, performanceClient) {
@@ -5562,6 +5880,20 @@ var SilentFlowClient = class {
5562
5880
  throw createClientAuthError(tokenRefreshRequired, request.correlationId);
5563
5881
  }
5564
5882
  } else if (cachedAccessToken.refreshOn && isTokenExpired(cachedAccessToken.refreshOn, 0)) lastCacheOutcome = CacheOutcome.PROACTIVELY_REFRESHED;
5883
+ if (cachedAccessToken.tokenType?.toLowerCase() === AuthenticationScheme.DPOP.toLowerCase()) {
5884
+ if (!cachedAccessToken.keyId) {
5885
+ this.logger.info("SilentFlowClient:acquireCachedToken - Cached DPoP access token is missing keyId; refresh required", request.correlationId);
5886
+ this.setCacheOutcome(CacheOutcome.NO_CACHED_ACCESS_TOKEN, request.correlationId);
5887
+ throw createClientAuthError(tokenRefreshRequired, request.correlationId);
5888
+ }
5889
+ try {
5890
+ await this.config.tokenBindingKeyManager.getTokenBindingPublicKeyJwk(cachedAccessToken.keyId, request.correlationId);
5891
+ } catch {
5892
+ this.logger.info("SilentFlowClient:acquireCachedToken - Local DPoP key was not found for cached access token; refresh required", request.correlationId);
5893
+ this.setCacheOutcome(CacheOutcome.NO_CACHED_ACCESS_TOKEN, request.correlationId);
5894
+ throw createClientAuthError(tokenRefreshRequired, request.correlationId);
5895
+ }
5896
+ }
5565
5897
  const environment = request.authority || this.authority.getPreferredCache();
5566
5898
  const cacheRecord = {
5567
5899
  account: this.cacheManager.getAccount(this.cacheManager.generateAccountKey(request.account), request.correlationId),
@@ -5586,12 +5918,15 @@ var SilentFlowClient = class {
5586
5918
  async generateResultFromCacheRecord(cacheRecord, request) {
5587
5919
  let idTokenClaims;
5588
5920
  if (cacheRecord.idToken) idTokenClaims = extractTokenClaims(cacheRecord.idToken.secret, this.config.cryptoInterface.base64Decode, request.correlationId);
5589
- return ResponseHandler.generateAuthenticationResult(this.cryptoUtils, this.authority, cacheRecord, true, request, this.performanceClient, idTokenClaims);
5921
+ return ResponseHandler.generateAuthenticationResult(this.cryptoUtils, this.authority, cacheRecord, true, request, this.performanceClient, {
5922
+ idTokenClaims,
5923
+ tokenBindingKeyManager: this.config.tokenBindingKeyManager
5924
+ });
5590
5925
  }
5591
5926
  };
5592
5927
  //#endregion
5593
5928
  //#region node_modules/@azure/msal-common/dist/request/BaseAuthRequest.mjs
5594
- /*! @azure/msal-common v16.12.0 2026-08-04 */
5929
+ /*! @azure/msal-common v16.14.0 2026-08-28 */
5595
5930
  /**
5596
5931
  * Helper to enforce resource parameter presence in token requests when isMcp is set in the configuration.
5597
5932
  * If resource parameter is set in both the request and in extraQueryParameters or extraParameters, an error will be thrown.
@@ -5610,7 +5945,7 @@ function containsResourceParam(params) {
5610
5945
  }
5611
5946
  //#endregion
5612
5947
  //#region node_modules/@azure/msal-node/dist/cache/serializer/Deserializer.mjs
5613
- /*! @azure/msal-node v5.5.0 2026-08-04 */
5948
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
5614
5949
  /**
5615
5950
  * This class deserializes cache entities read from the file into in-memory object types defined internally
5616
5951
  * @internal
@@ -5758,7 +6093,7 @@ var Deserializer = class {
5758
6093
  };
5759
6094
  }
5760
6095
  };
5761
- /*! @azure/msal-node v5.5.0 2026-08-04 */
6096
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
5762
6097
  /**
5763
6098
  * Managed Identity Query Parameters - used in network requests
5764
6099
  */
@@ -5871,7 +6206,7 @@ const LOOPBACK_SERVER_CONSTANTS = {
5871
6206
  };
5872
6207
  //#endregion
5873
6208
  //#region node_modules/@azure/msal-node/dist/network/HttpClient.mjs
5874
- /*! @azure/msal-node v5.5.0 2026-08-04 */
6209
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
5875
6210
  /**
5876
6211
  * HTTP client implementation using Node.js native fetch API.
5877
6212
  *
@@ -6008,7 +6343,7 @@ function getFetchHeaders(options) {
6008
6343
  }
6009
6344
  //#endregion
6010
6345
  //#region node_modules/@azure/msal-node/dist/error/ManagedIdentityErrorCodes.mjs
6011
- /*! @azure/msal-node v5.5.0 2026-08-04 */
6346
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
6012
6347
  const invalidFileExtension = "invalid_file_extension";
6013
6348
  const invalidFilePath = "invalid_file_path";
6014
6349
  const invalidManagedIdentityIdType = "invalid_managed_identity_id_type";
@@ -6021,6 +6356,7 @@ const unableToCreateCloudShell = "unable_to_create_cloud_shell";
6021
6356
  const unableToCreateSource = "unable_to_create_source";
6022
6357
  const unableToReadSecretFile = "unable_to_read_secret_file";
6023
6358
  const userAssignedNotAvailableAtRuntime = "user_assigned_not_available_at_runtime";
6359
+ const userAssignedManagedIdentityNotConfirmed = "user_assigned_managed_identity_not_confirmed";
6024
6360
  const wwwAuthenticateHeaderMissing = "www_authenticate_header_missing";
6025
6361
  const wwwAuthenticateHeaderUnsupportedFormat = "www_authenticate_header_unsupported_format";
6026
6362
  const MsiEnvironmentVariableUrlMalformedErrorCodes = {
@@ -6031,7 +6367,7 @@ const MsiEnvironmentVariableUrlMalformedErrorCodes = {
6031
6367
  };
6032
6368
  //#endregion
6033
6369
  //#region node_modules/@azure/msal-node/dist/error/ManagedIdentityError.mjs
6034
- /*! @azure/msal-node v5.5.0 2026-08-04 */
6370
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
6035
6371
  /**
6036
6372
  * ManagedIdentityErrorMessage class containing string constants used by error codes and messages.
6037
6373
  */
@@ -6052,8 +6388,9 @@ const ManagedIdentityErrorMessages = {
6052
6388
  [unableToCreateSource]: "Unable to create a Managed Identity source based on environment variables.",
6053
6389
  [unableToReadSecretFile]: "Unable to read the secret file.",
6054
6390
  [userAssignedNotAvailableAtRuntime]: "Service Fabric user assigned managed identity ClientId or ResourceId is not configurable at runtime.",
6055
- [wwwAuthenticateHeaderMissing]: "A 401 response was received form the Azure Arc Managed Identity, but the www-authenticate header is missing.",
6056
- [wwwAuthenticateHeaderUnsupportedFormat]: "A 401 response was received form the Azure Arc Managed Identity, but the www-authenticate header is in an unsupported format."
6391
+ [userAssignedManagedIdentityNotConfirmed]: "Azure Arc did not confirm the requested user-assigned managed identity in the token response. The agent likely does not support user-assigned managed identity and returned the system-assigned identity.",
6392
+ [wwwAuthenticateHeaderMissing]: "A 401 response was received from the Azure Arc Managed Identity, but the www-authenticate header is missing.",
6393
+ [wwwAuthenticateHeaderUnsupportedFormat]: "A 401 response was received from the Azure Arc Managed Identity, but the www-authenticate header is in an unsupported format."
6057
6394
  };
6058
6395
  var ManagedIdentityError = class ManagedIdentityError extends AuthError {
6059
6396
  constructor(errorCode, correlationId) {
@@ -6067,10 +6404,10 @@ function createManagedIdentityError(errorCode, correlationId) {
6067
6404
  }
6068
6405
  //#endregion
6069
6406
  //#region node_modules/@azure/msal-node/dist/config/ManagedIdentityId.mjs
6070
- /*! @azure/msal-node v5.5.0 2026-08-04 */
6407
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
6071
6408
  //#endregion
6072
6409
  //#region node_modules/@azure/msal-node/dist/error/NodeAuthError.mjs
6073
- /*! @azure/msal-node v5.5.0 2026-08-04 */
6410
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
6074
6411
  /**
6075
6412
  * NodeAuthErrorMessage class containing string constants used by error codes and messages.
6076
6413
  */
@@ -6174,7 +6511,7 @@ var NodeAuthError = class NodeAuthError extends AuthError {
6174
6511
  };
6175
6512
  //#endregion
6176
6513
  //#region node_modules/@azure/msal-node/dist/config/Configuration.mjs
6177
- /*! @azure/msal-node v5.5.0 2026-08-04 */
6514
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
6178
6515
  const DEFAULT_AUTH_OPTIONS = {
6179
6516
  clientId: "",
6180
6517
  authority: DEFAULT_AUTHORITY,
@@ -6249,7 +6586,7 @@ function buildAppConfiguration({ auth, broker, cache, system, telemetry }) {
6249
6586
  }
6250
6587
  //#endregion
6251
6588
  //#region node_modules/@azure/msal-node/dist/crypto/GuidGenerator.mjs
6252
- /*! @azure/msal-node v5.5.0 2026-08-04 */
6589
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
6253
6590
  var GuidGenerator = class {
6254
6591
  /**
6255
6592
  * Generates a random [RFC 4122](https://www.rfc-editor.org/rfc/rfc4122.txt) version 4 UUID. The UUID is generated using a
@@ -6268,7 +6605,7 @@ var GuidGenerator = class {
6268
6605
  };
6269
6606
  //#endregion
6270
6607
  //#region node_modules/@azure/msal-node/dist/utils/EncodingUtils.mjs
6271
- /*! @azure/msal-node v5.5.0 2026-08-04 */
6608
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
6272
6609
  var EncodingUtils = class EncodingUtils {
6273
6610
  /**
6274
6611
  * 'utf8': Multibyte encoded Unicode characters. Many web pages and other document formats use UTF-8.
@@ -6306,7 +6643,7 @@ var EncodingUtils = class EncodingUtils {
6306
6643
  };
6307
6644
  //#endregion
6308
6645
  //#region node_modules/@azure/msal-node/dist/crypto/HashUtils.mjs
6309
- /*! @azure/msal-node v5.5.0 2026-08-04 */
6646
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
6310
6647
  var HashUtils = class {
6311
6648
  /**
6312
6649
  * generate 'SHA256' hash
@@ -6318,7 +6655,7 @@ var HashUtils = class {
6318
6655
  };
6319
6656
  //#endregion
6320
6657
  //#region node_modules/@azure/msal-node/dist/crypto/PkceGenerator.mjs
6321
- /*! @azure/msal-node v5.5.0 2026-08-04 */
6658
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
6322
6659
  /**
6323
6660
  * https://tools.ietf.org/html/rfc7636#page-8
6324
6661
  */
@@ -6362,7 +6699,7 @@ var PkceGenerator = class {
6362
6699
  };
6363
6700
  //#endregion
6364
6701
  //#region node_modules/@azure/msal-node/dist/crypto/CryptoProvider.mjs
6365
- /*! @azure/msal-node v5.5.0 2026-08-04 */
6702
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
6366
6703
  /**
6367
6704
  * This class implements MSAL node's crypto interface, which allows it to perform base64 encoding and decoding, generating cryptographically random GUIDs and
6368
6705
  * implementing Proof Key for Code Exchange specs for the OAuth Authorization Code Flow using PKCE (rfc here: https://tools.ietf.org/html/rfc7636).
@@ -6416,29 +6753,29 @@ var CryptoProvider = class {
6416
6753
  return this.pkceGenerator.generatePkceCodes();
6417
6754
  }
6418
6755
  /**
6419
- * Generates a keypair, stores it and returns a thumbprint - not yet implemented for node
6420
- */
6421
- getPublicKeyThumbprint() {
6422
- throw new Error("Method not implemented.");
6423
- }
6424
- /**
6425
6756
  * Removes cryptographic keypair from key store matching the keyId passed in
6426
6757
  * @param kid - public key id
6758
+ * @param correlationId - correlation id
6427
6759
  */
6428
- removeTokenBindingKey() {
6760
+ removeTokenBindingKey(kid, correlationId) {
6429
6761
  throw new Error("Method not implemented.");
6430
6762
  }
6431
6763
  /**
6432
6764
  * Removes all cryptographic keys from Keystore
6765
+ * @param correlationId - correlation id
6433
6766
  */
6434
- clearKeystore() {
6767
+ clearKeystore(correlationId) {
6435
6768
  throw new Error("Method not implemented.");
6436
6769
  }
6437
6770
  /**
6438
- * Signs the given object as a jwt payload with private key retrieved by given kid - currently not implemented for node
6771
+ * Signs a compact JWT with a token-binding key - not yet implemented for node
6772
+ * @param header - JOSE header
6773
+ * @param payload - JWT payload
6774
+ * @param kid - public key id
6775
+ * @param correlationId - correlation id
6439
6776
  */
6440
- signJwt() {
6441
- throw new Error("Method not implemented.");
6777
+ signTokenBindingJwt(header, payload, kid, correlationId) {
6778
+ throw createClientAuthError(methodNotImplemented, correlationId);
6442
6779
  }
6443
6780
  /**
6444
6781
  * Returns the SHA-256 hash of an input string
@@ -6449,7 +6786,7 @@ var CryptoProvider = class {
6449
6786
  };
6450
6787
  //#endregion
6451
6788
  //#region node_modules/@azure/msal-node/dist/cache/CacheHelpers.mjs
6452
- /*! @azure/msal-node v5.5.0 2026-08-04 */
6789
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
6453
6790
  /**
6454
6791
  * Computes a combined hash from additional cache key components.
6455
6792
  *
@@ -6503,14 +6840,14 @@ function generateAccountKey(account) {
6503
6840
  }
6504
6841
  //#endregion
6505
6842
  //#region node_modules/@azure/msal-node/dist/cache/NodeStorage.mjs
6506
- /*! @azure/msal-node v5.5.0 2026-08-04 */
6843
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
6507
6844
  /**
6508
6845
  * This class implements Storage for node, reading cache from user specified storage location or an extension library
6509
6846
  * @public
6510
6847
  */
6511
6848
  var NodeStorage = class extends CacheManager {
6512
6849
  constructor(logger, clientId, cryptoImpl, staticAuthorityOptions) {
6513
- super(clientId, cryptoImpl, logger, new StubPerformanceClient(), staticAuthorityOptions);
6850
+ super(clientId, cryptoImpl, logger, new StubPerformanceClient(), staticAuthorityOptions, DEFAULT_TOKEN_BINDING_KEY_MANAGER);
6514
6851
  this.cache = {};
6515
6852
  this.changeEmitters = [];
6516
6853
  this.logger = logger;
@@ -6870,7 +7207,7 @@ var NodeStorage = class extends CacheManager {
6870
7207
  };
6871
7208
  //#endregion
6872
7209
  //#region node_modules/@azure/msal-node/dist/cache/TokenCache.mjs
6873
- /*! @azure/msal-node v5.5.0 2026-08-04 */
7210
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
6874
7211
  const defaultSerializedCache = {
6875
7212
  Account: {},
6876
7213
  IdToken: {},
@@ -11266,7 +11603,7 @@ var import_jsonwebtoken = /* @__PURE__ */ __toESM((/* @__PURE__ */ __commonJSMin
11266
11603
  TokenExpiredError: require_TokenExpiredError()
11267
11604
  };
11268
11605
  })))(), 1);
11269
- /*! @azure/msal-node v5.5.0 2026-08-04 */
11606
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
11270
11607
  const userTimeoutReached = "user_timeout_reached";
11271
11608
  const invalidAssertion = "invalid_assertion";
11272
11609
  const deviceCodePollingCancelled = "device_code_polling_cancelled";
@@ -11274,7 +11611,7 @@ const deviceCodeExpired = "device_code_expired";
11274
11611
  const deviceCodeUnknownError = "device_code_unknown_error";
11275
11612
  //#endregion
11276
11613
  //#region node_modules/@azure/msal-node/dist/client/ClientAssertion.mjs
11277
- /*! @azure/msal-node v5.5.0 2026-08-04 */
11614
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
11278
11615
  /**
11279
11616
  * Client assertion of type jwt-bearer used in confidential client flows
11280
11617
  * @public
@@ -11382,12 +11719,12 @@ var ClientAssertion = class ClientAssertion {
11382
11719
  };
11383
11720
  //#endregion
11384
11721
  //#region node_modules/@azure/msal-node/dist/packageMetadata.mjs
11385
- /*! @azure/msal-node v5.5.0 2026-08-04 */
11722
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
11386
11723
  const name = "@azure/msal-node";
11387
- const version = "5.5.0";
11724
+ const version = "6.0.0";
11388
11725
  //#endregion
11389
11726
  //#region node_modules/@azure/msal-node/dist/client/BaseClient.mjs
11390
- /*! @azure/msal-node v5.5.0 2026-08-04 */
11727
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
11391
11728
  /**
11392
11729
  * Base application class which will construct requests to send to and handle responses from the Microsoft STS using the authorization code flow.
11393
11730
  * @internal
@@ -11439,7 +11776,7 @@ var BaseClient = class {
11439
11776
  };
11440
11777
  //#endregion
11441
11778
  //#region node_modules/@azure/msal-node/dist/client/UsernamePasswordClient.mjs
11442
- /*! @azure/msal-node v5.5.0 2026-08-04 */
11779
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
11443
11780
  /**
11444
11781
  * Oauth2.0 Password grant client
11445
11782
  * Note: We are only supporting public clients for password grant and for purely testing purposes
@@ -11459,7 +11796,7 @@ var UsernamePasswordClient = class extends BaseClient {
11459
11796
  this.logger.info("in acquireToken call in username-password client", request.correlationId);
11460
11797
  const reqTimestamp = nowSeconds();
11461
11798
  const response = await this.executeTokenRequest(this.authority, request);
11462
- const responseHandler = new ResponseHandler(this.config.authOptions.clientId, this.cacheManager, this.cryptoUtils, this.logger, this.performanceClient, this.config.serializableCache, this.config.persistencePlugin);
11799
+ const responseHandler = new ResponseHandler(this.config.authOptions.clientId, this.cacheManager, this.cryptoUtils, this.logger, this.performanceClient, this.config.serializableCache, this.config.persistencePlugin, this.config.tokenBindingKeyManager);
11463
11800
  responseHandler.validateTokenResponse(response.body, request.correlationId);
11464
11801
  return responseHandler.handleServerTokenResponse(response.body, this.authority, reqTimestamp, request, ApiId.acquireTokenByUsernamePassword);
11465
11802
  }
@@ -11520,7 +11857,7 @@ var UsernamePasswordClient = class extends BaseClient {
11520
11857
  };
11521
11858
  //#endregion
11522
11859
  //#region node_modules/@azure/msal-node/dist/protocol/Authorize.mjs
11523
- /*! @azure/msal-node v5.5.0 2026-08-04 */
11860
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
11524
11861
  /**
11525
11862
  * Constructs the full /authorize URL with request parameters
11526
11863
  * @param config
@@ -11549,7 +11886,7 @@ function getAuthCodeRequestUrl(config, authority, request, logger) {
11549
11886
  }
11550
11887
  //#endregion
11551
11888
  //#region node_modules/@azure/msal-node/dist/client/ClientApplication.mjs
11552
- /*! @azure/msal-node v5.5.0 2026-08-04 */
11889
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
11553
11890
  /**
11554
11891
  * Base abstract class for all ClientApplications - public and confidential
11555
11892
  * @public
@@ -11597,14 +11934,20 @@ var ClientApplication = class {
11597
11934
  */
11598
11935
  async acquireTokenByCode(request, authCodePayLoad) {
11599
11936
  this.logger.info("acquireTokenByCode called", request.correlationId || "");
11600
- if (request.state && authCodePayLoad) {
11937
+ let validatedAuthCodePayload = authCodePayLoad;
11938
+ if (request.state && validatedAuthCodePayload) {
11601
11939
  this.logger.info("acquireTokenByCode - validating state", request.correlationId || "");
11602
- this.validateState(request.state, authCodePayLoad.state || "", request.correlationId || "");
11603
- authCodePayLoad = {
11604
- ...authCodePayLoad,
11940
+ this.validateState(request.state, validatedAuthCodePayload.state || "", request.correlationId || "");
11941
+ validatedAuthCodePayload = {
11942
+ ...validatedAuthCodePayload,
11605
11943
  state: ""
11606
11944
  };
11607
11945
  }
11946
+ if (request.nonce) validatedAuthCodePayload = {
11947
+ ...validatedAuthCodePayload,
11948
+ code: request.code,
11949
+ nonce: request.nonce
11950
+ };
11608
11951
  const validRequest = {
11609
11952
  ...request,
11610
11953
  ...await this.initializeBaseRequest(request),
@@ -11615,7 +11958,7 @@ var ClientApplication = class {
11615
11958
  const discoveredAuthority = await this.createAuthority(validRequest.authority, validRequest.correlationId, void 0, request.azureCloudOptions);
11616
11959
  const authorizationCodeClient = new AuthorizationCodeClient(await this.buildOauthClientConfiguration(discoveredAuthority, validRequest.correlationId, validRequest.redirectUri, serverTelemetryManager), new StubPerformanceClient());
11617
11960
  this.logger.verbose("Auth code client created", validRequest.correlationId);
11618
- return await authorizationCodeClient.acquireToken(validRequest, ApiId.acquireTokenByCode, authCodePayLoad);
11961
+ return await authorizationCodeClient.acquireToken(validRequest, ApiId.acquireTokenByCode, validatedAuthCodePayload);
11619
11962
  } catch (e) {
11620
11963
  if (e instanceof AuthError) e.correlationId = validRequest.correlationId;
11621
11964
  serverTelemetryManager.cacheFailedRequest(e);
@@ -11862,7 +12205,7 @@ var ClientApplication = class {
11862
12205
  };
11863
12206
  //#endregion
11864
12207
  //#region node_modules/@azure/msal-node/dist/network/LoopbackClient.mjs
11865
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12208
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
11866
12209
  var LoopbackClient = class {
11867
12210
  constructor(preferredPort) {
11868
12211
  this.preferredPort = preferredPort;
@@ -11985,7 +12328,7 @@ var LoopbackClient = class {
11985
12328
  };
11986
12329
  //#endregion
11987
12330
  //#region node_modules/@azure/msal-node/dist/client/DeviceCodeClient.mjs
11988
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12331
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
11989
12332
  /**
11990
12333
  * OAuth2.0 Device code client
11991
12334
  * @public
@@ -12004,7 +12347,7 @@ var DeviceCodeClient = class extends BaseClient {
12004
12347
  request.deviceCodeCallback(deviceCodeResponse);
12005
12348
  const reqTimestamp = nowSeconds();
12006
12349
  const response = await this.acquireTokenWithDeviceCode(request, deviceCodeResponse);
12007
- const responseHandler = new ResponseHandler(this.config.authOptions.clientId, this.cacheManager, this.cryptoUtils, this.logger, this.performanceClient, this.config.serializableCache, this.config.persistencePlugin);
12350
+ const responseHandler = new ResponseHandler(this.config.authOptions.clientId, this.cacheManager, this.cryptoUtils, this.logger, this.performanceClient, this.config.serializableCache, this.config.persistencePlugin, this.config.tokenBindingKeyManager);
12008
12351
  responseHandler.validateTokenResponse(response, request.correlationId);
12009
12352
  return responseHandler.handleServerTokenResponse(response, this.authority, reqTimestamp, request, ApiId.acquireTokenByDeviceCode);
12010
12353
  }
@@ -12159,7 +12502,7 @@ var DeviceCodeClient = class extends BaseClient {
12159
12502
  };
12160
12503
  //#endregion
12161
12504
  //#region node_modules/@azure/msal-node/dist/client/PublicClientApplication.mjs
12162
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12505
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
12163
12506
  /**
12164
12507
  * This class is to be used to acquire tokens for public client applications (desktop, mobile). Public client applications
12165
12508
  * are not trusted to safely store application secrets, and therefore can only request tokens in the name of an user.
@@ -12228,8 +12571,7 @@ var PublicClientApplication = class extends ClientApplication {
12228
12571
  const correlationId = request.correlationId || this.cryptoProvider.createNewGuid();
12229
12572
  this.logger.trace("acquireTokenInteractive called", correlationId);
12230
12573
  enforceResourceParameter(this.config.auth.isMcp, request);
12231
- const { openBrowser, successTemplate, errorTemplate, windowHandle, loopbackClient: customLoopbackClient, preferredPort, ...remainingProperties } = request;
12232
- if (customLoopbackClient) this.logger.warning("The loopbackClient option is deprecated and will be removed in a future major version. Omit it to use the built-in loopback server, and set preferredPort when a fixed port is required.", correlationId);
12574
+ const { openBrowser, successTemplate, errorTemplate, windowHandle, preferredPort, ...remainingProperties } = request;
12233
12575
  if (this.nativeBrokerPlugin) {
12234
12576
  const brokerRequest = {
12235
12577
  ...remainingProperties,
@@ -12252,8 +12594,8 @@ var PublicClientApplication = class extends ClientApplication {
12252
12594
  request.redirectUri = "";
12253
12595
  }
12254
12596
  const { verifier, challenge } = await this.cryptoProvider.generatePkceCodes();
12255
- const loopbackClient = customLoopbackClient || new LoopbackClient(preferredPort);
12256
- const responseMode = remainingProperties.responseMode ?? ResponseMode$1.QUERY;
12597
+ const loopbackClient = new LoopbackClient(preferredPort);
12598
+ const responseMode = remainingProperties.responseMode ?? ResponseMode$1.FORM_POST;
12257
12599
  if (responseMode !== ResponseMode$1.QUERY && responseMode !== ResponseMode$1.FORM_POST) throw createClientConfigurationError(invalidResponseMode, correlationId);
12258
12600
  let authCodeResponse = {};
12259
12601
  let authCodeListenerError = null;
@@ -12368,7 +12710,7 @@ var PublicClientApplication = class extends ClientApplication {
12368
12710
  }
12369
12711
  /**
12370
12712
  * Attempts to retrieve the redirectUri from the loopback server. If the loopback server does not start listening for requests within the timeout this will throw.
12371
- * @param loopbackClient - developer provided custom loopback server implementation
12713
+ * @param loopbackClient - built-in loopback server implementation
12372
12714
  * @param correlationId - correlation id of the request
12373
12715
  * @returns
12374
12716
  */
@@ -12401,19 +12743,19 @@ var PublicClientApplication = class extends ClientApplication {
12401
12743
  };
12402
12744
  //#endregion
12403
12745
  //#region node_modules/@azure/msal-node/dist/client/ClientCredentialClient.mjs
12404
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12746
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
12405
12747
  //#endregion
12406
12748
  //#region node_modules/@azure/msal-node/dist/client/OnBehalfOfClient.mjs
12407
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12749
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
12408
12750
  //#endregion
12409
12751
  //#region node_modules/@azure/msal-node/dist/client/UserFederatedIdentityCredentialClient.mjs
12410
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12752
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
12411
12753
  //#endregion
12412
12754
  //#region node_modules/@azure/msal-node/dist/client/ConfidentialClientApplication.mjs
12413
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12755
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
12414
12756
  //#endregion
12415
12757
  //#region node_modules/@azure/msal-node/dist/utils/TimeUtils.mjs
12416
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12758
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
12417
12759
  /**
12418
12760
  * @internal
12419
12761
  * Checks if a given date string is in ISO 8601 format.
@@ -12428,7 +12770,7 @@ function isIso8601(dateString) {
12428
12770
  }
12429
12771
  //#endregion
12430
12772
  //#region node_modules/@azure/msal-node/dist/network/HttpClientWithRetries.mjs
12431
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12773
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
12432
12774
  var HttpClientWithRetries = class {
12433
12775
  constructor(httpClientNoRetries, retryPolicy, logger) {
12434
12776
  this.httpClientNoRetries = httpClientNoRetries;
@@ -12458,7 +12800,7 @@ var HttpClientWithRetries = class {
12458
12800
  };
12459
12801
  //#endregion
12460
12802
  //#region node_modules/@azure/msal-node/dist/client/ManagedIdentitySources/BaseManagedIdentitySource.mjs
12461
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12803
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
12462
12804
  /**
12463
12805
  * Managed Identity User Assigned Id Query Parameter Names
12464
12806
  */
@@ -12648,21 +12990,21 @@ BaseManagedIdentitySource.getValidatedEnvVariableUrlString = (envVariableStringN
12648
12990
  throw createManagedIdentityError(MsiEnvironmentVariableUrlMalformedErrorCodes[envVariableStringName], "");
12649
12991
  }
12650
12992
  };
12651
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12652
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12653
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12654
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12993
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
12994
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
12995
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
12996
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
12655
12997
  `${process.env["ProgramData"]}`;
12656
12998
  `${process.env["ProgramFiles"]}`;
12657
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12658
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12659
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12660
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12661
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12999
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
13000
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
13001
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
13002
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
13003
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
12662
13004
  `${ManagedIdentitySourceNames.MACHINE_LEARNING}`;
12663
- /*! @azure/msal-node v5.5.0 2026-08-04 */
12664
- /*! @azure/msal-node v5.5.0 2026-08-04 */
13005
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
13006
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
12665
13007
  ManagedIdentitySourceNames.SERVICE_FABRIC;
12666
- /*! @azure/msal-node v5.5.0 2026-08-04 */
13008
+ /*! @azure/msal-node v6.0.0 2026-08-28 */
12667
13009
  //#endregion
12668
13010
  export { CryptoProvider, PublicClientApplication };