Preflight checklist
Ory Network Project
No response
Describe your problem
In #1732 127.0.0.1 and [::1] were implemented to allow the usage of arbitrary ports.
Many MCP clients like claude code and others do not use 127.0.0.1 but localhost and generate a random port for the OAuth callback.
See this commit message: agentserver/agentserver@ff15f32
The MCP context possibly also relates to #4061
Describe your ideal solution
Could you please add localhost as a third allowed option alongside 127.0.0.1 and [::1] to use an arbitrary port.
I know, the RFC does not recommend doing this but there are many usecases that unfortunatly require it anyway: https://datatracker.ietf.org/doc/html/rfc8252#section-8.3
Other OAuth implementations e.g. Microsoft Entra ID do support it.
Also there are WSL (Windows Subsystem for Linux) network configurations that do only work using localhost and do not work with 127.0.0.1.
Workarounds or alternatives
None.
Version
v26.0.2
Additional Context
No response
Preflight checklist
Ory Network Project
No response
Describe your problem
In #1732
127.0.0.1and[::1]were implemented to allow the usage of arbitrary ports.Many MCP clients like claude code and others do not use
127.0.0.1butlocalhostand generate a random port for the OAuth callback.See this commit message: agentserver/agentserver@ff15f32
The MCP context possibly also relates to #4061
Describe your ideal solution
Could you please add
localhostas a third allowed option alongside127.0.0.1and[::1]to use an arbitrary port.I know, the RFC does not recommend doing this but there are many usecases that unfortunatly require it anyway: https://datatracker.ietf.org/doc/html/rfc8252#section-8.3
Other OAuth implementations e.g. Microsoft Entra ID do support it.
Also there are WSL (Windows Subsystem for Linux) network configurations that do only work using
localhostand do not work with127.0.0.1.Workarounds or alternatives
None.
Version
v26.0.2
Additional Context
No response