[v5] Strict matching default for MSAL Interceptor#8355
Conversation
There was a problem hiding this comment.
Pull request overview
This PR updates @azure/msal-angular v5 to use strict URL component matching by default when evaluating protectedResourceMap entries, and relocates the legacy matching helper away from msal-common.
Changes:
- Default
MsalInterceptorbehavior now uses strict, anchored, component-aware wildcard matching unlessstrictMatching === false. - Removes
StringUtils.matchPatternfrom@azure/msal-commonand migrates matching tests tomsal-angular. - Adds/updates v5 docs describing strict matching semantics and the opt-out path.
Reviewed changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| lib/msal-angular/src/msal.interceptor.ts | Enables strict matching by default and introduces matchPatternStrict while retaining legacy matching behind strictMatching: false. |
| lib/msal-angular/src/msal.interceptor.config.ts | Documents and exposes the new strictMatching?: boolean configuration option (default true in v5). |
| lib/msal-angular/src/msal.interceptor.spec.ts | Adds extensive unit + integration coverage for strict matching and preserves legacy coverage by setting strictMatching: false in existing tests. |
| lib/msal-angular/docs/msal-interceptor.md | Documents strict matching behavior, defaults, and opt-out guidance. |
| lib/msal-angular/docs/v4-v5-upgrade-guide.md | Adds a breaking-change note for strict matching in v5. |
| lib/msal-common/src/utils/StringUtils.ts | Removes matchPattern from StringUtils. |
| lib/msal-common/test/utils/StringUtils.spec.ts | Removes matchPattern tests now that the helper is removed. |
| lib/msal-common/apiReview/msal-common.api.md | Updates the API review surface to reflect removal of matchPattern. |
| change/@azure-msal-common-8da2a968-6ae2-4495-8ca6-e327ce3f5bd1.json | Adds a changefile for the msal-common API change. |
| change/@azure-msal-angular-0e4576d0-f88b-40f7-9d46-acfeca4f1bad.json | Adds a changefile for the msal-angular default-behavior change. |
change/@azure-msal-common-8da2a968-6ae2-4495-8ca6-e327ce3f5bd1.json
Outdated
Show resolved
Hide resolved
change/@azure-msal-angular-0e4576d0-f88b-40f7-9d46-acfeca4f1bad.json
Outdated
Show resolved
Hide resolved
…AD/microsoft-authentication-library-for-js into v5/strict-matching-default
b142c04
|
This PR makes strictMatching the default for the MSAL Angular interceptor.