Use a whitelist to control which packages may use location piercing
settings on LocationRequest.
Test: Manually
Bug: 118883513
Change-Id: I16e8496c49b6bef016cb7f090969ed97a39e38c2
When user selects a eSIM subscription, Settings app informs Telephony.
Telephony needs to take actions such as writting it into global
settings, switch profiles and notify registrants, for example
AlternativeNetworkAccessService.
Bug: 120945564
Test: unittest
Change-Id: I846d9444aac368d183e06744c9eb8aa0c08dfe6a
Instead of keeping reading the whitelist everytime, we want to store it in
Settings.Global variable and reuse it later.
BUG: 120869311
Test: Build, flash and boot.
Change-Id: I5e39757383c5ba7d31af7efb3e6e8a2996e669f4
This introduces a setting that turns off sticky Battery Saver above a
certain threshold and disables Battery Saver if it was enabled due to
the sticky setting.
Bug: 112232746
Test: atest com.android.server.power.batterysaver.BatterySaverStateMachineTest
Test: atest android.provider.SettingsBackupTest
Change-Id: Ib9a9fd627a56529404b41fbabedf8bb4a372074e
Vendors can still set the default behavior by pm.dexopt.priv-app-oob*
system properties, but still the experiment flag can override the
behavior.
This change also removes the audit log because the setting provider is
not ready. The old code works because we use the default system property
(which may be inconsistent to settings).
Test: cmd package compile -m speed -f com.google.android.dialer
am start com.google.android.dialer
cat /proc/`pidof com.google.android.dialer`/maps |grep oat |grep /data
# Compiled code IS mapped as executable
Test: device_config put fsi_boot oob_enabled true
pkill com.google.android.dialer; am start ...
# Compiled code is NOT mapped as executable
Test: device_config put fsi_boot oob_enabled false
# Compiled code IS mapped as executable
Test: device_config put fsi_boot oob_enabled true
device_config put fsi_boot oob_whitelist com.android.vending,com.example
# Compiled code is NOT mapped as executable
Test: device_config put fsi_boot oob_enabled true
device_config put fsi_boot oob_whitelist com.android.vending,com.google.android.dialer
# Compiled code IS mapped as executable
Test: device_config reset untrusted_clear
# Compiled code IS mapped as executable
Test: atest DexManagerTests
Bug: 120793002
Change-Id: I67f29ac593bd2c33dc8c75ce2135cf9ec5490650
Instead of generating only a handful of thumbnail "kinds", none of
which scale with display density, shift to generating only a single
thumbnail whose dimensions are limited to half the smallest screen
width of the device.
This change also shifts to storing thumbnails on the relevant volume
where the source data actually came from. This solves the problem
of having to GC thumbnails for a storage device that we haven't seen
in a long time.
Bug: 119887587
Test: atest cts/tests/tests/provider/src/android/provider/cts/MediaStore*
Change-Id: I2ce6c5051b7058d2f1bba523c077e84a1f0b46e9
This reverts commit 16522412eb.
Reason for revert: solution needs some adjustments - will update with a better solution.
Change-Id: I74ed92225017a8c1ac23176ed176663acfef7578
When callers are inserting or updating raw "_data" paths, we need to
sanity check them to make sure they're not "crossing the streams"
between storage devices. For example, it would be really broken to
insert a file on the SD card into the "internal" storage volume.
This also enforces that callers don't "cross the streams" between
multiple storage volumes on devices that support them, since
otherwise they'd end up with very confusing behavior, such as
the same underlying file being inserted into multiple databases.
Also, the "internal" storage volume should really only be used for
common media (such as ringtones), and it shouldn't be allowed to
point into private app data directories, since MODE_WORLD_READABLE
has been deprecated for many years now.
Bug: 117932814
Test: atest MediaProviderTests
Test: atest cts/tests/tests/media/src/android/media/cts/MediaScanner*
Test: atest cts/tests/tests/provider/src/android/provider/cts/MediaStore*
Change-Id: I267eacd45bbd270b8ce9b28de9d6e209f780f31a
If a non-persistent service is being restarted and it was killed due to
low memory previously, instead of restarting the service in one second,
we now restart it based on its last known oom_adj value. The backoff
logic of consistent restarts remains the same.
Additionally, when the service is due to restart, if the memory pressure
is still considered to be critical, the new logic will further delay the
service restart.
Initial test results: # of restarts dropped by 40-50% on average with
the optimized logic when the memory pressure was gradually increased.
Tested manually via memeater. Increased the memory pressure by 500 mb
at a time via the following command: adb shell memeater 500
On a 4gb device, no significant restarts were noticed when memory
pressure was increased by 2gb in total. When increased by 3gb in total,
services started to restart and the above results were observed via
the logged output over a 5 min period.
Bug: 79848281
Test: manually (steps listed above)
Change-Id: Idcd1300882321c6033e569736150a8bf7889678b
The notification_assistant package will contain flags controling the
default Android Platform implementation of the Notification Assistant
(named ExtServices).
The flags will be read in
android.ext.services.notification.AssistantSettings.
Bug: 120792826
Test: build
Change-Id: Ib57ca8bb707e1582f315390d5d2eb833033b7d25
- Add nullability annotations for some methods
- Update the java doc of isRootsUri to make it more clear
Change-Id: I8b065d526e11fe8d71bb1aec223918e7559967e0
Fix: 122549058
Test: make
For system (assistant) generated smart replies we want to ensure the
replies don't seem biased (see example [1]). Therefore we here add an
experiment flag that determines the minimum number of replies N to show
in a notification. If we can't fit N replies into the notification we
remove all replies from that notification (i.e. we show zero replies).
[1] Example of biased replies:
Message: "Hi, how are you?"
Replies: "Good", "Great!", "Bad"
using only one reply here ("Good") might be seen as biased.
Bug: 120779592
Test: atest SystemUITests
Test: call "adb shell settings put global
smart_replies_in_notifications_flags enabled=true,min_num_replies=X" for
different values of X and ensure the behaviour is correct.
Change-Id: I898850f7895d0fd43ec6788095162f3138cd62cb
NetworkMonitor lives in the NetworkStack which must only use system
APIs. This includes constants used by NetworkMonitor and captive portal
login.
Bug: 112869080
Test: m
(Cherry-pick of aosp I4879568d3fbf9435767c8d4d0ab5198d421a2f4f)
Change-Id: I8b5f0bb61c3ef0d2f33af7dd67b72ac6c5a1d1b5
For experiment flag testing, adding netd flag in DeviceConfig.
Test: add sepolicy, m -j, check GetServerConfigurableFlag function in netd
Bug:122050512
Change-Id: Ie24cdd145d955b1d6d6bae8e4b5c20740eb8ed95