Commit Graph

16986 Commits

Author SHA1 Message Date
Hunter Knepshield
93a25e9cd1 Merge "Create CarrierPrivilegesListener callback." am: d54e1126ab am: e66c82b449 am: c7a0de9f6f
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1912993

Change-Id: Id89455067252fd32f2c8890af120c4241185fcf7
2021-12-16 19:48:39 +00:00
Hunter Knepshield
c7a0de9f6f Merge "Create CarrierPrivilegesListener callback." am: d54e1126ab am: e66c82b449
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1912993

Change-Id: Ia3a4afac2c703b6ff411dd981d4899be78d78281
2021-12-16 19:40:11 +00:00
Hunter Knepshield
d54e1126ab Merge "Create CarrierPrivilegesListener callback." 2021-12-16 19:00:24 +00:00
Ayush Sharma
e41e71aca7 Merge "Revert "Add APIs that allow to exclude routes from VPN"" am: da37e0f471 am: d48a67e944 am: 05fad87223
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1927301

Change-Id: I84505e56bfdb32ab4dc43559d56390d60bc1ff73
2021-12-16 15:52:37 +00:00
Ayush Sharma
05fad87223 Merge "Revert "Add APIs that allow to exclude routes from VPN"" am: da37e0f471 am: d48a67e944
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1927301

Change-Id: I2847af72de65564d3bda4145ebc05261e9fbe61e
2021-12-16 15:39:49 +00:00
Ayush Sharma
da37e0f471 Merge "Revert "Add APIs that allow to exclude routes from VPN"" 2021-12-16 15:01:30 +00:00
Ayush Sharma
487b2e645a Revert "Add APIs that allow to exclude routes from VPN"
Revert "Suppress NewApi warnings for @SystemApi -> public APIs"

Revert "Add VpnServiceBuilderShim for VpnService.Builder"

Revert submission 1551943-vpn-impl

Reason for revert: <DroidMonitor-triggered revert due to breakage https://android-build.googleplex.com/builds/quarterdeck?branch=aosp-master&target=mainline_modules_x86_64-userdebug&lkgb=8007224&lkbb=8008168&fkbb=8007902 >, bug b/210979001
Reverted Changes:
I0e7aa077a:Add VpnServiceBuilderShim for VpnService.Builder
Ib12f5ab39:Suppress NewApi warnings for @SystemApi -> public ...
I59b9185cf:Unhide RouteInfo#getType and related fields
Ie5b62b2b2:Unhide IpPrefix(InetAddress, int)
I993a32d40:Add CTS tests for exclude VPN routes APIs
Ib24b2d3fb:Suppress NewApi warnings for @SystemApi -> public ...
Ic3b10464a:Add APIs that allow to exclude routes from VPN

Change-Id: I89209357ab4bb206d206adcf9fd6d3498ce6ef4c
BUG: 210979001
2021-12-16 14:40:13 +00:00
Taras Antoshchuk
a5d20fcf3c Merge "Add APIs that allow to exclude routes from VPN" am: 55f030225b am: 1e2f898c30 am: 0cfd695f07
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1619406

Change-Id: If11e20ea47987c6017d52ee93489b6784af580ec
2021-12-16 12:04:23 +00:00
Taras Antoshchuk
0cfd695f07 Merge "Add APIs that allow to exclude routes from VPN" am: 55f030225b am: 1e2f898c30
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1619406

Change-Id: I982d3289d967d42954087e88628b2022982cb721
2021-12-16 11:49:25 +00:00
Taras Antoshchuk
55f030225b Merge "Add APIs that allow to exclude routes from VPN" 2021-12-16 11:13:33 +00:00
Rambo Wang
7f9a9fd489 Merge "Support CarrierService#notifyCarrierNetworkChange with subscription" am: eaa2a701cd am: c37af99d0a am: 48f89c249b
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1897973

Change-Id: I612975482ce290deb3f0fd3d4999460e90aeae4b
2021-12-16 01:16:14 +00:00
Rambo Wang
48f89c249b Merge "Support CarrierService#notifyCarrierNetworkChange with subscription" am: eaa2a701cd am: c37af99d0a
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1897973

Change-Id: Ic0a51db9174ef6f58af469b1cbeeab613b79836d
2021-12-16 00:56:07 +00:00
Treehugger Robot
9e9eb416f7 Merge "Fix an off-by-one bug in EditableInputConnection#endBatchEdit() return value" am: e908851af5 am: 0c024d11ed am: d9c2da8152
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1923058

Change-Id: I3ed9484befd715965561bd80d0de6498a5b2735e
2021-12-15 18:19:34 +00:00
Treehugger Robot
d9c2da8152 Merge "Fix an off-by-one bug in EditableInputConnection#endBatchEdit() return value" am: e908851af5 am: 0c024d11ed
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1923058

