p2 / OAuth2

OAuth2 framework for macOS and iOS, written in Swift.
Other
1.14k stars 276 forks source link

Use an HTTP URL for authorization in code flow #347

Open suzukieng opened 4 years ago

suzukieng commented 4 years ago

My client uses the authorization code flow, and has a requirement that the authorization URL be HTTP (no HTTPS/TLS). The communication is secured by other means (usually a middleware will redirect to HTTPS).

The redirect URI is a local URL schema (e.g. myapp://oauth2/code), the token URI is HTTPS.

I can't currently use the library because, it will complain that I must use TLS, even for the authorization URL.

Is there some way to opt-out of the HTTPS/SSL/TLS check for the authorization URI?