thunderbird-user.js: [BUG] Can't add Yahoo account to Thunderbird (OAuth2 + ReCaptcha)
Hello,
Describe the bug Not really a bug I guess, but I would like to add a Yahoo account to a Thunderbird profile with thunderbird-user.js & user.js-overrides from 12bytes.org.
After configuration of the account in TB, a webpage pops up displaying Yahoo’s login screen (OAuth2). It first asks for the email address (pre-filled field), then I click “Next” and it displays the following error message within the page “Oops, something went wrong”.
The URL of this page is of the following format (portions with braces are actually replacing some tokens in original URL): https://login.yahoo.net/account/challenge/recaptcha/recaptcha-script?src=oauth&client_id={clientIDToken}--&redirect_uri=http%3A%2F%2Flocalhost&done=https%3A%2F%2Fapi.login.yahoo.com%2Foauth2%2Fauthorize%3F.scrumb%3D0%26client_id%3D{clientIDToken}--%26redirect_uri%3Dhttp%253A%252F%252Flocalhost%26response_type%3Dcode%26scope%3Dmail-w&sessionIndex=QQ--&acrumb={smallToken}&display=login&authMechanism=primary&lang=en-US&siteKey={siteKeyToken}&recaptchaLang=en&recaptchaDomain=www.google.com
It looks like a ReCaptcha issue, also I’ve tried what is advised at the top of this thread :
privacy.resistFingerprinting - false
privacy.firstparty.isolate.restrict_opener_access - false
privacy.firstparty.isolate - false
dom.targetBlankNoOpener.enabled - false
dom.webaudio.enabled - true
and google.com/recaptcha & gstatic.com/recaptcha 3rd party stuff whitelisted in extensions
also google likes 3rd party cookies for their services to run
also don't mess with windows.name (script, CanvasBlocker: whitelist it)
More precisely I set the 5 first prefs as indicated, and authorized all cookies (not sure what are extensions’ whitelist and window.name referring to). But no success.
Environment
- Thunderbird version used (X.Y.Z) : 102.7.1
thunderbird user.js
template version used (X.Y or commit SHA) : 102.1- Operating system and version : Linux Mint 21
Additional context This happens on a freshly created TB profile with thunderbird-user.js and user.js-overrides applied using arkenfox’s updater.sh (in which I modified the update URL so that it points to this repo and not arkenfox’s) and prefsCleaner.js
Checklist
- I can confirm the bug is due to
thunderbird user.js
template and not an overridden preference nor an add-on ; - I have searched for
[SETUP-*]
tags and read them up ; - I have searched the GitHub project (issues and Wiki) for my issue.
About this issue
- Original URL
- State: closed
- Created a year ago
- Comments: 16 (8 by maintainers)
Thank you very much for your messages and congratulations for your achievements ! 🎉
The OAuth2 wiki page has been updated with your additions 🙏
Bye, see you around 👋
Took some time but eventually paid off, and you were right in focusing on CSP errors. Thank you for your support & guidance.
Here is the magical recipe to perform Yahoo Oauth. One can ignore all what was said hereinabove and just apply the following (tested on a fresh TB profile with thunderbird-user.js v102.1 alone, as well as together with 12bytes.org’s user.js-overrides v102r2):
Notes:
Successfully tested TB account config:
I am fine with digging further the issue, but I am likely to need guidance 😃
I have just tried looking at the debugging output when adding an account to TB which I knew was working with standard thunderbird-user.js without any tweaking, but here with the same prefs setup than the previous debug log. It still works and here is the debug output leading to successful integration of the account to Thunderbird.
There are plenty of
NS_ERROR_NOT_IMPLEMENTED
as well, looking the same than in previous debug log. As the result is successful, that makes those errors less likely to be the ones blocking the Yahoo Oauth. However no CSP error there so they may well be an issue.Referring to Yahoo’s debug log from previous post, do you know whether we can exclude from the investigation the warnings about:
transform-origin: 0 0
?Do you refer to all thunderbird-user.js’ modified prefs as base set of prefs to analyze ?