@azure/msal-common 15.15.0 → 15.16.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.
Files changed (84) hide show
  1. package/dist/account/AccountInfo.mjs +1 -1
  2. package/dist/account/AuthToken.mjs +1 -1
  3. package/dist/account/CcsCredential.mjs +1 -1
  4. package/dist/account/ClientInfo.mjs +1 -1
  5. package/dist/account/TokenClaims.mjs +1 -1
  6. package/dist/authority/Authority.mjs +1 -1
  7. package/dist/authority/AuthorityFactory.mjs +1 -1
  8. package/dist/authority/AuthorityMetadata.mjs +1 -1
  9. package/dist/authority/AuthorityOptions.mjs +1 -1
  10. package/dist/authority/AuthorityType.mjs +1 -1
  11. package/dist/authority/CloudInstanceDiscoveryErrorResponse.mjs +1 -1
  12. package/dist/authority/CloudInstanceDiscoveryResponse.mjs +1 -1
  13. package/dist/authority/OpenIdConfigResponse.mjs +1 -1
  14. package/dist/authority/ProtocolMode.mjs +1 -1
  15. package/dist/authority/RegionDiscovery.mjs +1 -1
  16. package/dist/cache/CacheManager.mjs +1 -1
  17. package/dist/cache/entities/AccountEntity.mjs +1 -1
  18. package/dist/cache/persistence/TokenCacheContext.mjs +1 -1
  19. package/dist/cache/utils/CacheHelpers.mjs +1 -1
  20. package/dist/client/AuthorizationCodeClient.mjs +1 -1
  21. package/dist/client/BaseClient.mjs +1 -1
  22. package/dist/client/RefreshTokenClient.mjs +1 -1
  23. package/dist/client/SilentFlowClient.mjs +1 -1
  24. package/dist/config/ClientConfiguration.mjs +1 -1
  25. package/dist/constants/AADServerParamKeys.mjs +1 -1
  26. package/dist/crypto/ICrypto.mjs +1 -1
  27. package/dist/crypto/JoseHeader.mjs +1 -1
  28. package/dist/crypto/PopTokenGenerator.mjs +1 -1
  29. package/dist/error/AuthError.mjs +1 -1
  30. package/dist/error/AuthErrorCodes.mjs +1 -1
  31. package/dist/error/CacheError.mjs +1 -1
  32. package/dist/error/CacheErrorCodes.mjs +1 -1
  33. package/dist/error/ClientAuthError.mjs +1 -1
  34. package/dist/error/ClientAuthErrorCodes.mjs +1 -1
  35. package/dist/error/ClientConfigurationError.mjs +1 -1
  36. package/dist/error/ClientConfigurationErrorCodes.mjs +1 -1
  37. package/dist/error/InteractionRequiredAuthError.mjs +1 -1
  38. package/dist/error/InteractionRequiredAuthErrorCodes.mjs +1 -1
  39. package/dist/error/JoseHeaderError.mjs +1 -1
  40. package/dist/error/JoseHeaderErrorCodes.mjs +1 -1
  41. package/dist/error/NetworkError.mjs +1 -1
  42. package/dist/error/PlatformBrokerError.mjs +1 -1
  43. package/dist/error/ServerError.mjs +1 -1
  44. package/dist/index-browser.mjs +1 -1
  45. package/dist/index-node.mjs +1 -1
  46. package/dist/index.mjs +1 -1
  47. package/dist/logger/Logger.mjs +1 -1
  48. package/dist/network/INetworkModule.mjs +1 -1
  49. package/dist/network/RequestThumbprint.mjs +1 -1
  50. package/dist/network/ThrottlingUtils.mjs +1 -1
  51. package/dist/packageMetadata.d.ts +1 -1
  52. package/dist/packageMetadata.mjs +2 -2
  53. package/dist/protocol/Authorize.mjs +1 -1
  54. package/dist/request/AuthenticationHeaderParser.mjs +1 -1
  55. package/dist/request/RequestParameterBuilder.mjs +1 -1
  56. package/dist/request/ScopeSet.mjs +1 -1
  57. package/dist/response/ResponseHandler.mjs +1 -1
  58. package/dist/telemetry/performance/PerformanceClient.mjs +1 -1
  59. package/dist/telemetry/performance/PerformanceEvent.mjs +1 -1
  60. package/dist/telemetry/performance/StubPerformanceClient.mjs +1 -1
  61. package/dist/telemetry/server/ServerTelemetryManager.mjs +1 -1
  62. package/dist/url/UrlString.mjs +1 -1
  63. package/dist/utils/ClientAssertionUtils.mjs +1 -1
  64. package/dist/utils/Constants.mjs +1 -1
  65. package/dist/utils/FunctionWrappers.mjs +1 -1
  66. package/dist/utils/ProtocolUtils.mjs +1 -1
  67. package/dist/utils/StringUtils.d.ts +25 -0
  68. package/dist/utils/StringUtils.d.ts.map +1 -1
  69. package/dist/utils/StringUtils.mjs +40 -1
  70. package/dist/utils/StringUtils.mjs.map +1 -1
  71. package/dist/utils/TimeUtils.mjs +1 -1
  72. package/dist/utils/UrlUtils.mjs +1 -1
  73. package/lib/index-browser.cjs +2 -2
  74. package/lib/{index-node-BtzY9XyU.js → index-node-BovRRhfW.js} +42 -3
  75. package/lib/index-node-BovRRhfW.js.map +1 -0
  76. package/lib/index-node.cjs +2 -2
  77. package/lib/index.cjs +2 -2
  78. package/lib/types/packageMetadata.d.ts +1 -1
  79. package/lib/types/utils/StringUtils.d.ts +25 -0
  80. package/lib/types/utils/StringUtils.d.ts.map +1 -1
  81. package/package.json +1 -1
  82. package/src/packageMetadata.ts +1 -1
  83. package/src/utils/StringUtils.ts +48 -0
  84. package/lib/index-node-BtzY9XyU.js.map +0 -1
