OAuth2 on watch!

Hi!

I managed to get OAuth2 authentication run on Tizen Emulator, all features are working like:

  • Showing user a browser where user can grant access
  • Getting access_token and refresh_token by auth_code (first run)
  • Getting new refresh_tokens and access_tokens (from second run).

Everything works perfectly on emulator (Tizen5.5).

On watch I uploaded the app, and it also works perfectly. BUT only as long as I am connected to Wifi!

Once I disable Wifi on watch, nothing happens.

The bad thing is that in case of deactivated Wifi, I can’t see the logs either.

I think I have to use some kind of “web proxy” to reach the internet over Bluetooth over joined phone, but it requires to add “CURLOPT_PROXY”: Curl | Tizen Docs

Which I believe OAuth2 manager just doesn’t have.

So my question is: how can I use OAuth2 manager in Tizen with companion phone over BT?
And a bonus one: how can I test (simulate) BT phone network with emulator?

Thank you!

Hi,
I think you can follow the below guide for that,
https://docs.tizen.org/application/native/guides/personal/oauth/

Thank you, it doesn’t help.

liboauth2 doesn’t apply the required proxy, so it can’t be used on Bluetooth-connected watches.

You can hack yourself into it, and copy the whole library into your workspace and make the required proxy changes to curl functions and that way it can be made working.

Out-of-the-box liboauth2 is not working on the watch.

Samsung expert help is also notified about this, but they didn’t yet have time to look into it.