uber / rides-ios-sdk

Uber Rides iOS SDK (beta)
https://developer.uber.com/docs
MIT License
371 stars 123 forks source link

Implement prompt for re-login/consent #308

Closed mohssenfathi closed 1 month ago

mohssenfathi commented 1 month ago

Description

Implements the OpenID prompt query parameter to allow the integrating client to force either re-login or re-consent when issuing the authorize request. Details on the API here. Note: Backend currently only supports login and consent parameters for inApp auth only. In the future we may add support for other parameters.

Changes

Prompt

A new OptionSet that defines which prompt parameters to send to the authorize request. Multiple values are supported, they will be sent space delimited and will be url encoded in the requests query parameters.

AuthorizeRequest

Updated the AuthorizeRequest to accept prompt as a parameter. If supplied it will send it as an additional query parameter.

AuthorizationCodeAuthProvider

Also added prompt as a parameter here, which will get injected into AuthorizeRequest for inApp auth only.

Testing

https://github.com/uber/rides-ios-sdk/assets/5241321/83eb2314-54c2-41d5-98df-1fb01fe08e2a