New issue
Advanced search Search tips

Issue 825143 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Mar 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 1
Type: Bug



Sign in to add a comment

[Dice M2] Reconcilor may revoke the primary token.

Project Member Reported by droger@chromium.org, Mar 23 2018

Issue description

I don't think this really happens in Chrome in practice, but this definitely happens in tests.

The issue is that the AccountReconcilor is supposed to sometimes revoke secondary tokens:
- If the user cleared their Google cookies
- in some cases if the main token is in error state

However the AccountReconcilor should never revoke the main token.

It happens in tests:
- reconcilor starts when there is no main account, AccountReconcilor::primary_account_ is empty. A call to ListAccounts is started.
- the test does a signin, but does not set any cookies
- ListAccounts returns, and sees that there is a token but no cookies. AccountReconcilor decides to clear the secondary tokens.
- since AccountReconcilor::primary_account_ is empty, the account reconcilor thinks the token is a secondary token and revokes it.
- the user is signed out


This is happening on the bots:
https://logs.chromium.org/v/?s=chromium%2Fbuildbucket%2Fcr-buildbucket.appspot.com%2F8951346925631062368%2F%2B%2Fsteps%2Fsync_integration_tests__with_patch_%2F0%2Flogs%2FSingleClientBookmarksSyncTest.Sanity%2F0
 
Project Member

Comment 1 by bugdroid1@chromium.org, Mar 28 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/2729dee7a97a84f1a59d7d4088ba3da8d5ed7eb5

commit 2729dee7a97a84f1a59d7d4088ba3da8d5ed7eb5
Author: David Roger <droger@chromium.org>
Date: Wed Mar 28 09:28:17 2018

[Dice] Support signin during reconcile

The reconcilor may perform a unwanted signout if the signin happened
in the middle of the reconcile.
This is mostly happening in tests.

Bug:  825143 
Change-Id: I55949bc5758b3a3d4e7994fa8a0cc6ee75db7c02
Reviewed-on: https://chromium-review.googlesource.com/980036
Commit-Queue: David Roger <droger@chromium.org>
Reviewed-by: Mihai Sardarescu <msarda@chromium.org>
Cr-Commit-Position: refs/heads/master@{#546442}
[modify] https://crrev.com/2729dee7a97a84f1a59d7d4088ba3da8d5ed7eb5/components/signin/core/browser/account_reconcilor.cc
[modify] https://crrev.com/2729dee7a97a84f1a59d7d4088ba3da8d5ed7eb5/components/signin/core/browser/account_reconcilor.h
[modify] https://crrev.com/2729dee7a97a84f1a59d7d4088ba3da8d5ed7eb5/components/signin/core/browser/account_reconcilor_unittest.cc

Comment 2 by droger@chromium.org, Mar 28 2018

Status: Fixed (was: Started)

Sign in to add a comment