Skip to content

[MM-68968] Guard redirects and subframe navigations alongside will-navigate (#3927) - #3928

Merged
devinbinnie merged 1 commit into
release-6.3from
MM-68968_cherrypick_release-6.3
Jul 31, 2026
Merged

[MM-68968] Guard redirects and subframe navigations alongside will-navigate (#3927)#3928
devinbinnie merged 1 commit into
release-6.3from
MM-68968_cherrypick_release-6.3

Conversation

@devinbinnie

@devinbinnie devinbinnie commented Jul 31, 2026

Copy link
Copy Markdown
Member

Cherry-pick of #3927 to release-6.3

NONE

Change Impact: 🟡 Medium

Regression Risk: Changes affect shared navigation handling across multiple Electron windows. Automated tests cover main-frame and subframe navigation paths.

QA Recommendation: Skip manual QA because automated coverage is comprehensive and rollback is straightforward.

Generated by CodeRabbitAI

@coderabbitai

coderabbitai Bot commented Jul 31, 2026

Copy link
Copy Markdown
Contributor
🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the main change: guarding redirects and subframe navigations alongside will-navigate.

Comment @coderabbitai help to get the list of available commands.

@devinbinnie
devinbinnie enabled auto-merge (squash) July 31, 2026 14:41
@devinbinnie devinbinnie changed the title [MM-68968] Guard redirects and subframe navigations alongside will-na… [MM-68968] Guard redirects and subframe navigations alongside will-navigate (#3927) Jul 31, 2026

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@src/app/views/pluginsPopUps.ts`:
- Line 65: Replace the generateWillFrameNavigate registration in
PluginsPopUpsManager with a popup-specific subframe handler that allows
about:blank, about:srcdoc, and URLs matching the parent window’s originating
server origin, while preventing all other subframe navigations. Update the
corresponding pluginsPopUps test case to assert that a cross-origin HTTPS URL is
blocked.

In `@src/app/views/webContentEvents.ts`:
- Line 259: Update the popup navigation listeners near generateWillFrameNavigate
so the popup’s will-redirect event also uses generateWillFrameNavigate, while
preserving the event.isMainFrame distinction for subframes. Add a regression
test covering an HTTPS subframe redirect to custom://payload and verify the
subframe policy blocks or handles it as expected.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: cf95d1c4-e982-4d03-83de-2b239c303c9c

📥 Commits

Reviewing files that changed from the base of the PR and between 01b8d6e and 9c108c2.

📒 Files selected for processing (8)
  • src/app/callsWidgetWindow.test.js
  • src/app/callsWidgetWindow.ts
  • src/app/views/pluginsPopUps.test.js
  • src/app/views/pluginsPopUps.ts
  • src/app/views/webContentEvents.test.js
  • src/app/views/webContentEvents.ts
  • src/app/views/webContentEventsCommon.test.ts
  • src/app/views/webContentEventsCommon.ts

Comment thread src/app/views/pluginsPopUps.ts
Comment thread src/app/views/webContentEvents.ts
@devinbinnie
devinbinnie merged commit e68571b into release-6.3 Jul 31, 2026
23 checks passed
@devinbinnie
devinbinnie deleted the MM-68968_cherrypick_release-6.3 branch July 31, 2026 14:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants