Feb 25th, 2013, 02:26 PM
Client info in approval page
I'm implementing a custom user approval page, and would like to display some meaningful information about the client in addition to the id (which, in my current scheme, is not intended to be human readable). I see there is an authorizationRequest passed to the view, which gives me access to the clientId, but I do not see the actual client.
Is there a way to get at that without 1) putting logic to load the client in the view, or 2) having to implement custom approval handling classes? Am I missing a request attribute that is set elsewhere in the call stack?
Feb 26th, 2013, 02:21 AM
The vanilla WhitelabelApprovalEndpoint doesn't give you any flexibility with the View or the model, so I expect most implementations will implement both a @RequestMapping for /oauth/confirm_access and a View for it (like in sparklr). It's really up to you then to render the client any way you like, e.g. using a message keyed on the id, or using the additional info in the client registration.
Feb 26th, 2013, 07:58 PM
Thanks for the reply - it nudged me in the right direction. I had set the user-approval-page on <authorization-server>, but didn't understand the relationship between the approval endpoint, the authorization endpoint, and the approval page. Added a mapping to /oauth/confirm_access put what I wanted into the request/view. Pretty simple. Which usually makes me suspect I'm missing something