[BatterySaver] Fix the vulnerability of ExtremeBatterySaver
Enable the Standard Battery Saver directly if this is the first time
that user see the low battery notification for enabling battery saver and
the device is locked.
Flag: com.android.settingslib.flags.extreme_power_low_state_vulnerability
Bug: 346513692
Test: Manual Test and Unit Test
Test: http://ab/I38500010293424439 (robotest)
Change-Id: Ie2538980f2b8fef46b213f39cb9f56bf17305e8c
diff --git a/packages/SettingsLib/aconfig/settingslib.aconfig b/packages/SettingsLib/aconfig/settingslib.aconfig
index 38c871c..403e219 100644
--- a/packages/SettingsLib/aconfig/settingslib.aconfig
+++ b/packages/SettingsLib/aconfig/settingslib.aconfig
@@ -102,3 +102,13 @@
purpose: PURPOSE_BUGFIX
}
}
+
+flag {
+ name: "extreme_power_low_state_vulnerability"
+ namespace: "pixel_energizer"
+ description: "the battery saver can pause all non-essential apps and their corresponding notification when device is in locked state to introduce the security vulnerability"
+ bug: "346513692"
+ metadata {
+ purpose: PURPOSE_BUGFIX
+ }
+}