-
Notifications
You must be signed in to change notification settings - Fork 2.7k
[msal-v5] Add local-network-access iframe attribute for Chrome 142+ compatibility #8132
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: msal-v5
Are you sure you want to change the base?
Conversation
Co-authored-by: tnorling <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR backports Chrome 142+ compatibility changes from PR #8128 to the msal-v5 branch, adding support for Local Network Access restrictions that prevent ssoSilent() failures when iframes need to access authorization servers on local networks.
Key Changes
- Added
allow="local-network-access *"iframe attribute to enable Chrome 142+ compatibility - Added test coverage to verify the attribute is correctly set on iframes
- Included beachball changefile for patch release
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| lib/msal-browser/src/interaction_handler/SilentHandler.ts | Added allow="local-network-access *" attribute to iframe in createHiddenIframe() function to enable access to local network resources in Chrome 142+ |
| lib/msal-browser/test/interaction_handler/SilentHandler.spec.ts | Added test case verifying the allow attribute is set to "local-network-access *" on created iframes |
| change/@azure-msal-browser-f58c5c6e-8433-4f07-9f71-6e58bab22ab2.json | Added beachball changefile for patch release documenting the Chrome 142 compatibility fix |
change/@azure-msal-browser-f58c5c6e-8433-4f07-9f71-6e58bab22ab2.json
Outdated
Show resolved
Hide resolved
Co-authored-by: tnorling <[email protected]>
Chrome 142 enables Local Network Access Restrictions by default, causing
ssoSilent()to fail withBrowserAuthError: monitor_window_timeoutwhen the iframe cannot access authorization servers on local networks.Changes
allow="local-network-access *"attribute to iframe created increateHiddenIframe()Technical Details
This replicates PR #8128 changes to the msal-v5 branch. The test was adapted to match msal-v5's function signature (4 parameters vs 5 in dev).
Documentation
Added to
iframe-usage.md:ssoSilent()when the iframe needs to access authorization servers on local networksallow="local-network-access *"iframe attribute to address this restrictionReferences
This pull request was created as a result of the following prompt from Copilot chat.
Original prompt
This pull request was created as a result of the following prompt from Copilot chat.
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.