@@ -1,4 +1,4 @@
1
- /*! @azure/msal-common v15.15.0 2026-02-23 */
1
+ /*! @azure/msal-common v15.16.0 2026-03-04 */
2
2
  'use strict';
3
3
  /*
4
4
  * Copyright (c) Microsoft Corporation. All rights reserved.
@@ -1,4 +1,4 @@
1
- /*! @azure/msal-common v15.15.0 2026-02-23 */
1
+ /*! @azure/msal-common v15.16.0 2026-03-04 */
2
2
  'use strict';
3
3
  import { createClientAuthError } from '../error/ClientAuthError.mjs';
4
4
  import { StringUtils } from './StringUtils.mjs';
@@ -1,8 +1,8 @@
1
- /*! @azure/msal-common v15.15.0 2026-02-23 */
1
+ /*! @azure/msal-common v15.16.0 2026-03-04 */
2
2
  'use strict';
3
3
  'use strict';
4
4
 
5
- var indexNode = require('./index-node-BtzY9XyU.js');
5
+ var indexNode = require('./index-node-BovRRhfW.js');
6
6
 
7
7
  /*
8
8
  * Copyright (c) Microsoft Corporation. All rights reserved.
@@ -1,4 +1,4 @@
1
- /*! @azure/msal-common v15.15.0 2026-02-23 */
1
+ /*! @azure/msal-common v15.16.0 2026-03-04 */
2
2
  'use strict';
3
3
  'use strict';
4
4
 
@@ -1149,6 +1149,45 @@ class StringUtils {
1149
1149
  .replace(/\?/g, "\\?"));
1150
1150
  return regex.test(input);
1151
1151
  }
1152
+ /**
1153
+ * Tests if a given string matches a given pattern using stricter, anchored matching semantics.
1154
+ *
1155
+ * Differences from `matchPattern` (legacy):
1156
+ * - All regex metacharacters (including `.`) in the pattern are treated as literals,
1157
+ * so `example.com` matches only `example.com` and not `exampleXcom`.
1158
+ * - The generated regex is anchored with `^` and `$` so partial/substring matches
1159
+ * are not allowed.
1160
+ * - `*` is the only supported wildcard. Its behaviour depends on the URL component:
1161
+ * - `host` component: `*` matches any sequence of characters that does NOT include
1162
+ * a dot (`.`), keeping wildcards within a single DNS label boundary.
1163
+ * - All other components: `*` matches any sequence of characters (including `/`).
1164
+ *
1165
+ * @param pattern - The `protectedResourceMap` key pattern to match against. `*` is a
1166
+ * multi-character wildcard; all other characters are treated as literals.
1167
+ * @param input - The URL component value (e.g. host, pathname) extracted from the
1168
+ * outgoing request URL to test against the pattern.
1169
+ * @param options - Optional. Provide `component` to enable component-aware wildcard
1170
+ * semantics. Accepted values: `"host"`, `"path"`, `"protocol"`, `"search"`,
1171
+ * `"hash"`. Defaults to path-style (permissive) matching when omitted.
1172
+ * @returns `true` if the full input string matches the pattern; `false` otherwise.
1173
+ */
1174
+ static matchPatternStrict(pattern, input, options) {
1175
+ const component = options?.component;
1176
+ // Step 1: Escape all regex special characters so literals are matched literally.
1177
+ let regexBody = pattern.replace(/[.+^${}()|[\]\\*?]/g, "\\$&");
1178
+ // Step 2: Replace the escaped '*' with its component-aware regex equivalent.
1179
+ if (component === "host") {
1180
+ regexBody = regexBody.replace(/\\\*/g, "[^.]*");
1181
+ }
1182
+ else {
1183
+ // PATH, PROTOCOL, SEARCH, HASH, or unspecified: '*' matches any characters.
1184
+ regexBody = regexBody.replace(/\\\*/g, ".*");
1185
+ }
1186
+ // Step 3: Anchor for full-string matching.
1187
+ // eslint-disable-next-line security/detect-non-literal-regexp
1188
+ const regex = new RegExp(`^${regexBody}$`);
1189
+ return regex.test(input);
1190
+ }
1152
1191
  }
1153
1192
 
1154
1193
  /*
@@ -3987,7 +4026,7 @@ class Logger {
3987
4026
 
3988
4027
  /* eslint-disable header/header */
3989
4028
  const name = "@azure/msal-common";
3990
- const version = "15.15.0";
4029
+ const version = "15.16.0";
3991
4030
 
3992
4031
  /*
3993
4032
  * Copyright (c) Microsoft Corporation. All rights reserved.
@@ -8604,4 +8643,4 @@ exports.invokeAsync = invokeAsync;
8604
8643
  exports.tenantIdMatchesHomeTenant = tenantIdMatchesHomeTenant;
8605
8644
  exports.updateAccountTenantProfileData = updateAccountTenantProfileData;
8606
8645
  exports.version = version;
8607
- //# sourceMappingURL=index-node-BtzY9XyU.js.map
8646
+ //# sourceMappingURL=index-node-BovRRhfW.js.map