mirror of
https://github.com/open-webui/open-webui.git
synced 2026-08-25 17:21:00 -05:00
[GH-ISSUE #24155] bug: OAuth 2.1 (Static) MCP redirect_uri with mcp: prefix fails post-SAML validation
#107205
Reference in New Issue
Block a user
Originally created by @NorEliYehShi on GitHub (Apr 26, 2026).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/24155
Check Existing Issues
Installation Method
Docker
Open WebUI Version
v0.9.2
Ollama Version (if applicable)
No response
Operating System
macOS 26
Browser (if applicable)
No response
Confirmation
README.md.Expected Behavior
After completing the OAuth 2.1 (Static) authentication flow with Asana's V2 MCP server,
the user should be redirected back to Open WebUI successfully and the Asana MCP tool
should become active in the chat.
Actual Behavior
After completing SAML authentication via Microsoft Entra ID (triggered by Asana's SSO),
Asana performs a second redirect_uri validation and returns:
The OAuth flow fails and the Asana MCP tool cannot be enabled.
The root cause is that Open WebUI generates the redirect URI with a
:character in the path:When this URI is URL-encoded in the OAuth request it becomes:
Asana performs two separate validations:
The post-SAML validation does not normalize/decode the URI before comparing,
so
mcp%3Aasanadoes not match the registeredmcp:asana.Additionally,
:in a URL path segment is invalid per RFC 3986, which maycause other strict OAuth providers to reject it as well.
Steps to Reproduce
WEBUI_SECRET_KEYand Microsoft Entra ID SSO configured:+MCP Streamable HTTPasanaasanahttps://mcp.asana.com/v2/mcpOAuth 2.1 (Static)+→ Integrations → Tools → toggle Asana onFinal URL in browser:
Logs & Screenshots
Open WebUI log during the failed flow:
Additional Information
Suggested Fix
Change the redirect URI format to use a URL-safe separator instead of
::This eliminates the
:from the path without breaking routing logic and ensurescompatibility with strict OAuth providers that perform exact string matching.
@pr-validator-bot commented on GitHub (Apr 26, 2026):
⚠️ Missing Issue Title Prefix
@NorEliYehShi, your issue title is missing a prefix (e.g.,
bug:,feat:,docs:).Please update your issue title to include one of the following prefixes:
Example:
bug: Login fails when using special characters in password@tjbck commented on GitHub (May 8, 2026):
This is not really an Open WebUI bug. The : character is perfectly valid in URL path segments per RFC 3986. The actual problem is on Asana's side: their post-SAML redirect validation is comparing URL-encoded strings (mcp%3Aasana) against the raw registered URI (mcp:asana) without decoding first. That's Asana's OAuth implementation being broken, not Open WebUI's.