fix: bind consent to the parsed client on the authorize endpoint - #4121
fix: bind consent to the parsed client on the authorize endpoint#4121knQzx wants to merge 1 commit into
Conversation
verifyConsent compared the flow client against the raw query client_id, so on a POST /oauth2/auth the parsed form client could differ from the query value and a consent granted for one client got applied to another. Compare against the resolved request client instead, and re-validate the granted scope and audience against that client when building the session.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (4)
📝 WalkthroughWalkthroughConsent validation now uses the parsed authorization requester client. Authorization and device authorization handlers pass that requester. Session updates filter consented scopes and audiences against client configuration. Tests cover conflicting query and parsed client identifiers. ChangesAuthorization validation
Estimated code review effort: 3 (Moderate) | ~20 minutes Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
The consent verification compared the flow client against the raw client_id query parameter instead of the parsed client, so on the authorize endpoint the two could diverge and a consent granted for one client be applied to a request running as another. This binds consent to the parsed client and revalidates the granted scope and audience against it.
Summary by CodeRabbit