Skip to content

OAuth popup channel name is HTML-escaped inside JS - #1325

Merged
RhysSullivan merged 1 commit into
UsefulSoftwareCo:mainfrom
BittuBarnwal7479:fix/oauth-popup-channel-js-serialization
Aug 3, 2026
Merged

OAuth popup channel name is HTML-escaped inside JS#1325
RhysSullivan merged 1 commit into
UsefulSoftwareCo:mainfrom
BittuBarnwal7479:fix/oauth-popup-channel-js-serialization

Conversation

@BittuBarnwal7479

Copy link
Copy Markdown

Summary:
popupDocument HTML-escapes the OAuth channel name before embedding it in inline JavaScript. In <script>, &quot; is not decoded, so a channel containing " can publish to the wrong BroadcastChannel / localStorage key.

It should serialize the channel name as a JavaScript string instead.

Test:
bun run --cwd packages/core/api test oauth-popup.test.ts passed.

@RhysSullivan
RhysSullivan merged commit d80d278 into UsefulSoftwareCo:main Aug 3, 2026
@BittuBarnwal7479
BittuBarnwal7479 deleted the fix/oauth-popup-channel-js-serialization branch August 4, 2026 04:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants