Skip to content

Replace direct redirect with page asking to confirm nav outside Plausible - #6906

Merged
apata merged 2 commits into
masterfrom
mcp/fix-open-redirect
Nov 23, 2026
Merged

apata merged 2 commits into
masterfrom
mcp/fix-open-redirect

Conversation

@apata

@apata apata commented Nov 19, 2026

Copy link
Copy Markdown
Contributor

Motivation

[The attacker could] send an erroneous authorization request, e.g., by using an invalid scope value, thus instructing the authorization server to redirect the user agent to its phishing site.

From OAuth 2.1 draft, authorization server as open redirector.

Changes

To fix, I introduced a "Confirm that you want to navigate outside Plausible page" for the OAuth redirects that previously just redirected without asking the user.

IPhone SE:
localhost_8001_login_oauth_authorize_client_id=https___gist githubusercontent com_apata_7387339c3c81540524bc670da0b05f00_raw_client-metadata json redirect_uri=http___localhost_6276_oauth_callback response_type=code code_challenge=E9Melhoa2O

Desktop:
Screenshot 2026-11-19 at 22 55 39

Tests

  • Automated tests have been added

Changelog

  • This PR does not make a user-facing change

Documentation

  • This change does not need a documentation update

Dark mode

  • The UI has been tested both in dark and light mode

@vinibrsl vinibrsl left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Nice solution!

@apata
apata added this pull request to the merge queue Nov 23, 2026
Merged via the queue into master with commit ad272ac Nov 23, 2026
29 checks passed
@apata
apata deleted the mcp/fix-open-redirect branch November 23, 2026 13:37
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