jaredhanson / draft-openid-connect-cross-origin-authentication

2 stars 2 forks source link

Cross-Origin-Authentication with AccessToken for SSO-Usage #2

Open padLuk opened 6 years ago

padLuk commented 6 years ago

Hi, over the last days I tried figuring out what's the best way of doing SSO between a mobile native app and a web app. The mobile app is secured with 'resource owner password credentials'-flow and has its own login form.

Our requirement is that the user is able to jump from the native app into other client applications also secured with the same IdP. The other client applications are web applications that should be displayed in In-App-WebViews or maybe Custom-Tabs.

So I found your draft for the Cross-Origin-Authentication and thought it was quite suitable for our use case.

Do you see any problems of doing something similar by sending the Access-Token to the Cross-Origin-Authentication-Endpoint? I know it's not the best way of giving the Access-Token to the useragent but the native app is a confidential client application.

Thanks for some hints or opinions from your side.

twistedstream commented 5 years ago

@padLuk I just stumbled across your question and had a few thoughts. I'm not the author of this spec, so I'm not responding on their behalf. These are just my own opinions:

If you already have an OAuth 2.0 Authorization Server, I highly suggest you look into using ACG+PKCE for your mobile application. Since you'll be using the system browser for authorization, SSO will work "out of the box" should you want to send the user to a web page hosted at the same domain. If your server does not support this, then I encourage you to maybe look for alternative ones that do. I found several good options when Googling authorization code grant pkce sso.