Add 2 new enterprise policies to control the enablement of Crostini. New user policy CrostiniEnabled to control the user's ability to run Crostini. New device policy UnaffiliatedCrostiniAllowed to control unaffiliated user's ability to run Crostini.
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/e296bd11c29c0861bde989fba89287d3c271d28b commit e296bd11c29c0861bde989fba89287d3c271d28b Author: Tim Zheng <timzheng@google.com> Date: Wed Sep 05 19:16:30 2018 Add 2 Crostini policies. The 2 policies added are an user policy UserCrostiniEnabled and a device policy UnaffiliatedCrostiniAllowed. This CL adds their definitions and the related pref and setting name respectively. BUG= chromium:879737 TEST=Unit tests. Change-Id: I0b213251e47eec1d7b8ecceb63b8bf779c3f283e Reviewed-on: https://chromium-review.googlesource.com/1200524 Reviewed-by: Maksim Ivanov <emaxx@chromium.org> Reviewed-by: Dan Erat <derat@chromium.org> Reviewed-by: Nicholas Verne <nverne@chromium.org> Commit-Queue: Tim Zheng <timzheng@chromium.org> Cr-Commit-Position: refs/heads/master@{#588964} [modify] https://crrev.com/e296bd11c29c0861bde989fba89287d3c271d28b/chrome/browser/chromeos/crostini/crostini_pref_names.cc [modify] https://crrev.com/e296bd11c29c0861bde989fba89287d3c271d28b/chrome/browser/chromeos/crostini/crostini_pref_names.h [modify] https://crrev.com/e296bd11c29c0861bde989fba89287d3c271d28b/chrome/browser/chromeos/crostini/crostini_util.cc [modify] https://crrev.com/e296bd11c29c0861bde989fba89287d3c271d28b/chrome/browser/chromeos/crostini/crostini_util.h [modify] https://crrev.com/e296bd11c29c0861bde989fba89287d3c271d28b/chrome/browser/chromeos/policy/device_policy_decoder_chromeos.cc [modify] https://crrev.com/e296bd11c29c0861bde989fba89287d3c271d28b/chrome/browser/chromeos/settings/device_settings_provider.cc [modify] https://crrev.com/e296bd11c29c0861bde989fba89287d3c271d28b/chrome/browser/policy/configuration_policy_handler_list_factory.cc [modify] https://crrev.com/e296bd11c29c0861bde989fba89287d3c271d28b/chrome/test/data/policy/policy_test_cases.json [modify] https://crrev.com/e296bd11c29c0861bde989fba89287d3c271d28b/chromeos/settings/cros_settings_names.cc [modify] https://crrev.com/e296bd11c29c0861bde989fba89287d3c271d28b/chromeos/settings/cros_settings_names.h [modify] https://crrev.com/e296bd11c29c0861bde989fba89287d3c271d28b/components/policy/proto/chrome_device_policy.proto [modify] https://crrev.com/e296bd11c29c0861bde989fba89287d3c271d28b/components/policy/resources/policy_templates.json [modify] https://crrev.com/e296bd11c29c0861bde989fba89287d3c271d28b/tools/metrics/histograms/enums.xml
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/97de8a01f44d865e9789f8142b4a7443263e03c5 commit 97de8a01f44d865e9789f8142b4a7443263e03c5 Author: Tim Zheng <timzheng@google.com> Date: Thu Sep 06 22:48:44 2018 Correct a policy test case. BUG= chromium:879737 TEST=This is a test case. Change-Id: I57c11e9ad663081ec6ee56b5dd4afa58db470384 Reviewed-on: https://chromium-review.googlesource.com/1211113 Reviewed-by: Maksim Ivanov <emaxx@chromium.org> Commit-Queue: Tim Zheng <timzheng@chromium.org> Cr-Commit-Position: refs/heads/master@{#589347} [modify] https://crrev.com/97de8a01f44d865e9789f8142b4a7443263e03c5/chrome/test/data/policy/policy_test_cases.json
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/f1ef41ea2afebeb7fb4d04e8176f731648aeedea commit f1ef41ea2afebeb7fb4d04e8176f731648aeedea Author: Tim Zheng <timzheng@google.com> Date: Fri Sep 07 18:18:54 2018 Add a device policy to DeviceSettingsProvider. This was missed in a previous CL crrev.com/c/1200524. BUG= chromium:879737 TEST=Browsertests passed with code that uses this setting. Change-Id: I6ca354c0a781a16d17fb2be5c12203209992e25b Reviewed-on: https://chromium-review.googlesource.com/1211731 Reviewed-by: Dan Erat <derat@chromium.org> Reviewed-by: Steven Bennetts <stevenjb@chromium.org> Commit-Queue: Tim Zheng <timzheng@chromium.org> Cr-Commit-Position: refs/heads/master@{#589588} [modify] https://crrev.com/f1ef41ea2afebeb7fb4d04e8176f731648aeedea/chrome/browser/chromeos/settings/device_settings_provider.cc
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/2957e4e30d991f59423a165968da698517dd5468 commit 2957e4e30d991f59423a165968da698517dd5468 Author: Tim Zheng <timzheng@google.com> Date: Fri Sep 07 18:50:12 2018 Check 2 new Crostini policies. BUG= chromium:879737 TEST=Manually tested on an eve device with YAPS. Change-Id: I9a99d5a76178ba71fcd4017c6e43f1fad0fc77b8 Reviewed-on: https://chromium-review.googlesource.com/1208827 Commit-Queue: Tim Zheng <timzheng@chromium.org> Reviewed-by: Nicholas Verne <nverne@chromium.org> Cr-Commit-Position: refs/heads/master@{#589611} [modify] https://crrev.com/2957e4e30d991f59423a165968da698517dd5468/chrome/browser/chromeos/crostini/crostini_util.cc
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/63d275de09b05bce3a05936cda532423226a40b4 commit 63d275de09b05bce3a05936cda532423226a40b4 Author: Tim Zheng <timzheng@google.com> Date: Tue Sep 11 00:11:13 2018 Add 2 Crostini policies. The 2 policies added are an user policy UserCrostiniEnabled and a device policy UnaffiliatedCrostiniAllowed. This CL adds their definitions and the related pref and setting name respectively. BUG= chromium:879737 TEST=Unit tests. TBR=timzheng@google.com (cherry picked from commit e296bd11c29c0861bde989fba89287d3c271d28b) Change-Id: I0b213251e47eec1d7b8ecceb63b8bf779c3f283e Reviewed-on: https://chromium-review.googlesource.com/1200524 Reviewed-by: Maksim Ivanov <emaxx@chromium.org> Reviewed-by: Dan Erat <derat@chromium.org> Reviewed-by: Nicholas Verne <nverne@chromium.org> Commit-Queue: Tim Zheng <timzheng@chromium.org> Cr-Original-Commit-Position: refs/heads/master@{#588964} Reviewed-on: https://chromium-review.googlesource.com/1217907 Cr-Commit-Position: refs/branch-heads/3538@{#258} Cr-Branched-From: 79f7c91a2b2a2932cd447fa6f865cb6662fa8fa6-refs/heads/master@{#587811} [modify] https://crrev.com/63d275de09b05bce3a05936cda532423226a40b4/chrome/browser/chromeos/crostini/crostini_pref_names.cc [modify] https://crrev.com/63d275de09b05bce3a05936cda532423226a40b4/chrome/browser/chromeos/crostini/crostini_pref_names.h [modify] https://crrev.com/63d275de09b05bce3a05936cda532423226a40b4/chrome/browser/chromeos/crostini/crostini_util.cc [modify] https://crrev.com/63d275de09b05bce3a05936cda532423226a40b4/chrome/browser/chromeos/crostini/crostini_util.h [modify] https://crrev.com/63d275de09b05bce3a05936cda532423226a40b4/chrome/browser/chromeos/policy/device_policy_decoder_chromeos.cc [modify] https://crrev.com/63d275de09b05bce3a05936cda532423226a40b4/chrome/browser/chromeos/settings/device_settings_provider.cc [modify] https://crrev.com/63d275de09b05bce3a05936cda532423226a40b4/chrome/browser/policy/configuration_policy_handler_list_factory.cc [modify] https://crrev.com/63d275de09b05bce3a05936cda532423226a40b4/chrome/test/data/policy/policy_test_cases.json [modify] https://crrev.com/63d275de09b05bce3a05936cda532423226a40b4/chromeos/settings/cros_settings_names.cc [modify] https://crrev.com/63d275de09b05bce3a05936cda532423226a40b4/chromeos/settings/cros_settings_names.h [modify] https://crrev.com/63d275de09b05bce3a05936cda532423226a40b4/components/policy/proto/chrome_device_policy.proto [modify] https://crrev.com/63d275de09b05bce3a05936cda532423226a40b4/components/policy/resources/policy_templates.json [modify] https://crrev.com/63d275de09b05bce3a05936cda532423226a40b4/tools/metrics/histograms/enums.xml
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/e4741b72b5f3c89d89ebb07456579551e004046e commit e4741b72b5f3c89d89ebb07456579551e004046e Author: Tim Zheng <timzheng@google.com> Date: Tue Sep 11 00:11:29 2018 Add a device policy to DeviceSettingsProvider. This was missed in a previous CL crrev.com/c/1200524. BUG= chromium:879737 TEST=Browsertests passed with code that uses this setting. Change-Id: I6ca354c0a781a16d17fb2be5c12203209992e25b Reviewed-on: https://chromium-review.googlesource.com/1211731 Reviewed-by: Dan Erat <derat@chromium.org> Reviewed-by: Steven Bennetts <stevenjb@chromium.org> Commit-Queue: Tim Zheng <timzheng@chromium.org> Cr-Original-Commit-Position: refs/heads/master@{#589588}(cherry picked from commit f1ef41ea2afebeb7fb4d04e8176f731648aeedea) Reviewed-on: https://chromium-review.googlesource.com/1217518 Reviewed-by: Jeremy Klein <jlklein@chromium.org> Cr-Commit-Position: refs/branch-heads/3538@{#260} Cr-Branched-From: 79f7c91a2b2a2932cd447fa6f865cb6662fa8fa6-refs/heads/master@{#587811} [modify] https://crrev.com/e4741b72b5f3c89d89ebb07456579551e004046e/chrome/browser/chromeos/settings/device_settings_provider.cc
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/4ad57a66c3e3c21faa14fb8cddc8f1a058a59ea9 commit 4ad57a66c3e3c21faa14fb8cddc8f1a058a59ea9 Author: Tim Zheng <timzheng@google.com> Date: Tue Sep 11 00:11:45 2018 Check 2 new Crostini policies. BUG= chromium:879737 TEST=Manually tested on an eve device with YAPS. Change-Id: I9a99d5a76178ba71fcd4017c6e43f1fad0fc77b8 Reviewed-on: https://chromium-review.googlesource.com/1208827 Commit-Queue: Tim Zheng <timzheng@chromium.org> Reviewed-by: Nicholas Verne <nverne@chromium.org> Cr-Original-Commit-Position: refs/heads/master@{#589611}(cherry picked from commit 2957e4e30d991f59423a165968da698517dd5468) Reviewed-on: https://chromium-review.googlesource.com/1217711 Reviewed-by: Jeremy Klein <jlklein@chromium.org> Cr-Commit-Position: refs/branch-heads/3538@{#261} Cr-Branched-From: 79f7c91a2b2a2932cd447fa6f865cb6662fa8fa6-refs/heads/master@{#587811} [modify] https://crrev.com/4ad57a66c3e3c21faa14fb8cddc8f1a058a59ea9/chrome/browser/chromeos/crostini/crostini_util.cc
Comment 1 by bugdroid1@chromium.org
, Sep 5