Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat clipboard access #503

Draft
wants to merge 316 commits into
base: 14
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
316 commits
Select commit Hold shift + click to select a range
04a85d9
CarrierConfig: Do not mark dun APN types as read only
flawedworld Feb 9, 2022
d0db02d
CarrierConfig: Always show ICCID
flawedworld Mar 5, 2022
7914338
CarrierConfig: allow toggling VoWiFi while roaming by default
girlbossceo Mar 24, 2023
c0fc8a8
enable secondary user logout support by default
flawedworld Oct 15, 2021
019a8f4
enable backup service for non-owner users
empratyush May 2, 2021
2e7efc3
increase default max password length to 64
thestinger Jun 29, 2017
dd205ca
increase default max password length to 128
neelchauhan May 24, 2024
8c4a69d
GrapheneOS boot logo mask
thestinger May 11, 2019
e68d4a0
use black wallpaper by default
thestinger Mar 7, 2022
b6ac8a3
stop auto-granting location to system browsers
thestinger Mar 17, 2019
b14357d
appop: Save discrete app op history for more permissions
kdrag0n Oct 11, 2021
e5320e8
add check for empty TTS engine name
thestinger Dec 20, 2020
4a7c38f
Add a config to state whether a device supports increased touch sensi…
lzlrd Jun 30, 2021
a650d51
stop enforcing camera sound for certain carriers
thestinger Feb 11, 2022
cbf2b06
colors: Switch to GrapheneOS blue color palette for Material You
kdrag0n Mar 7, 2022
26e2241
improve PendingIntent security check compatibility
thestinger Mar 18, 2022
84e286f
Show USB icon in notification instead of generic system icon
kdrag0n Oct 6, 2020
c26553a
Sharesheet: Display two rows of max ranked targets
luk1337 Oct 28, 2020
166689e
extsettings: add a set of helper classes for defining system settings
muhomorr Feb 12, 2023
efe5524
add exec-based spawning support
thestinger Mar 14, 2015
2ca803f
disable exec spawning when using debugging options
thestinger May 22, 2019
339e8ce
add parameter for avoiding full preload with exec
thestinger May 14, 2019
7d8c2e3
pass through fullPreload to libcore
thestinger Sep 11, 2019
16d8a79
disable OpenGL preloading for exec spawning
thestinger May 14, 2019
35510f9
Revert "disable OpenGL preloading for exec spawning"
thestinger Oct 16, 2021
a763e2d
disable resource preloading for exec spawning
thestinger May 14, 2019
36eb338
disable class preloading for exec spawning
thestinger May 14, 2019
81183bb
disable WebView reservation for exec spawning
thestinger May 14, 2019
d44e89b
disable JCA provider warm up for exec spawning
thestinger May 14, 2019
dbb25dd
disable preloading classloaders for exec spawning
thestinger Sep 11, 2019
98837c8
disable preloading HALs for exec spawning
thestinger Sep 11, 2019
2224acd
pass through runtime flags for exec spawning and implement them in th…
randomhydrosol Oct 30, 2020
0ef2f08
exec spawning: don't close the binder connection when the app crashes
muhomorr Aug 8, 2022
a2656c5
add a wrapper for execveat(2)
muhomorr Aug 14, 2022
cf93e27
zygote: define runtime flags that depend on exec spawning
muhomorr Aug 14, 2022
dea425e
exec spawning: support runtime resource overlays
muhomorr Mar 30, 2023
6df7185
exec spawning: support disabling hardened_malloc and extended VA space
muhomorr Aug 14, 2022
f8c7c8f
exec spawning: add workaround for late init of ART userfaultfd GC
muhomorr Apr 9, 2024
c17cb20
use HTTPS X-Time header for time updates instead of NTP
muhomorr Jan 23, 2024
1f3a2cc
extend auto-time setting to forced time updates
muhomorr Jan 24, 2024
6314855
reduce system clock drift warning
thestinger Feb 22, 2023
c41ef6b
core/config: disable using telephony-based auto time
thestinger Feb 22, 2023
9baf0ae
add system package check methods to PackageUtils
muhomorr Jun 22, 2023
ca8c13e
filter out non-system packages from location indicator exemptions
muhomorr Jun 22, 2023
71ea434
filter out non-system packages from getLocationBypassPackages() result
muhomorr Jun 22, 2023
3040274
define package name of first-party app source
muhomorr Jan 3, 2024
484ec3d
SystemUI: require unlocking to use QS tiles by default
muhomorr Mar 11, 2024
b96bb26
SystemUI: allow to use some QS tiles while device is locked
muhomorr Mar 11, 2024
eb8b03b
SystemUI: enable NFC quick settings tile
thestinger Mar 17, 2019
cc90cd9
SystemUI: Enable production-ready feature flags
kdrag0n Mar 14, 2022
3fafb61
SystemUI: Use new privacy indicators for location
kdrag0n Oct 11, 2021
0417ea5
SystemUI: fully enable location indicators by default
thestinger Aug 17, 2022
98b8eba
SystemUI: specify config_sceenshotWorkProfileFilesApp
muhomorr Jun 18, 2023
b79d11c
SystemUI: improve media projection dialog wording
muhomorr Jan 22, 2023
d801221
SystemUI: add Battery share & Battery share quick tiles
empratyush Jun 21, 2022
1a884b6
SystemUI: change default quick tiles and quick tile order
thestinger Oct 19, 2021
7100602
SystemUI: make screenshot sound use touch sounds setting
girlbossceo Mar 19, 2023
41a7769
SystemUI: have NfcTile get an NfcAdapter directly
inthewaves Sep 20, 2020
9e0f409
SystemUI: apply "Add users from lock screen" setting to guest users
muhomorr Jun 23, 2023
09d6384
SystemUI: Allow customizing lock screen shortcuts via ThemePicker
quh4gko8 Oct 10, 2023
7866059
Add config to exempt telephony-related app from location indicators
kdrag0n Feb 17, 2022
863200b
exempt some system packages from status bar privacy indicator
thestinger Apr 17, 2022
782a1dc
allow PackageInstaller to use platform APIs
muhomorr Mar 5, 2024
f97e80b
PackageInstaller: link "App info" screen from the uninstallation dialog
muhomorr Apr 17, 2022
8651a76
PackageInstaller: make sure install confirmation returns a result
muhomorr Jun 2, 2022
c901742
disable support for pre-approving PackageInstaller sessions
muhomorr Dec 22, 2023
3f793e3
define READ_LOGS_FULL permission for promptless logcat access
muhomorr Jan 6, 2024
abf0ef1
add APIs for launching LogViewer app
muhomorr Jan 6, 2024
3daf5b1
add helpers for system_server extensions
muhomorr Jul 31, 2022
74400a9
Warn the user if they are using a prototype Pixel device
flawedworld Jun 15, 2022
852f5d9
Support forwarding notifications from other users
girlbossceo Mar 19, 2022
ea58f95
DeviceIdleJobsController: don't ignore whitelisted system apps
muhomorr Jul 7, 2022
6c29f84
do not allow disabling app visibility filtering
muhomorr Apr 6, 2023
5b9e385
add hooks for modifying PackageManagerService behavior
muhomorr Mar 27, 2023
a6f8dcb
rename AppsFilterImpl.grantImplicitAccess method
muhomorr Apr 30, 2024
b9c5483
add hooks for modifying ActivityThread behavior
muhomorr Aug 18, 2023
475a9f1
AppBindArgs: infrastructure for passing extra args to app process init
muhomorr May 16, 2023
d59569a
infrastructure for custom handling of known packages
muhomorr Dec 20, 2023
18a6e75
gosps: support for per-app GrapheneOS-specific persistent state
muhomorr Jul 31, 2022
89401a1
extend excludedMethods list in AndroidPackageTest
muhomorr Jun 2, 2024
717ad35
add method for updating cached package permission state
muhomorr Dec 18, 2023
b799acc
PackageHooks: infrastructure for per-package hooks in system_server
muhomorr Dec 18, 2023
534dc8b
add base class for complex per-app switches
muhomorr Sep 24, 2023
1d88b35
infrastructure for spoofing self permission checks
muhomorr Jul 31, 2022
a3956b7
infrastructure for special runtime permissions
muhomorr Feb 9, 2023
81a163f
add special runtime permission for other sensors
muhomorr Feb 9, 2023
d805133
notify the user when sensors access is denied by OTHER_SENSORS perm
muhomorr Oct 4, 2022
4a8364c
make INTERNET into a special runtime permission
thestinger Mar 17, 2019
fbb36ad
improve compatibility of INTERNET special runtime permission
muhomorr Jul 31, 2022
164449a
don't run jobs that need connectivity in apps that lack INTERNET perm
muhomorr May 19, 2023
8ab9b84
PackageInstallerUI: an option to skip auto-grant of INTERNET permission
muhomorr Oct 7, 2022
6544049
use permanent fingerprint lockout immediately
thestinger Sep 12, 2017
55439ae
add system property for disabling keyguard camera
thestinger Jul 25, 2017
9ae4f69
add auto-reboot feature
muhomorr Jan 13, 2024
5df5c08
infrastructure for the Storage Scopes feature
muhomorr Jul 31, 2022
4de72e8
sscopes: temp: disable incomplete handling of READ_MEDIA_VISUAL_USER_…
muhomorr Oct 5, 2023
38ffe67
control access to Android/obb directory with a GosPackageState flag
muhomorr Jul 31, 2022
214caf2
add an option to show the details of an application error to the user
muhomorr Aug 8, 2022
93c53e5
ErrorDialogController: do not auto-dismiss crash dialogs
muhomorr Oct 1, 2023
6e95cd4
Set always-on and lockdown on by default on first vpn connection at s…
quh4gko8 Aug 1, 2022
dc86d99
pre-grant POST_NOTIFICATIONS to more system apps
muhomorr Aug 22, 2022
4324957
allow privileged installer to search for packages across all users
muhomorr Nov 23, 2022
64783ac
extend original-package renaming to provider authorities for Vanadium
muhomorr Nov 5, 2022
dc18582
extend original-package renaming to static launcher shortcuts
muhomorr Nov 23, 2022
c68a3f3
bugfix: properly acquire package state from original package
quh4gko8 Mar 13, 2024
164fcc9
disable package parser cache
muhomorr Jan 30, 2023
1e5dfde
perform additional boot-time checks on system package updates
muhomorr Jan 31, 2023
735072c
allow out-of-band package updates to use original-package system
muhomorr Jan 27, 2023
6a97892
require fs-verity when installing system package updates
muhomorr Jan 31, 2023
e96a72c
don't allow updating system packages to the same versionCode
muhomorr Dec 27, 2022
8bed80d
allow privileged installers to use getSharedLibraries(MATCH_ANY_USER)
muhomorr Mar 30, 2024
e0798fd
allow only first party app source and shell to update system packages
muhomorr May 2, 2024
1faed04
Remove build fingerprint from screenshot EXIF
girlbossceo Apr 29, 2022
1634722
add toggle for screenshot timestamp EXIF metadata
girlbossceo Feb 18, 2023
0287c59
SUPL: Don't send IMSI / Phone number to SUPL server
MSe1969 Oct 29, 2018
fe7f1fb
add GNSS SUPL setting
muhomorr Mar 3, 2023
82fff6f
allow privileged installers to maintain a global list of busy packages
muhomorr Mar 4, 2023
82ae1ea
add option to scramble PIN layout
muhomorr Feb 24, 2023
ab98b0d
enable LOCK_PIN_ENHANCED_PRIVACY setting by default
muhomorr Jun 14, 2023
e6d03ef
don't crash apps that depend on missing Gservices provider
muhomorr Mar 26, 2023
9865fd4
integrate Google's EuiccSupportPixel package
muhomorr Mar 27, 2023
061d30f
integrate Google's eUICC LPA package (EuiccGoogle)
muhomorr May 30, 2023
2d4c72d
do not auto-grant Camera permission to the eUICC LPA UI app
muhomorr Mar 19, 2023
a9d8918
gmscompat: add compatibility layer for unprivileged GMS
thestinger Jun 6, 2023
b7a2fa7
require vendor camera extensions package to be a system app by default
muhomorr Mar 30, 2023
4d18ff8
add config for Pixel Camera Services
muhomorr Jan 9, 2024
88163b8
infrastructure for creating per-package seinfo overrides
muhomorr Mar 30, 2023
98d5b9e
support denying special access to hardware accelerators by Google apps
muhomorr Apr 6, 2023
de1f278
add GNSS PSDS setting
muhomorr May 2, 2023
d530979
support redirecting ContentProvider calls to another provider
muhomorr May 16, 2023
0f6b7f4
infrastructure for the Contact Scopes feature
muhomorr May 16, 2023
1a0581c
add connectivity checks setting and its migration from Settings.Global
muhomorr May 25, 2023
928afc6
Wi-Fi auto turn off
muhomorr Jul 31, 2022
bc6c4c2
Bluetooth auto turn off
muhomorr Jul 31, 2022
0215116
implement dynamic deny_new_usb toggle mode
thestinger Jun 16, 2016
ee0eb1a
add support for hooking LocationManager methods
muhomorr Jun 19, 2023
a1d2083
improve compat with apps that try to access network location provider
muhomorr Jun 19, 2023
ef7564f
add RemoteKeyProvisioning server override setting
muhomorr Aug 10, 2023
029c139
support showing dexopt progress during boot
muhomorr Oct 3, 2023
2515677
don't skip AOT compilation of apps that weren't recently used
muhomorr Nov 14, 2022
bd9d061
do not delete compiled code (OAT files) of hibernated apps
muhomorr Oct 11, 2023
1561f0c
disable OtaDexoptService
muhomorr Oct 23, 2023
420d4e8
add notification-based UI for the background dexopt job
muhomorr Oct 23, 2023
f035ee6
infrastructure for per-package dex2oat compiler filter overrides
muhomorr Oct 31, 2023
c1b5fe5
always use speed dex2oat compiler filter for VPN service packages
muhomorr Nov 1, 2023
7289f50
add helper class for launching non-standard Settings intents
muhomorr Nov 15, 2023
753c8cc
add helper class for notifications that link AppSwitch UI
muhomorr Nov 8, 2023
0dfebd3
infrastructure for passing extra args to Zygote and WebViewZygote
muhomorr Sep 23, 2023
07c62c7
infrastructure for passing SELinux flags to the kernel
muhomorr Sep 24, 2023
d5edae5
add per-app setting for hardened_malloc and extended VA space
muhomorr Sep 26, 2023
4f88a59
always stop app zygotes when app is being force-stopped
muhomorr Nov 8, 2023
41c1a76
add per-app native debugging setting
muhomorr Sep 26, 2023
13ef3fc
add per-app dynamic code execution settings
muhomorr Sep 26, 2023
d7c7db5
add a test for the new per-app hardening features
muhomorr Sep 20, 2023
ddf2779
add per-app memory tagging setting
muhomorr Nov 5, 2023
beffb29
add system API for getting app info by PID
muhomorr Nov 8, 2023
78fa79e
infrastructure for handling callbacks from logd to system_server
muhomorr Nov 8, 2023
5364316
infrastructure for showing notifications about SELinux TSEC_FLAG denials
muhomorr Nov 15, 2023
7fe22c2
show notification after app is blocked from accessing ptrace
muhomorr Nov 19, 2023
76e54ff
fix rate limiting for non-app tombstones
muhomorr Nov 8, 2023
65fb615
DropBoxManager: fix TreeSet API contract violations
muhomorr Dec 23, 2023
c4b9473
DropBox: skip spurious system_server_crash entries
muhomorr Jan 15, 2024
23ebb0a
DropBox: skip fsck.f2fs results that don't contain errors
muhomorr Jan 16, 2024
b9780e3
notify the user about notable system journal entries
muhomorr Nov 8, 2023
4f6fd62
Widevine provisioning setting
maade93791 Sep 29, 2023
a0b3fd8
add a method for sending BOOT_COMPLETED broadcast to a specific package
muhomorr Dec 23, 2023
d81793b
define READ_DEVICE_SERIAL_NUMBER permission for Build.getSerial() access
muhomorr Dec 18, 2023
68c9829
aauto: define a restricted version of the MANAGE_USB permission
muhomorr Dec 18, 2023
7581995
aauto: add definition of restricted BLUETOOTH_PRIVILEGED permission
muhomorr Dec 18, 2023
602eea5
aauto: add definition of restricted WIFI_PRIVILEGED permission
muhomorr Dec 18, 2023
38f56ec
aauto: add definition of restricted READ_PRIVILEGED_PHONE_STATE permi…
muhomorr Dec 25, 2023
3280827
adjust definition of TelecomManager.getUserSelectedOutgoingPhoneAccou…
muhomorr Dec 25, 2023
6dd7d31
aauto: support using aauto USB accessory activity as a default activity
muhomorr Dec 20, 2023
1e69ea9
aauto: define ASSOCIATE_COMPANION_DEVICES_RESTRICTED permission
muhomorr Dec 18, 2023
5d6554b
aauto: support allowing association with "automotive projection" devices
muhomorr Dec 18, 2023
d45a38e
aauto: support granting privileged permissions via PackageHooks
muhomorr Dec 18, 2023
faff266
hide from Aurora Store packages that it's not allowed to update
muhomorr Jan 15, 2024
d409733
run full explicit GC in SystemUI and system_server after locking
thestinger Feb 2, 2024
e7f6694
add UsbManager API for configuring USB port security state
muhomorr Feb 23, 2024
aa0bddd
add setting for USB port security state
muhomorr Feb 23, 2024
c90aaf5
Do not use filter calling uid parameter originally intended for insta…
quh4gko8 Nov 3, 2023
ad9e68e
Disallow the camera shortcut toggle from the lockscreen
neelchauhan May 28, 2024
1306473
disable support for adoptable storage
muhomorr May 29, 2024
a2c111b
add a helper class for wiping eUICCs
muhomorr May 29, 2024
b59cb3b
add duress password feature
muhomorr May 29, 2024
a96b9a6
add lock_settings shell commands for testing the duress password feature
muhomorr May 30, 2024
5cb4b88
add a test for the duress password feature
muhomorr May 29, 2024
bd53a27
extend the upstream wipe-without-reboot implementation
muhomorr Jun 1, 2024
d68b7f6
add lock_settings shell command option for printing executed Weaver ops
muhomorr Jun 1, 2024
8ba9f0f
duress password test: check that Weaver is wiped as part of duress wipe
muhomorr Jun 1, 2024
f5e194e
gmscompat: adjust to DynamiteLoader changes in GmsCore 24.22
muhomorr Jun 5, 2024
364e9f1
change default UsbPortSecurity mode to CHARGING_ONLY_WHEN_LOCKED
muhomorr Jun 6, 2024
e284360
temp: unconditionally enable system crash notifications
muhomorr Jun 3, 2024
8af7731
gmscompat: move enableNfc() to GmsModuleHooks
muhomorr Jun 11, 2024
4d1cc26
Revert "SystemUI: have NfcTile get an NfcAdapter directly"
muhomorr Jun 11, 2024
8418ba2
update lint baseline
muhomorr Jun 11, 2024
a65cb44
temp: disable boot-time dexopt progress UI
muhomorr Jun 12, 2024
2d25026
Revert "temp: unconditionally enable system crash notifications"
thestinger Jun 13, 2024
b396b28
EuiccWipe: add missing null check for UiccSlotInfo
muhomorr Jun 13, 2024
25107d2
DuressPasswordTest: remove device wipe from test preparation
muhomorr Jun 13, 2024
e19f52b
DuressPasswordTest: adjust to changed representation of WeaverRead.to…
muhomorr Jun 13, 2024
11b0cfc
DuressPasswordTest: fix test failure when device screen is initially …
muhomorr Jun 13, 2024
1f6f351
fix ApplicationInfo flag initialization being skipped in some cases
muhomorr Jun 13, 2024
354a50e
Revert "temp: disable boot-time dexopt progress UI"
muhomorr Jun 13, 2024
80de566
fix crash of boot-time info dialog due to delayed font init
muhomorr Jun 13, 2024
5ba04b8
Revert "Remove SystemUIDialog subclass from InternetDialog"
muhomorr Jun 13, 2024
00d4c90
Revert "[CDM][1/2] Modulize files"
muhomorr Jun 14, 2024
a863e8e
Revert "Move association revoke logic to AssociationRevokeProcessor"
muhomorr Jun 14, 2024
fcca6f2
add status callback to USB port security state API
muhomorr Jun 20, 2024
e42d81e
bugfix: Use cast checking first before casting to PackageExt
quh4gko8 Jun 20, 2024
59e8e94
move auto-reboot callback listener from SystemUI to system_server
muhomorr Jun 20, 2024
1b55993
don't toggle USB-C port after first unlock if it was connected BFU
muhomorr Jun 20, 2024
3c0fba6
Remove extra colon on GosPackageStatePmHooks
quh4gko8 Jul 1, 2024
ab6d54f
rework initialization of UsbPortSecurityHooks
muhomorr Jul 1, 2024
2ddc7de
fix USB port toggling being skipped after first unlock in some cases
muhomorr Jul 1, 2024
6527582
stub out reads of hidden system settings in Google's text-to-speech app
muhomorr Jul 1, 2024
a276f5d
Revert "PackageInstaller: make sure install confirmation returns a re…
muhomorr Jul 1, 2024
741bb11
gmscompat: don't let Play Store abort pending package installation
muhomorr Jul 1, 2024
84e7362
PackageInstaller: add missing handling of trusted app sources
muhomorr Jul 1, 2024
27f95b9
fix AppSwitch#isNotificationSuppressed
octocorvus May 14, 2024
ca1e725
show a deprecation warning dialog on each launch of a 32-bit app
muhomorr Jul 6, 2024
09b054d
better 32-bit deprecation warning
thestinger Jul 7, 2024
d67f26a
fix a race condition in initialization of UsbPortSecurityHooks
muhomorr Jul 16, 2024
715e4d1
fix touch-to-unlock on Google devices with side fingerprint scanner
muhomorr Jul 16, 2024
19b1c82
add setting for alternative touchscreen mode
muhomorr Jun 19, 2024
e2dc608
TombstoneHandler: support not reporting crashes with specific backtraces
muhomorr Aug 5, 2024
6b0bf45
don't report some android.hardware.bluetooth-service.bcmbtlinux crashes
muhomorr Aug 5, 2024
1bf842e
don't report some vendor.google.wifi_ext-service-vendor crashes
muhomorr Aug 5, 2024
62ba028
Enforce BaseUserRestriction for DISALLOW_CONFIG_BRIGHTNESS
wangchaohui Mar 12, 2024
0875559
Remove Dependency#get call from ToggleSeekBar.
Mar 5, 2024
edb0418
SettingsLib: add CategoryKey for Exploit protection screen
muhomorr Jul 30, 2024
51edc9b
ap2f: update Build.VERSION_CODES.VANILLA_ICE_CREAM
muhomorr Aug 12, 2024
5b72bd6
15: enable signature matching of updated system apps for all such apps
muhomorr Aug 9, 2024
52fc706
15: new PermissionService: implement shouldBlockGrantRuntimePermission()
muhomorr Aug 10, 2024
571d126
15: new PermissionService: implement updatePermissions()
muhomorr Aug 10, 2024
55bec67
15: new PermissionService: implement PackageHooks support
muhomorr Aug 10, 2024
e7019ff
15: new PermissionService: support for special runtime permissions
muhomorr Aug 11, 2024
35e5a93
15: PackageInstallerUI: add option to skip auto-grants of INTERNET perm
muhomorr Aug 11, 2024
5459deb
fixup! don't report some android.hardware.bluetooth-service.bcmbtlinu…
muhomorr Aug 8, 2024
b271784
require owner credential to check whether duress password is present
muhomorr Aug 10, 2024
0593f6d
PackageInstaller: fix NPE due to a race condition in PackageUtil
muhomorr Aug 15, 2024
a2256f9
gosps: add flags for clipboard setting
octocorvus Nov 26, 2023
e14ca23
add global per-user clipboard setting
octocorvus Jun 21, 2024
f9da05b
add intent for clipboard setting
octocorvus Jun 21, 2024
132035c
move generic app switch notification code to AppSwitchNotificationBase
octocorvus Jun 22, 2024
76e2a0e
change visibility of AppSwitch#isUsingDefaultValue to protected
octocorvus Jun 23, 2024
2564a26
add support for remove suppress notif flag in AppSwitch
octocorvus Jun 23, 2024
91203cc
add per-app clipboard setting
octocorvus Jun 23, 2024
31071f2
fixup! add per-app clipboard setting
octocorvus Aug 14, 2024
f41869c
fixup! add global per-user clipboard setting
octocorvus Aug 16, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 1 addition & 0 deletions Android.bp
Original file line number Diff line number Diff line change
Expand Up @@ -248,6 +248,7 @@ java_library {
"android.hardware.usb-V1.0-java-constants",
"android.hardware.usb-V1.1-java-constants",
"android.hardware.usb-V1.2-java-constants",
"android.hardware.usb.ext-V1-java",
"android.hardware.usb.gadget-V1-java",
"android.hardware.usb.gadget-V1.0-java",
"android.hardware.usb.gadget-V1.1-java",
Expand Down
12 changes: 12 additions & 0 deletions apex/jobscheduler/framework/java/android/app/AlarmManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
import android.annotation.SystemApi;
import android.annotation.SystemService;
import android.annotation.TestApi;
import android.app.compat.gms.GmsCompat;
import android.compat.annotation.ChangeId;
import android.compat.annotation.EnabledSince;
import android.compat.annotation.UnsupportedAppUsage;
Expand Down Expand Up @@ -1049,6 +1050,17 @@ private void setImpl(@AlarmType int type, long triggerAtMillis, long windowMilli
long intervalMillis, int flags, PendingIntent operation, final OnAlarmListener listener,
String listenerTag, Executor targetExecutor, WorkSource workSource,
AlarmClockInfo alarmClock) {
if (GmsCompat.isEnabled()) {
if (windowMillis == WINDOW_EXACT && !canScheduleExactAlarms()) {
windowMillis = WINDOW_HEURISTIC;
}
// non-null WorkSource requires privileged UPDATE_DEVICE_STATS permission
workSource = null;

// requires privileged SCHEDULE_PRIORITIZED_ALARM permission
flags &= ~FLAG_PRIORITIZE;
}

if (triggerAtMillis < 0) {
/* NOTYET
if (mAlwaysExact) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,11 @@
import android.annotation.SystemApi;
import android.annotation.SystemService;
import android.annotation.UserHandleAware;
import android.app.compat.gms.GmsCompat;
import android.content.Context;

import com.android.internal.gmscompat.client.ClientPriorityManager;

import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.util.Collections;
Expand Down Expand Up @@ -618,6 +621,11 @@ public void removeFromPermanentAllowList(@NonNull String packageName) {
@RequiresPermission(android.Manifest.permission.CHANGE_DEVICE_IDLE_TEMP_WHITELIST)
public void addToTemporaryAllowList(@NonNull String packageName, @ReasonCode int reasonCode,
@Nullable String reason, long durationMs) {
if (GmsCompat.isEnabled()) {
ClientPriorityManager.raiseToForeground(packageName, durationMs, reason, reasonCode);
return;
}

try {
mService.addPowerSaveTempWhitelistApp(packageName, durationMs, mContext.getUserId(),
reasonCode, reason);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ void addPowerSaveTempWhitelistAppDirect(int uid, long duration,

boolean isAppOnWhitelist(int appid);

int[] getPowerSaveWhitelistUserAppIds();
int[] getPowerSaveWhitelistAppIds();

int[] getPowerSaveTempWhitelistAppIds();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2381,14 +2381,14 @@ public String[] getFullPowerWhitelistExceptIdle() {
}

/**
* Returns the array of app ids whitelisted by user. Take care not to
* Returns the array of whitelisted app ids. Take care not to
* modify this, as it is a reference to the original copy. But the reference
* can change when the list changes, so it needs to be re-acquired when
* {@link PowerManager#ACTION_POWER_SAVE_WHITELIST_CHANGED} is sent.
*/
@Override
public int[] getPowerSaveWhitelistUserAppIds() {
return DeviceIdleController.this.getPowerSaveWhitelistUserAppIds();
public int[] getPowerSaveWhitelistAppIds() {
return DeviceIdleController.this.getAppIdWhitelistInternal();
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ public void onReceive(Context context, Intent intent) {
case PowerManager.ACTION_POWER_SAVE_WHITELIST_CHANGED:
synchronized (mLock) {
mDeviceIdleWhitelistAppIds =
mLocalDeviceIdleController.getPowerSaveWhitelistUserAppIds();
mLocalDeviceIdleController.getPowerSaveWhitelistAppIds();
if (DEBUG) {
Slog.d(TAG, "Got whitelist "
+ Arrays.toString(mDeviceIdleWhitelistAppIds));
Expand Down Expand Up @@ -133,7 +133,7 @@ public DeviceIdleJobsController(JobSchedulerService service) {
mPowerManager = (PowerManager) mContext.getSystemService(Context.POWER_SERVICE);
mLocalDeviceIdleController =
LocalServices.getService(DeviceIdleInternal.class);
mDeviceIdleWhitelistAppIds = mLocalDeviceIdleController.getPowerSaveWhitelistUserAppIds();
mDeviceIdleWhitelistAppIds = mLocalDeviceIdleController.getPowerSaveWhitelistAppIds();
mPowerSaveTempWhitelistAppIds =
mLocalDeviceIdleController.getPowerSaveTempWhitelistAppIds();
mDeviceIdleUpdateFunctor = new DeviceIdleUpdateFunctor();
Expand Down Expand Up @@ -194,7 +194,7 @@ public void setUidActiveLocked(int uid, boolean active) {
}

/**
* Checks if the given job's scheduling app id exists in the device idle user whitelist.
* Checks if the given job's scheduling app id exists in the device idle whitelist.
*/
boolean isWhitelistedLocked(JobStatus job) {
return Arrays.binarySearch(mDeviceIdleWhitelistAppIds,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
import android.app.job.UserVisibleJobSummary;
import android.content.ClipData;
import android.content.ComponentName;
import android.content.Context;
import android.net.Network;
import android.net.NetworkRequest;
import android.net.Uri;
Expand Down Expand Up @@ -2384,6 +2385,23 @@ private boolean isConstraintsSatisfied(int satisfiedConstraints) {
return true;
}

if ((mRequiredConstraintsOfInterest & CONSTRAINT_CONNECTIVITY) != 0) {
if ((satisfiedConstraints & CONSTRAINT_CONNECTIVITY) != 0) {
var pmi = LocalServices.getService(
com.android.server.pm.permission.PermissionManagerServiceInternal.class);

if (pmi.checkUidPermission(getSourceUid(), android.Manifest.permission.INTERNET, Context.DEVICE_ID_DEFAULT) !=
android.content.pm.PackageManager.PERMISSION_GRANTED) {
if (DEBUG) {
Slog.d(TAG, "skipping job " + getJobId() + " for " + getSourcePackageName()
+ " in user " + getSourceUserId() + ": it has CONSTRAINT_CONNECTIVITY, "
+ "but its UID doesn't have the INTERNET permission");
}
return false;
}
}
}

int sat = satisfiedConstraints;
if (overrideState == OVERRIDE_SOFT) {
// override: pretend all 'soft' requirements are satisfied
Expand Down
6 changes: 4 additions & 2 deletions cmds/app_process/app_main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,10 @@ class AppRuntime : public AndroidRuntime
AndroidRuntime* ar = AndroidRuntime::getRuntime();
ar->callMain(mClassName, mClass, mArgs);

IPCThreadState::self()->stopProcess();
hardware::IPCThreadState::self()->stopProcess();
if (mClassName != "com.android.internal.os.ExecInit") {
IPCThreadState::self()->stopProcess();
hardware::IPCThreadState::self()->stopProcess();
}
}

virtual void onZygoteInit()
Expand Down
2 changes: 1 addition & 1 deletion cmds/hid/jni/com_android_commands_hid_Device.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -368,7 +368,7 @@ static void closeDevice(JNIEnv* /* env */, jclass /* clazz */, jlong ptr) {
}
}

static JNINativeMethod sMethods[] = {
static const JNINativeMethod sMethods[] = {
{"nativeOpenDevice",
"(Ljava/lang/String;IIII[B"
"Lcom/android/commands/hid/Device$DeviceCallback;)J",
Expand Down
2 changes: 1 addition & 1 deletion cmds/uinput/jni/com_android_commands_uinput_Device.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,7 @@ static jint getEvdevInputPropByLabel(JNIEnv* env, jclass /* clazz */, jstring ra
return InputEventLookup::getLinuxEvdevInputPropByLabel(label.c_str()).value_or(-1);
}

static JNINativeMethod sMethods[] = {
static const JNINativeMethod sMethods[] = {
{"nativeOpenUinputDevice",
"(Ljava/lang/String;IIIIIILjava/lang/String;"
"Lcom/android/commands/uinput/Device$DeviceCallback;)J",
Expand Down
7 changes: 5 additions & 2 deletions core/api/current.txt
Original file line number Diff line number Diff line change
Expand Up @@ -231,6 +231,7 @@ package android {
field public static final String NFC = "android.permission.NFC";
field public static final String NFC_PREFERRED_PAYMENT_INFO = "android.permission.NFC_PREFERRED_PAYMENT_INFO";
field public static final String NFC_TRANSACTION_EVENT = "android.permission.NFC_TRANSACTION_EVENT";
field public static final String OTHER_SENSORS = "android.permission.OTHER_SENSORS";
field public static final String OVERRIDE_WIFI_CONFIG = "android.permission.OVERRIDE_WIFI_CONFIG";
field public static final String PACKAGE_USAGE_STATS = "android.permission.PACKAGE_USAGE_STATS";
field @Deprecated public static final String PERSISTENT_ACTIVITY = "android.permission.PERSISTENT_ACTIVITY";
Expand Down Expand Up @@ -345,7 +346,9 @@ package android {
field public static final String LOCATION = "android.permission-group.LOCATION";
field public static final String MICROPHONE = "android.permission-group.MICROPHONE";
field public static final String NEARBY_DEVICES = "android.permission-group.NEARBY_DEVICES";
field public static final String NETWORK = "android.permission-group.NETWORK";
field public static final String NOTIFICATIONS = "android.permission-group.NOTIFICATIONS";
field public static final String OTHER_SENSORS = "android.permission-group.OTHER_SENSORS";
field public static final String PHONE = "android.permission-group.PHONE";
field public static final String READ_MEDIA_AURAL = "android.permission-group.READ_MEDIA_AURAL";
field public static final String READ_MEDIA_VISUAL = "android.permission-group.READ_MEDIA_VISUAL";
Expand Down Expand Up @@ -32732,7 +32735,7 @@ package android.os {
field public static final int S_V2 = 32; // 0x20
field public static final int TIRAMISU = 33; // 0x21
field public static final int UPSIDE_DOWN_CAKE = 34; // 0x22
field @FlaggedApi("android.os.android_os_build_vanilla_ice_cream") public static final int VANILLA_ICE_CREAM = 10000; // 0x2710
field @FlaggedApi("android.os.android_os_build_vanilla_ice_cream") public static final int VANILLA_ICE_CREAM = 35; // 0x23
}

public final class Bundle extends android.os.BaseBundle implements java.lang.Cloneable android.os.Parcelable {
Expand Down Expand Up @@ -43266,7 +43269,7 @@ package android.telecom {
method public android.telecom.PhoneAccountHandle getSimCallManager();
method @Nullable public android.telecom.PhoneAccountHandle getSimCallManagerForSubscription(int);
method @Nullable public String getSystemDialerPackage();
method @Nullable @RequiresPermission(android.Manifest.permission.READ_PHONE_STATE) public android.telecom.PhoneAccountHandle getUserSelectedOutgoingPhoneAccount();
method @Nullable @RequiresPermission(anyOf={"android.permission.READ_PRIVILEGED_PHONE_STATE", "android.permission.READ_PRIVILEGED_PHONE_STATE_ANDROID_AUTO"}) public android.telecom.PhoneAccountHandle getUserSelectedOutgoingPhoneAccount();
method @RequiresPermission(android.Manifest.permission.READ_PHONE_STATE) public String getVoiceMailNumber(android.telecom.PhoneAccountHandle);
method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean handleMmi(String);
method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean handleMmi(String, android.telecom.PhoneAccountHandle);
Expand Down
7 changes: 6 additions & 1 deletion core/api/lint-baseline.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1109,6 +1109,12 @@ Todo: android.provider.ContactsContract.RawContacts#newEntityIterator(android.da
Documentation mentions 'TODO'


UnflaggedApi: android.Manifest.permission#OTHER_SENSORS:
New API must be flagged with @FlaggedApi: field android.Manifest.permission.OTHER_SENSORS
UnflaggedApi: android.Manifest.permission_group#NETWORK:
New API must be flagged with @FlaggedApi: field android.Manifest.permission_group.NETWORK
UnflaggedApi: android.Manifest.permission_group#OTHER_SENSORS:
New API must be flagged with @FlaggedApi: field android.Manifest.permission_group.OTHER_SENSORS
UnflaggedApi: android.R.color#on_surface_disabled_material:
New API must be flagged with @FlaggedApi: field android.R.color.on_surface_disabled_material
UnflaggedApi: android.R.color#outline_disabled_material:
Expand Down Expand Up @@ -1461,7 +1467,6 @@ UnflaggedApi: android.graphics.text.PositionedGlyphs#getItalicOverride(int):
New API must be flagged with @FlaggedApi: method android.graphics.text.PositionedGlyphs.getItalicOverride(int)
UnflaggedApi: android.graphics.text.PositionedGlyphs#getWeightOverride(int):
New API must be flagged with @FlaggedApi: method android.graphics.text.PositionedGlyphs.getWeightOverride(int)

UnflaggedApi: android.hardware.camera2.ExtensionCaptureRequest:
New API must be flagged with @FlaggedApi: class android.hardware.camera2.ExtensionCaptureRequest
UnflaggedApi: android.hardware.camera2.ExtensionCaptureRequest#ExtensionCaptureRequest():
Expand Down
42 changes: 42 additions & 0 deletions core/api/module-lib-current.txt
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,20 @@ package android.app.admin {

}

package android.app.compat.gms {

public class GmsModuleHooks {
method @Nullable public static String deviceConfigGetProperty(@NonNull String, @NonNull String);
method public static boolean deviceConfigSetProperties(@NonNull android.provider.DeviceConfig.Properties);
method public static boolean deviceConfigSetProperty(@NonNull String, @NonNull String, @Nullable String);
method @Nullable public static Boolean enableBluetoothAdapter();
method public static void enableNfc();
method public static boolean interceptSynchronousResultReceiverException(@NonNull RuntimeException);
method public static void makeBluetoothAdapterDiscoverable();
}

}

package android.content {

public abstract class ContentProvider implements android.content.ComponentCallbacks2 {
Expand Down Expand Up @@ -140,6 +154,29 @@ package android.content.pm {

}

package android.ext.settings {

public class ConnChecksSetting {
method public static int get();
method public static boolean put(int);
field public static final int VAL_DEFAULT = 0; // 0x0
field public static final int VAL_DISABLED = 2; // 0x2
field public static final int VAL_GRAPHENEOS = 0; // 0x0
field public static final int VAL_STANDARD = 1; // 0x1
}

public class RemoteKeyProvisioningSettings {
method @Nullable public static String getServerUrlOverride(@NonNull android.content.Context);
field public static final int GRAPHENEOS_PROXY = 0; // 0x0
field public static final int STANDARD_SERVER = 1; // 0x1
}

public class WidevineProvisioningSettings {
method @Nullable public static String getServerHostnameOverride(@NonNull android.content.Context);
}

}

package android.hardware.usb {

public class UsbManager {
Expand Down Expand Up @@ -456,6 +493,11 @@ package android.os {
field public static final long TRACE_TAG_NETWORK = 2097152L; // 0x200000L
}

public final class UserHandle implements android.os.Parcelable {
method public static int getUid(int, int);
method public static int getUserId(int);
}

}

package android.os.storage {
Expand Down
Loading