Chromium Code Reviews
DescriptionMerge "cros: Fix flaky owner detection"
> When owner key is generated for a consumer owner, OwnerKeySet is
> called on both DeviceSettingsService and OwnerSettingsServiceChromeOS.
> Code that watches for ownership signal from DeviceSettingsService
> (either as an observer or via NOTIFICATION_OWNERSHIP_STATUS_CHANGED)
> also expects that the private part of the owner is available at the
> time the signal is generated. However, the private key loading
> in OwnerSettingsServiceChromeOS is independent of load operations
> in DeviceSettingsService. The private key may or may not be loaded
> when a load operation finishes. The CL adds an explicit flag about
> whether a consumer ownership is going to be established. When the
> flag is set, DeviceSettingsService defers all loads until InitOwner
> is called, which happens when the private key is loaded.
>
> Another problem is that a bool flag |is_current_user_owner_| is
> used but it is not updated when switching active user. This causes
> incorrect value returned for IsCurrentUserOwner call. The CL fixes
> the problems by replacing the bool flag with comparing active user
> AccountId with owner AccountId. Security is not reduced because the
> owner account id is part of the signed policy blob and only set to
> UserManager after policy blob is validated.
>
> BUG=702308, 706820
> TEST=DeviceSettingsServiceTest.LoadDeferredDuringOwnershipEastablishment
>
> Review-Url: https://codereview.chromium.org/2779973007
> Cr-Commit-Position: refs/heads/master@{#461835}
> (cherry picked from commit c8310bb706ce377ab64aac321f6e8f286826b360)
Review-Url: https://codereview.chromium.org/2798343003 .
Cr-Commit-Position: refs/branch-heads/3029@{#606}
Cr-Branched-From: 939b32ee5ba05c396eef3fd992822fcca9a2e262-refs/heads/master@{#454471}
Committed: https://chromium.googlesource.com/chromium/src/+/33ef6173cda18bb0e9bf1d890318216b59483207
Patch Set 1 #
Messages
Total messages: 2 (1 generated)
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||