Why am I being logged out of Gmail and Outlook web mail apps

Which would make you wonder if it’s within whatever you changed. Anyway, they are obviously still looking ant trying to figure it out.

Btw, @Moondoggy did you see the bit about the histogram and all? When logged out, would have been nice to catch that and share.

on logout event please open brave://histograms/Signin.BoundSessionCredentials and dump everything you got on this page here. I’m mostly curious if anyone of you got Signin.BoundSessionCredentials.SessionTerminationTrigger histogram and what the value it has in this case.

The thing is in my case, the logout doesn’t occur immediately. I downloaded 1.84.67 as it’s the current nightly release a while ago and Gmail is still live within the browser even when I close the browser completely and return later on. I had installed 1.84.66 the previous evening and Gmail was still live when I logged on in the morning and checked but sometime after that when I opened Brave again Gmail was logged off. So again, in my case it seems like some timing issue that causing Gmail to log out.

ok thanks for explaining I’ve gone ahead and pasted the histogram text in that github here: https://github.com/brave/brave-browser/issues/44789#issuecomment-3294472408

Yesterday I installed Brave Beta and still got signed out of my Google account every one or two hours

1 Like

Perfect, and just in time!

1 Like

For anyone interested, they left a long and informative comment there about the bug, summarized below, and they closed the issue. You can still vote for the issue and subscribe if you want to be notified of any update (I suppose they’ll update it when there’s progress).

A new ticket has been opened for Windows (49300), and there’s one for Linux (39758).

When it happens

Some folks report when closing. Others report it happens w/ browser open after a certain amount of time.

Things that folks have asked to check

These are things which could be giving the same symptom but it’s a different cause.

  • Is “Forget me when I close this site” enabled for site being visited? (click Brave logo next to omnibox)

  • There is also a global “Forget me when I close this site” located at brave://settings/shields

  • Make sure 3rd party software isn’t tampering with cookies / etc (virus scanner, etc).

Many people who are experiencing this issue and have responded here have checked those things and they’re not applicable.

Prognosis

We need to continue collecting more data. My co-worker @goodov shared some things to try in his post here and some folks have done this.

It’s possible Google/Chrome has a value set in their Finch server which we are missing and need to set too. Or they might have a different code-path and we might need to disable a specific feature. We’ll keep digging in to see if this is the case. We can make changes here without making a new binary.

Additional technical information

There are some browser events that happen which are notable. For example, on startup and every 1 hour, the browser itself will check for updates to components (adblock list, extensions, etc). This type of thing (checking at start up and periodically on an interval) happens for other values too. Chromium browsers (ex: Brave) each have a variations server (aka experiments system) configured. Google Chrome uses a system called Finch and Brave uses one called Griffin. Microsoft has one too which they also share and use for MS Office and other products.

You can see our variations / experiments system here:
https://griffin.brave.com/

We are actively monitoring the values Google sets in Finch and watching for multiple situations. One situation we watch for is when Chromium is having a feature ENABLED by default in the code but then it’s OFF for 100% of users in Finch. This particular situation has bit us before.

My guess is that there is a feature enabled (or disabled) in the code which is causing a code-branch for some people where the session termination happens prematurely.

We also did notice that Chromium 140 introduced the following commit:
https://chromiumdash.appspot.com/commit/fad5b47af1418b8db60523269fcf0f37832f8aaa

It’s not clear if this is related or not… but Chromium 140 is included in version 1.82.x of Brave which was first released 4 September on Windows.

3 Likes

What s1l3nce shared is the exact same issue that I’m facing here.

They found the source of the problem and are working on a fix. See link “49300” above.

2 Likes

Hi all, we’ve released a fix in Nightly channel. Is anyone here using Nightly, and can confirm that they’re no longer experiencing this? Thanks in advance! Once we begin to receive confirmations we will move it up to additional release channels.

2 Likes

But honestly, I’m afraid of moving to nightly as it would be not stable at all.

@asodmar3903f3mo5126

  1. Nightly is really stable. The only thing that really differs in it is you’re getting early access to features which may not work perfectly yet. But the core of the browser typically is solid with no problems. It’s only the things being introduced that might be iffy

  2. They are saying to use Nightly just to test if the issue resolves. They aren’t asking you to permanently switch. These are two separate browser installations and can be used without affecting each other.

1 Like

Oh, thanks for the clarification, I’ll test it then.

I’ve installed it right now, I’ll test. Where can I add confirmations? What’s the desired format of these reports?

OK folks - we have a fix merged for Nightly! :tada:

If you are reading this ticket and using the Nightly version of Brave, please restart your browser. When Brave starts up again, it should be contacting our variations server (Griffin).

You can then visit the brave://version page and search for BTMGoogleAuthWorkaround. You should find the experiment and it should be enabled:
BTMGoogleAuthWorkaround:Enabled

After you have confirmed you have this change, log back into the sites which were having the problem and let us know after a few hours. Before, it was doing a cleanup (session terminate) within 2 hours of login. You don’t need to close the browser.

If we get good confirmation this fixes the issue we’ll get this moving to Beta and Release. @goodov will be looking at a better permanent solution.

And then just a small related thing:

Reported upstream https://issues.chromium.org/issues/445561475

They also have this unexpected DBSC session termination, but because they keep 3p cookies for google auth, the auth is still kept.

So yeah, it’s being addressed from two different points.

2 Likes

You can report it in GitHub, if you have a login. Here’s the link to the issue:

Make sure you restart Brave nightly after installing it; the instructions are in Saoiray’s message just above.

If you’re still logged out, check the first comment of that issue to see what to report (there are examples of the format).


EDIT: Note also this update:

[…]

We’re going to roll the fix out to BETA (1.83.x) soon (today; 17 September) as results have been good and then will be rolling out for RELEASE (1.82.x) hopefully as early as tomorrow (18 September).

1 Like

I had reported it there, but I’m also sharing here that the issue seems to be fixed in the nightly version.

2 Likes

Looks like it, yes. It kept the Gmail login for more than 13h30, while the stable version logged me out after 2 hours earlier today.

I’m still puzzled that I don’t seem to get the problem on Linux. 3 days and I was still logged on; that’s weird. Anyway, looking forward to the fix in the stable release. :slight_smile:

2 Likes

@Redglyph yeah, and I never had the issue at all. It just seems to be related to whenever it first authorized the cookies or whatever. Hence why people who had newer installations where experiencing problems more often than others.

And as they indicated, it isn’t a Brave specific issue but it was more pronounced in Brave because of how cookies are handled. So they are doing a fix from Brave’s side but then also trying to have Chromium/Google also fix on their end.

Awesome to see it resolving for everyone.

2 Likes

The fix is making it to the release! :slight_smile: (progressive rollout)

And we’re now at 25% live with the fix on RELEASE (product version 1.82.x).

If you are reading this ticket and using the Release version of Brave, please restart your browser. When Brave starts up again, it should be contacting our variations server (Griffin).

You can check to see if you’re included in that 25% by opening brave://version and searching for BTMGoogleAuthWorkaroundRelease.

When you see that in brave://version, you have the fix and should be good to go. If you don’t see that yet, no worries. We’ll be increasing to 50% and then to 100%.

Please keep us updated as this makes its way out there :grinning_face_with_smiling_eyes: Thanks!

EDIT: I found out that the fix was only enabled in your browser if you see

BTMGoogleAuthWorkaroundRelease:EnabledDefault means it’s not!

2 Likes

@Redglyph are you seeing it on your end?