Change-Id: Icaa621b17c72031f0a767aaece8c96a92221fc82
2021-12-15 17:54:19 +00:00
Rambo Wang
241b1fa964 Support CarrierService#notifyCarrierNetworkChange with subscription
Current APIs does not include subId or phoneId to locate which
carrier network reported the change. A patch based on carrier
privilege were deployed in Q to temprarily fix the issue.

However, multiple subscriptions which all have the carrier
privileges will all get notified, even only one of them
has the real change.

To throughly resolve the issue, the subscription is introduced
in the API to distinguish which network actually has the change.

Bug: 131697791
Test: atest TelephonyRegistryManagerTest CarrierServiceTest
Change-Id: Ie7ee25f53da605c15e1a9228482cc8c4e7406d2a
2021-12-15 17:35:52 +00:00
Treehugger Robot
e908851af5 Merge "Fix an off-by-one bug in EditableInputConnection#endBatchEdit() return value" 2021-12-15 17:00:15 +00:00
Treehugger Robot
9fe54e87fc Merge "Allow renounce location permission" am: 373b687d96 am: 9bb03ffe7c am: 61569b3924
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1887652

Change-Id: I9af82e5d7dc806ffc42122e0849cbf854c220fde
2021-12-15 01:30:19 +00:00
Treehugger Robot
61569b3924 Merge "Allow renounce location permission" am: 373b687d96 am: 9bb03ffe7c
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1887652

Change-Id: I1f8a4b7f8e4774a780b18cb9c6475293ea706f37
2021-12-15 01:16:33 +00:00
Treehugger Robot
373b687d96 Merge "Allow renounce location permission" 2021-12-15 00:35:20 +00:00
Yohei Yukawa
1fdc14b8a9 Fix an off-by-one bug in EditableInputConnection#endBatchEdit() return value
This is a follow up CL to our previous CL [1], which had an off-by-one
bug when determining the return value of

   EditableInputConnection#endBatchEdit().

According to the API document of InputConnection#endBatchEdit(), the
following test should pass.

   EditText editText = new EditText(context);
   EditorInfo editorInfo = new EditorInfo();
   InputConnection editableInputConnection =
           editText.onCreateInputConnection(editorInfo);
   assertThat(editableInputConnection.beginBatchEdit()).isTrue();
   assertThat(editableInputConnection.beginBatchEdit()).isTrue();
   assertThat(editableInputConnection.endBatchEdit()).isTrue();
   assertThat(editableInputConnection.endBatchEdit()).isFalse(); // (*)
   assertThat(editableInputConnection.endBatchEdit()).isFalse();

However, the last assertion marked with (*) actually fails due to an
off-by-one bug.  This CL finally fixes it.

The risk of app compat breakages because of fixing this long standing
bug is supposed to be low, mainly because:

 * the system has not relied on this return value yet.
 * Widgets like WebView have correctly implemented this API.
 * IME has always received true no matter what the app returned, which
   is the same behavior as other async InputConnection APIs.

This CL adds several notes to InputConnection#endBatchEdit() document
to help developers correctly implement and use this API.

 [1]: I1ec5518fdc16fb0551fbce9d13f5d92eb4bc78c0
      c478c171e9

Fix: 209958658
Fix: 210165648
Test: atest -c CtsInputMethodTestCases:EditTextImeSupportTest
Change-Id: Ibc40072fa11a4d6e3c24b8d7860c914ccdbcbc8a
Merged-In: Ibc40072fa11a4d6e3c24b8d7860c914ccdbcbc8a
(cherry picked from commit beda2b7f76)
2021-12-14 15:15:54 -08:00
Sooraj Sasindran
5d02dbb7bf Allow renounce location permission
Allow renounce location permission

Bug: 198533763
Test: CTS
Merged-In: I10872f34603441da2cf80f1f2976f3f3ca0ff6c2
Change-Id: I10872f34603441da2cf80f1f2976f3f3ca0ff6c2
2021-12-14 13:25:04 -08:00
Kalesh Singh
298efb93e7 Merge "Add system_server to readtracefs group" am: 3f73570646 am: 1802c2eb34 am: f3c80521cf
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1914167

Change-Id: Ia3cd14996f74a7b8f0a0b64402c7c1381bed9c56
2021-12-14 20:43:24 +00:00
Xin Li
85d715bac3 Merge "Merge Android 12 QPR1" 2021-12-14 20:25:23 +00:00
Kalesh Singh
f3c80521cf Merge "Add system_server to readtracefs group" am: 3f73570646 am: 1802c2eb34
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1914167

Change-Id: Ic8dcd91d0f980e0bb2afbe8e0f9e657a4e0f7d2f
2021-12-14 20:24:56 +00:00
Kalesh Singh
1802c2eb34 Merge "Add system_server to readtracefs group" am: 3f73570646
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1914167

