Jejefcgb
Jejefcgb

Reputation: 390

Chrome Custom Tabs, deep linking with Oauth2

Hi I'm using Google Chrome Custom Tabs for a project and I have a few issues with deep linking.

I need to authenticate the users through a oauth2 process using chrome custom tabs. The user is sent to the authentication form then types is login/password. Then it is redirected to a url like myapp://something. An intent is then triggered and the user is sent back to the app.

The process is working well at first launch when the user is logging in through the authentication form. However, if I try to get another authentication code, I get an ERR_UNKNOWN_URL_SCHEME error and the app stays on the custom tabs.

Here are the three cases I tested :

1st case : Chrome custom tab, forcing the user to use the authentication form

-The user is sent to the authentication form

-A 302 redirect is done to a custom url

-The user is switched to the app

2nd case : Chrome custom tab (using the session cookie)

-The user is sent to the authentication website

-A 302 redirect is done to a custom url

-An ERR_UNKNOWN_URL_SCHEME occurs

3rd case : Chrome browser (using the authentication form or the session cookie)

-The user is sent to the authentication website

-A 302 redirect is done to a custom url

-The user is switched to the app

The full process is working with the chrome browser but I have to make it work with Custom Tabs. Is this behaviour normal ? I mean i read that a user interaction might be needed to use deep links but everything is working well with the chrome brower. Without this deep linking process, how is it possible to do SSO with custom tabs ?

PS : Here's a video to explain my issue and the tests done https://www.youtube.com/watch?v=Y-4uLpUv1lA

Upvotes: 2

Views: 3693

Answers (1)

Jejefcgb
Jejefcgb

Reputation: 390

Bug fixed with the latest chrome release : https://bugs.chromium.org/p/chromium/issues/detail?id=580069

Upvotes: 1

Related Questions