Fix message at login screen for devices with old state

Nvram-based boot lockbox was first introduce in M74. Through TPM 2.0,
nvram is initialized (think: empty set). Device initialized before M74
has uninitialized value (think: nil) from boot lockbox's perspective.

When the nvram is uninitialized, the QueryAdbSideload D-Bus call returns
with error NEED_POWERWASH, since powerwash is the only way to initialize
the value.

NEED_POWERWASH can only be returned on old devices, and on old devices
adb sideloading is not available. Thus, it is safe to assume that when
NEED_POWERWASH is returned, the device does not have sideloaded apps.

      2) flash to update to M80  # see warning message at login screen
      3) apply this fix  # warning message is gone

Test: 1) flash the device to M73, powerwash to initialize TPM state, login
Bug: 1038672
Change-Id: Iae7af4905d1b6824cba0c25b9cd4c69277c3d893
Commit-Queue: Victor Hsieh <>
Reviewed-by: Xiyuan Xia <>
Cr-Commit-Position: refs/heads/master@{#731749}
1 file changed