New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 883634 link

Starred by 1 user

Issue metadata

Status: Verified
Owner:
Closed: Nov 8
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 1
Type: Bug



Sign in to add a comment

Report Crostini usage asynchronously via DeviceStatusCollector

Project Member Reported by aoldemeier@google.com, Sep 13

Issue description

UserAgent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/69.0.3497.92 Safari/537.36

Steps to reproduce the problem:
There is currently no option for administrators to gain information about whether and how their users use Crostini.

What is the expected behavior?
There should be a policy (disabled by default) enabling administrators to trigger asynchronous device status reporting of the last Crostini app launch together with the termina version (with a three day granularity for privacy reasons).

What went wrong?
There is no policy, no hook to log the mentioned data, and no functionality in the DeviceStatusCollector to do the reporting.

Did this work before? No 

Chrome version: 70.0.3538.17  Channel: dev
OS Version: 70
Flash Version:
 
Cc: tbuckley@google.com bartfab@chromium.org snambiar@chromium.org poromov@chromium.org
Labels: -OS-Linux Enterprise-Triaged Target-70 OS-Chrome
Status: Started (was: Unconfirmed)
Labels: -Pri-2 Pri-1
Owner: aoldemeier@chromium.org
Labels: Proj-Crostini M-70
Labels: -Proj-Crostini Proj-Containers
Project Member

Comment 6 by bugdroid1@chromium.org, Sep 20

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

commit fc499f9357839bfe8d55f8b415ac3888115f8107
Author: Alex Oldemeier <aoldemeier@chromium.org>
Date: Thu Sep 20 21:50:35 2018

Report Crostini usage asynchronously via DeviceStatusCollector

Add a user policy for Crostini usage logging which is disabled by
default.
If this policy is active, log a time window for the last app launch
and the used Termina version in prefs.
Report these in DeviceStatusCollector.

Bug: 844468,  883634 
Test: Run unit and browser tests.
Change-Id: I90ba296c9284b987829f8907283873c8213fad9f
Reviewed-on: https://chromium-review.googlesource.com/1221947
Commit-Queue: Alex Oldemeier <aoldemeier@chromium.org>
Reviewed-by: Bartosz Fabianowski <bartfab@chromium.org>
Reviewed-by: Sergey Poromov <poromov@chromium.org>
Reviewed-by: Timothy Loh <timloh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#592959}
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/browser/chromeos/BUILD.gn
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/browser/chromeos/crostini/crostini_manager.cc
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/browser/chromeos/crostini/crostini_manager.h
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/browser/chromeos/crostini/crostini_pref_names.cc
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/browser/chromeos/crostini/crostini_pref_names.h
[add] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/browser/chromeos/crostini/crostini_reporting_util.cc
[add] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/browser/chromeos/crostini/crostini_reporting_util.h
[add] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/browser/chromeos/crostini/crostini_reporting_util_unittest.cc
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/browser/chromeos/crostini/crostini_util.cc
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/browser/chromeos/policy/device_status_collector.cc
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/browser/chromeos/policy/device_status_collector.h
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/browser/chromeos/policy/device_status_collector_browsertest.cc
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/browser/policy/configuration_policy_handler_list_factory.cc
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/browser/ui/views/crostini/crostini_installer_view.cc
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/common/pref_names.cc
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/test/BUILD.gn
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/chrome/test/data/policy/policy_test_cases.json
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/components/policy/proto/device_management_backend.proto
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/components/policy/resources/policy_templates.json
[modify] https://crrev.com/fc499f9357839bfe8d55f8b415ac3888115f8107/tools/metrics/histograms/enums.xml

Labels: Merge-Request-70
Project Member

Comment 8 by sheriffbot@chromium.org, Sep 21

Labels: -Merge-Request-70 Merge-Review-70 Hotlist-Merge-Review
This bug requires manual review: M70 has already been promoted to the beta branch, so this requires manual review
Please contact the milestone owner if you have questions.
Owners: benmason@(Android), kariahda@(iOS), geohsu@(ChromeOS), abdulsyed@(Desktop)

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
A build with the CL in it was smoke-tested over the weekend. It ran fine, no issues came up.
Labels: -Merge-Review-70 Merge-Approved-70
Project Member

Comment 11 by bugdroid1@chromium.org, Sep 27

Labels: -merge-approved-70 merge-merged-3538
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa

commit ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa
Author: Alex Oldemeier <aoldemeier@chromium.org>
Date: Thu Sep 27 14:21:22 2018

[Merge to M70] Report Crostini usage asynchronously via DeviceStatusCollector

Cherry-picked from master with conflicts resolved.

Note, this required coding to the pre-"CrostiniManager as a KeyedService" world.

Original commit: fc499f9357839bfe8d55f8b415ac3888115f8107

Add a user policy for Crostini usage logging which is disabled by
default.
If this policy is active, log a time window for the last app launch and the used Termina version in prefs.
Report these in DeviceStatusCollector.

Bug: 844468,  883634 
Change-Id: I46d4fb29cd1b53dfe6eb090de1f8cbcae7b59e8f
Reviewed-on: https://chromium-review.googlesource.com/1242803
Reviewed-by: Sergey Poromov <poromov@chromium.org>
Reviewed-by: Timothy Loh <timloh@chromium.org>
Reviewed-by: Bartosz Fabianowski <bartfab@chromium.org>
Cr-Commit-Position: refs/branch-heads/3538@{#704}
Cr-Branched-From: 79f7c91a2b2a2932cd447fa6f865cb6662fa8fa6-refs/heads/master@{#587811}
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/browser/chromeos/BUILD.gn
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/browser/chromeos/crostini/crostini_manager.cc
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/browser/chromeos/crostini/crostini_manager.h
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/browser/chromeos/crostini/crostini_pref_names.cc
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/browser/chromeos/crostini/crostini_pref_names.h
[add] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/browser/chromeos/crostini/crostini_reporting_util.cc
[add] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/browser/chromeos/crostini/crostini_reporting_util.h
[add] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/browser/chromeos/crostini/crostini_reporting_util_unittest.cc
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/browser/chromeos/crostini/crostini_util.cc
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/browser/chromeos/policy/device_status_collector.cc
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/browser/chromeos/policy/device_status_collector.h
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/browser/chromeos/policy/device_status_collector_browsertest.cc
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/browser/policy/configuration_policy_handler_list_factory.cc
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/browser/ui/views/crostini/crostini_installer_view.cc
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/common/pref_names.cc
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/test/BUILD.gn
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/chrome/test/data/policy/policy_test_cases.json
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/components/policy/proto/device_management_backend.proto
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/components/policy/resources/policy_templates.json
[modify] https://crrev.com/ed1cd841c1fdaa2b8200b80d7dcd745c7e35f4aa/tools/metrics/histograms/enums.xml

Status: Verified (was: Started)
This has been tested manually together with the CDM team, so closing as Verified.

Sign in to add a comment