DescriptionReporting a policy error after detecting mistyped policies.
After this changelist policy::Schema is used to validate policy contents.
Mistyped values trigger PolicyWatcher::PolicyErrorCallback.
Misspelled names trigger just a LOG(WARNING) message.
As a follow-up to using policy::Schema for validation, we can remove ad-hoc
fallback values for 2 out of 15 or our policies that used to be stored in
PolicyWatcher::bad_type_values_. This can be replaced with a CHECK that
verifies that the Schema indeed didn't pass through any mistyped values.
As another follow-up we can remove the TODO comment asking to start using
PolicyWatcher::PolicyErrorCallback again. We can also remove
SignalTransientPolicyError which is not used anymore at this point (we can
hesitantly consider reintroducing it if needed to handle detection of
unparseable files; this is still some time in the future though).
BUG=427513
TEST=remoting_unittests + manual verification on Win and Linux via TestRealChromotingPolicy
Committed: https://crrev.com/e5d69ea2ccfe129eccd06d3b1de43a7092ee201d
Cr-Commit-Position: refs/heads/master@{#317646}
Patch Set 1 : #
Total comments: 8
Patch Set 2 : Addressed code review feedback from Sergey. #Patch Set 3 : Rebasing... #
Messages
Total messages: 18 (10 generated)
|