-
Notifications
You must be signed in to change notification settings - Fork 613
[BUG][AUTH]: One time auth restricts multiple gateways with same URL #1448
Copy link
Copy link
Closed
Copy link
Labels
bugSomething isn't workingSomething isn't workingfrontendFrontend development (HTML, CSS, JavaScript)Frontend development (HTML, CSS, JavaScript)securityImproves securityImproves securitywxowxo integrationwxo integration
Milestone
Description
🐞 Bug Summary
When using one-time authentication, the system restricts adding multiple gateways that share the same URL. This happens because the duplicate-gateway detection logic compares URL and credentials, but with one-time auth enabled, credentials are not stored (set to None).
As a result, gateways with the same URL and no stored credentials appear as duplicates, even though they should be allowed.
This behavior is intended/implemented for open MCP servers with no auth, but not when one-time auth is intentionally used.
🧩 Affected Component
Select the area of the project impacted:
-
mcpgateway- API -
mcpgateway- UI (admin panel) -
mcpgateway.wrapper- stdio wrapper - Federation or Transports
- CLI, Makefiles, or shell scripts
- Container setup (Docker/Podman/Compose)
- Other (explain below)
🔁 Steps to Reproduce
- Add a Server with One time Authentication enabled.
- Try to add the second server with same url but may have different tools as different authentication is provided with One time Authentication enabled.
- The second server will not be registered as we will get a duplicate gateway found error.
🤔 Expected Behavior
When one-time auth is enabled:
- Skip duplicate-gateway checks that compare URL + credentials.
- Only enforce duplicate name checks.
- Allow multiple gateways pointing to the same URL (each prompting for one-time auth).
When one-time auth is disabled:
- Perform the existing full duplicate gateway check (URL + credentials).
🧠 Environment Info
You can retrieve most of this from the /version endpoint.
| Key | Value |
|---|---|
| Version or commit | e.g. v0.9.0 or main@a1b2c3d |
| Runtime | e.g. Python 3.11, Gunicorn |
| Platform / OS | e.g. Ubuntu 22.04, macOS |
| Container | e.g. Docker, Podman, none |
🧩 Additional Context (optional)
Add any configuration details, flags, or related issues.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingfrontendFrontend development (HTML, CSS, JavaScript)Frontend development (HTML, CSS, JavaScript)securityImproves securityImproves securitywxowxo integrationwxo integration