Brave-browser: Does the chrome.identity api work in chrome extensions in brave?

Created on 10 Jan 2020  路  5Comments  路  Source: brave/brave-browser

Description

I'm a chrome extension developer. In my extension I call chrome.identity.getAuthToken() to do oAuth, this normally pops up a sign-in window in Chrome. The identity API is what made oAuth possible in extensions. However, in Brave, the popup doesn't appear, and in the console it shows Unchecked runtime.lastError: The user turned off browser signin.

So is chrome.identity supported in Brave?

Steps to Reproduce

  1. call chrome.identity.getAuthToken() in an extension. (if you want to try with an existing extension, try the extension "Full Screen for Google Tasks".

Actual result:

No oAuth window appears. In the console it shows Unchecked runtime.lastError: The user turned off browser signin.

Expected result:

oAuth window appears.

Brave version (brave://version info)

Brave | 1.2.42 Chromium: 79.0.3945.117聽(Official Build)聽(64-bit)
Revision | 04f0a055010adab4484f7497fbfdbf312c307f1d-refs/branch-heads/3945@{#1019}
OS | Windows聽10 OS Version 1903 (Build 18362.295)

Version/Channel Information:

  • Can you reproduce this issue with the current release?
    Yes
  • Can you reproduce this issue with the beta channel?
  • Can you reproduce this issue with the dev channel?
  • Can you reproduce this issue with the nightly channel?

Other Additional Information:

  • Does the issue resolve itself when disabling Brave Shields?
    No
  • Does the issue resolve itself when disabling Brave Rewards?
    No
  • Is the issue reproducible on the latest version of Chrome?
    No
featurextensions privactracking question

Most helpful comment

Quick update - @jumde is looking at getting some of this functionality working in Brave (put behind a flag of course)

All 5 comments

@ZYinMD I believe this is expected behavior, as we do disable browser sign in. Any calls made to GAIA are non-routable

@jumde can you confirm?

cc: @pilgrim-brave @tomlowenthal

Confirmed. GAIA is unavailable in Brave in any context.

Thanks!

Hi, just wondering if there is an alternative please?

If I can't use GAIA chrome.identity.getAuthToken() in my extension, but still want to offer Google Auth, how can I do this please?

Thanks

Quick update - @jumde is looking at getting some of this functionality working in Brave (put behind a flag of course)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

AlexeyBarabash picture AlexeyBarabash  路  3Comments

bbondy picture bbondy  路  3Comments

bbondy picture bbondy  路  3Comments

kerry-perret picture kerry-perret  路  3Comments

Sondro picture Sondro  路  3Comments