Allow OAuth client registration without a client name - #254
Conversation
|
cc @pushpak1300 — since you built the OAuth/DCR layer in #233, this is likely your area. Small change to make |
|
Thanks for your pull request to Laravel! I appreciate you taking the time to submit this; however, it appears this contribution may have been primarily AI-generated without careful human review and consideration. We've found that AI-generated code often doesn't align well with Laravel's conventions, architectural decisions, and the specific context of what we're trying to accomplish with the framework. Quality contributions require thoughtful human insight into the codebase. If you're interested in contributing to Laravel, I'd encourage you to familiarize yourself with the existing codebase, engage with the community, and submit PRs that reflect your own understanding and careful consideration of the problem you're solving. |
|
Thanks. |
RFC 7591 §2 lists
client_nameas an OPTIONAL field for Dynamic Client Registration, butOAuthRegisterControllerrejects any registration that omits bothclient_nameand the legacyname, returning400 invalid_client_metadata. This blocks spec-compliant clients — notably Claude's remote MCP connector, whose registration request leaves outclient_nameand currently fails with "Couldn't register with … sign-in service".This PR makes
client_name/nameoptional. When neither is supplied, the client name falls back to the host of the first redirect URI (e.g.example.com), and toMCP Clientwhen no host can be derived. The existingclient_name>nameprecedence is unchanged, so requests that already send a name behave exactly as before.Tests are updated to cover a registration request without a name and the fallback behaviour.
Fixes #253