Change-Id: Idb8d8c434d577e01d7d9a31e317022a6f25ebf90
2021-12-14 19:54:11 +00:00
Kalesh Singh
3f73570646 Merge "Add system_server to readtracefs group" 2021-12-14 19:37:02 +00:00
Taras Antoshchuk
59073f0652 Add APIs that allow to exclude routes from VPN
Add new methods to VpnService.Builder that allow to specify network
routes that should bypass the VPN. Implemented by using RTN_THROW
routes.

Bug: 186082280
Test: atest HostsideVpnTests
Test: atest VpnServiceBuilderTest
Change-Id: Ic3b10464a53a8b56334589acec8f27acdc180ff7
2021-12-13 11:11:00 +01:00
Miranda Kephart
c5e145c3bf Update sharesheet for large devices
Switches to a wrapped sharesheet (instead of filling the screen)
and 6 columns instead of 8 for large screens. Also fixes some
small details with the appearance (see
https://docs.google.com/presentation/d/1WDbmWx6uXaFi8jos7Sp6ZUmBh24Y5Bj5G7dW78LxE40/edit#slide=id.gb836e06a0c_0_0)

Bug: 195102471
Test: manual (visual changes)
Merged-In: I5d84dce0aea7657a50dc3376be9d8b5e41b907db
Change-Id: I5d84dce0aea7657a50dc3376be9d8b5e41b907db
2021-12-10 09:47:58 +00:00
Hunter Knepshield
866d3a4d03 Create CarrierPrivilegesListener callback.
This callback will allow privileged components to listen to changes
around carrier privileged apps in a way that is aware and accounts for
SIM profile switches. This callback will be backed by
CarrierPrivilegesTracker as a follow-up change.

Bug: 205736323
Test: atest android.telephony.cts.TelephonyRegistryManagerTest
Change-Id: I432ed00be16c68303bf5c8e074fb9d6cf83e82c9
2021-12-08 15:53:33 -08:00
Jiakai Zhang
bbe20f1546 Merge "Prefetch standalone system server jars before switching domain." am: 04b45b74a1 am: 16895824d0 am: 5a86271193
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1909973

Change-Id: I76ef30d0aa75d697d9472df8b4d777663a86eeda
2021-12-08 23:34:32 +00:00
Jiakai Zhang
5a86271193 Merge "Prefetch standalone system server jars before switching domain." am: 04b45b74a1 am: 16895824d0
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1909973

Change-Id: I3e3a0853ab1d14a4759d2954d318d8213f1ea8a9
2021-12-08 23:21:58 +00:00
Jiakai Zhang
16895824d0 Merge "Prefetch standalone system server jars before switching domain." am: 04b45b74a1
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1909973

Change-Id: I1c66a904c3688717853ce34a2952d976960b21a7
2021-12-08 22:56:25 +00:00
Jiakai Zhang
405fb6dee9 Prefetch standalone system server jars before switching domain.
In b/203198541, we start to compile standalone system server jars, but
the SELinux policy doesn't allow system_server to load the compiled code
at runtime. As a solution, this change creates class loaders for
standalone system server jars and caches them before switching to the
"system_server" SELinux domain, which essentially loads the jars and
compiled code into the memory.

Bug: 203198541
Test: manual -
  1. Patch aosp/1874113, aosp/1876173, aosp/1906158 (in order to have
     odrefresh compile a standalone system server jar).
  2. Build a system image and flash it to a device.
  3. Run "adb shell cat /proc/`adb shell pidof system_server`/maps" and
     see "apex@com.android.wifi@javalib@service-wifi.jar@classes.odex"
     being mmap'ed.
  4. Run "adb logcat | grep avc" and see no denial.
  5. atest odsign_e2e_tests

Change-Id: I27fbdaadae2b6f50989b4c534f7fbc80044a6685
Merged-In: I365be766cfb77c6e240d5871f1b3d8ed7abae6f5
(cherry picked from commit 281a2dfaa1)
2021-12-08 09:47:38 +00:00
Kalesh Singh
57bbd0099e Add system_server to readtracefs group
This allows system_server to search/read tracefs entries. It is needed
for attaching cpu timeinstate bpf programs to tracepoints.

Bug: 208892266
Bug: 209513178
Test: libtimeinstate_test
Change-Id: I4139605eb7c5277887092b3d6a3fb26bf4f8f171
2021-12-07 23:48:08 +00:00
Andrei-Valentin Onea
ad82eb4ea3 Merge "Allow privapp permission allowlist in apex" am: e978ec5b07 am: 1c565d5b4b am: 9f370ba438
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1766011

Change-Id: Icfea66a1f48d1e3fde14afa89e1c6313da01dacc
2021-12-07 16:26:54 +00:00
Andrei-Valentin Onea
9f370ba438 Merge "Allow privapp permission allowlist in apex" am: e978ec5b07 am: 1c565d5b4b
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1766011

Change-Id: If9cc15759bead022245f08b02ffd3475160bee78
2021-12-07 16:07:07 +00:00
Andrei-Valentin Onea
1c565d5b4b Merge "Allow privapp permission allowlist in apex" am: e978ec5b07
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1766011

Change-Id: I3bb67e833b6c167ba24b974abcce9cde75317a89
2021-12-07 15:46:06 +00:00
Chris Li
af34c807e4 Merge "Use the current dimensions instead of relying on onConfigurationChanged" into sc-v2-dev am: fb1aca8138
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16361589

Change-Id: I14b5a046c0c784f8e8b34267487fca0810faa5d0
2021-12-07 06:08:53 +00:00
Andrei Onea
95ecac506d Allow privapp permission allowlist in apex
Read priv-app permission allowlists from APEX file and warn if
they're in the /system partition instead.

Test: boots
Bug: 190375768
Change-Id: I37d6deb60f0dffb75dd634075cd95bcf7ddf9684
Merged-In: I37d6deb60f0dffb75dd634075cd95bcf7ddf9684
2021-12-03 18:19:00 +00:00
Chris Li
e40ee51d37 Use the current dimensions instead of relying on onConfigurationChanged
There are some cases when the View will not receive
onConfigurationChanged event (such as DialogFragment). Always use the
current dimensions instead.

Fix: 205251075
Test: test with Settings app
Change-Id: If626fe597c02efcb480c05ca88cffbfae1b21a89
2021-11-30 17:39:00 +08:00
Treehugger Robot
81dd7537eb Merge "Fix an issue when empty the usap pool." am: faf1b1cf0b am: 9078248b75 am: 80f41edf05
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1893002

Change-Id: Idbaa45d4871c7e6c1e15d7af4fb432a2b24a49cf
2021-11-29 08:28:34 +00:00
Treehugger Robot
80f41edf05 Merge "Fix an issue when empty the usap pool." am: faf1b1cf0b am: 9078248b75
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1893002

Change-Id: Id444bd4f7b15a985fa026bde136a15c0efab7d38
2021-11-29 08:14:54 +00:00
Treehugger Robot
9078248b75 Merge "Fix an issue when empty the usap pool." am: faf1b1cf0b
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1893002

Change-Id: I6d5e04471f756ee5544bb1f77cf1927f44d7715a
2021-11-29 08:00:57 +00:00
Treehugger Robot
faf1b1cf0b Merge "Fix an issue when empty the usap pool." 2021-11-29 07:46:36 +00:00
zhangjianqiu
1bc2b9c612 Fix an issue when empty the usap pool.
When empty the usap pool, the usap processes may be blocked by
usapPoolSocket.accept(), which cause the usap process fail to kill
immediately. So we can move the position of blockSigTerm after
usapPoolsSocket.accept() and delele the old blockSigTerm in the while
loop.

Test: manual test.
1.setprop persist.device_config.runtime_native.usap_pool_enabled true.
After 1 min, trigger fill usap pools.
2.setprop persist.device_config.runtime_native.usap_pool_enabled false.
After 1 min, trigger empty usap pools.
3.repeat step 1.

Signed-off-by: zhangjianqiu <zhangjianqiu@oppo.com>
Change-Id: I657940b30f71cdc717c673be6d70738e61e2bb68
2021-11-24 09:48:01 +08:00
Treehugger Robot
aad398ed08 Merge "Framework and system_server classes can access public vendor libraries" am: 8cb6d28329 am: 1f479b99ce am: 6d0d1ff1e6
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1885792

Change-Id: I46c8afc6889b9e01e0d48e011092b49f5cee5a12
2021-11-19 01:05:19 +00:00
Treehugger Robot
6d0d1ff1e6 Merge "Framework and system_server classes can access public vendor libraries" am: 8cb6d28329 am: 1f479b99ce
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1885792

Change-Id: I924242f514458f53cfb71ef83b5084646c8b1b73
2021-11-19 00:47:09 +00:00
Treehugger Robot
1f479b99ce Merge "Framework and system_server classes can access public vendor libraries" am: 8cb6d28329
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1885792

Change-Id: Ia8fe285e3668fac4c2d6ca8ffff2976df88f90c3
2021-11-19 00:29:06 +00:00
Treehugger Robot
8cb6d28329 Merge "Framework and system_server classes can access public vendor libraries" 2021-11-19 00:08:57 +00:00
Issei Suzuki
b6bb0424f0 Merge "Stop output WM_DEBUG_WALLPAPER logs to logcat" into sc-v2-dev am: 8dfb06f117
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16283220

Change-Id: I2e622e390e341f1ef11088eff9265bb53ed39ed1
2021-11-18 19:51:05 +00:00