OSDN Git Service
Chih-Wei Huang [Wed, 5 Jun 2019 09:28:50 +0000 (17:28 +0800)]
Merge tag 'android-8.1.0_r65' into oreo-x86
Android 8.1.0 release 65
Chih-Wei Huang [Mon, 20 May 2019 09:27:39 +0000 (17:27 +0800)]
Merge tag 'android-8.1.0_r64' into oreo-x86
Android 8.1.0 Release 64 (OPM8.190505.001)
android-build-team Robot [Tue, 16 Apr 2019 22:37:45 +0000 (22:37 +0000)]
Merge cherrypicks of [
7077328,
7074021,
7074022,
7077576,
7077577,
7077578,
7077579] into oc-m8-release
Change-Id: Iec63c3117aa78ca05775724fb9afd8d048730755
Eran Messeri [Mon, 25 Mar 2019 14:31:04 +0000 (14:31 +0000)]
Permission Check For DPM.getPermittedAccessibilityServices
Bug:
128599660
Test: com.android.server.devicepolicy.DevicePolicyManagerTest
Test: com.google.android.gts.devicepolicy.DeviceOwnerTest
Change-Id: I8be915bd6a4ff99884d23005a4c6f0100806dbe8
Merged-In: I8ee3f876fcaffa63636645f0f59709cd147254ef
(cherry picked from commit
4fd13eefcf99d9b9b0d5f5ea99fdc7c799c83d23)
Julia Reynolds [Wed, 27 Mar 2019 16:15:57 +0000 (12:15 -0400)]
[RESTRICT_AUTOMERGE]: Add cross user permission check - areNotificationsEnabledForPackage
Test: atest
Fixes:
128599467
Change-Id: I13a0ca7590f8c4b44379730e0ee2088aba400c2a
(cherry picked from commit
657d164136199126ae241848887de0230699cea0)
(cherry picked from commit
bed6193b5954565f60afb5f5f9868d89991354d7)
android-build-team Robot [Wed, 13 Mar 2019 20:14:54 +0000 (20:14 +0000)]
Merge cherrypicks of [
6714499,
6716593,
6716594,
6716595,
6716596,
6716597,
6716977,
6718226,
6717773,
6716978,
6717663] into oc-m8-release
Change-Id: I96f75f93b03721c801d8f0d237995b6a7ae07564
WyattRiley [Thu, 28 Feb 2019 19:43:12 +0000 (11:43 -0800)]
DO NOT MERGE - SUPL ES Extension - Safer Init and Not After Boot
Safe order of pointer setting and background thread start
Verifying mCallEndElapsedRealtimeMillis is not the initial value
Bug:
112159033
Bug:
115361555
Bug:
125124724
Test: Verified not-after-boot with test code b/
115361555#comment14
Test: Reproed NPE with test thread sleep and verify fix
Change-Id: Icd2ea91d71da71c8fda109ceb70514733d35060b
(cherry picked from commit
a7cb82eb85cd361b90c9700ff935ba614c94f490)
Mauro Rossi [Sun, 3 Mar 2019 15:28:41 +0000 (16:28 +0100)]
android_view_ThreadedRenderer: prevent Null Pointer Exception in createBitmap
To avoid Playstore crashes with nouveau and Hardware Bitmap,
a check is added to bitmap returned by Bitmap::createFrom(buffer)
inspired by similar behavior in Bitmap.cpp Bitmap_createHardwareBitmap()
Fixes the following crash:
*** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
Build fingerprint: 'Android-x86/android_x86/x86:8.1.0/OPM8.181005.003/uten01131829:userdebug/test-keys'
Revision: '0'
ABI: 'x86'
pid: 4644, tid: 4644, name: android.vending >>> com.android.vending <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0xc
Cause: null pointer dereference
eax
89195380 ebx
b1d36290 ecx
00000000 edx
ae783074
esi
00000000 edi
ae7a9380
xcs
00000073 xds
0000007b xes
0000007b xfs
0000003b xss
0000007b
eip
b1c4f7c8 ebp
bff902c8 esp
bff9028c flags
00010246
backtrace:
#00 pc
000fd7c8 /system/lib/libandroid_runtime.so (android::bitmap::createBitmap(_JNIEnv*, android::Bitmap*, int, _jbyteArray*, _jobject*, int)+104)
#01 pc
000d08ca /system/lib/libandroid_runtime.so (android::android_view_ThreadedRenderer_createHardwareBitmapFromRenderNode(_JNIEnv*, _jobject*, long long, int, int)+1002)
android-build-team Robot [Wed, 16 Jan 2019 18:56:56 +0000 (18:56 +0000)]
Merge cherrypicks of [
6072696,
6072074,
6072757,
6072120,
6072121,
6072122,
6072123,
6072575,
6072576,
6072577,
6072578,
6072579,
6072193,
6072131,
6072194,
6072076,
6072210,
6072759,
6072760,
6072698,
6072699,
6072700,
6072701,
6072702,
6072703,
6072704,
6072905,
6072906,
6072907,
6072761] into oc-m8-release
Change-Id: Ia83e95b299ccfe815cca1abec869db1456fca295
Adrian Roos [Mon, 7 Jan 2019 15:57:31 +0000 (16:57 +0100)]
DPM: Fix regression from I54376f60ac53451ace22965d331b47cd8c2e614e
Fixes an issue where setting a password via DPM would never
satisfy a QUALITY_COMPLEX password requirement.
Change-Id: I3fbc952bd44291ac22728c626b128fc0c1aae232
Merged-In: I3fbc952bd44291ac22728c626b128fc0c1aae232
Fixes:
120915644
Bug:
110172241
Test: atest 'com.android.cts.devicepolicy.DeviceAdminHostSideTestApi24#testRunDeviceOwnerPasswordTest'
Test: Set credential via DPM.resetPassword(), factory reset device to trigger FRP, verify FRP shows.
(cherry picked from commit
48d06522c66cac586a859a628729d26c6fa5d64c)
Abodunrinwa Toki [Fri, 4 Jan 2019 17:18:39 +0000 (17:18 +0000)]
RESTRICT AUTOMERGE Do not linkify text with RLO/LRO characters.
Also don't show smart actions for selections in text with unsupported
characters.
Bug:
116321860
Test: runtest -x cts/tests/tests/text/src/android/text/util/cts/LinkifyTest.java
Change-Id: Ib2ee544b5783234fba8ee2f93adf0b36b039520f
(cherry picked from commit
4e3507d544741ba08d871a235b6ec11e1e674853)
WyattRiley [Thu, 6 Dec 2018 19:43:58 +0000 (11:43 -0800)]
Adding SUPL NI Emergency Extension Time
Configurable by carrier config.xml resource
Bug:
118839234
Bug:
115361555
Bug:
112159033
Test: On device, see b/
115361555#comment14
Change-Id: I52e61656cca8b6fa6468d32d2e69bf60f4c83c61
Merged-In: I52e61656cca8b6fa6468d32d2e69bf60f4c83c61
(cherry picked from commit
1cd7883a76d7bb28edc9c29bdabb3753a0c63396)
Adrian Roos [Thu, 6 Dec 2018 16:50:41 +0000 (17:50 +0100)]
FRP: save password quality in DPM.resetPassword
When setting a password from DPM.resetPassword(), the actual quality of the
password was not passed to LockSettingsService (instead, the minimum required
quality was passed which is often UNSPECIFIED). As a result, during FRP we
would see inconsistent state and skip it.
Bug:
110172241
Test: Set credential via DPM.resetPassword(), factory reset device to trigger FRP, verify FRP shows.
Change-Id: I54376f60ac53451ace22965d331b47cd8c2e614e
Merged-In: I54376f60ac53451ace22965d331b47cd8c2e614e
(cherry picked from commit
ef116def7c91fd4492a8df03355e1dbdbde02a85)
Chih-Wei Huang [Fri, 21 Dec 2018 08:57:42 +0000 (16:57 +0800)]
Merge tag 'android-8.1.0_r53' into oreo-x86
Android 8.1.0 release 53
android-build-team Robot [Fri, 7 Dec 2018 21:43:17 +0000 (21:43 +0000)]
Merge cherrypicks of [
5745882,
5746123,
5746124,
5746125,
5745544,
5745819,
5746700,
5745883,
5745545,
5746720,
5746344,
5745884,
5745885,
5745886,
5746740,
5746741] into oc-m8-release
Change-Id: Id37012cba82213c4eceac91277a0914ce7c50cf8
Jakub Pawlowski [Thu, 29 Nov 2018 17:54:21 +0000 (18:54 +0100)]
Bluetooth: Check descriptors size in BluetoothHidDeviceAppSdpSettings
Bug:
119819889
Test: compilation
Change-Id: If51d0e2af74d99758f79a603d40cc2f5c84e4dde
Merged-In: If51d0e2af74d99758f79a603d40cc2f5c84e4dde
(cherry picked from commit
f843ccbf9e3791b426af78389e276c46dbec75e1)
Varun Shah [Sat, 27 Oct 2018 00:03:23 +0000 (17:03 -0700)]
RESTRICT AUTOMERGE: Added an app id security check in isAppForeground.
ActivityManagerService#isAppForeground now checks if the caller has the
permission to view if an app is in the foreground.
Bug:
115384617
Test: cts-tradefed run cts -m CtsSecurityTestCases -t android.security.cts.ActivityManagerTest#testIsAppInForegroundNormal
Test: cts-tradefed run cts -m CtsSecurityTestCases -t android.security.cts.ActivityManagerTest#testIsAppInForegroundMalicious
Change-Id: I9602c89b2d40036e525c38960a08326dc74c6682
(cherry picked from commit
ad02e59ac2cd3e6180e02fd60e6dedd8177c7b6e)
android-build-team Robot [Fri, 19 Oct 2018 16:33:31 +0000 (16:33 +0000)]
Merge cherrypicks of [
5313290,
5313323,
5313343,
5313415,
5313291,
5313441,
5313557,
5313344,
5313383,
5313384,
5313324,
5313325,
5313326,
5313294,
5313295,
5313296,
5313498] into oc-m8-release
Change-Id: I46b1483089554a4bec18c984d21c8b56ee8bcb85
Jeff Sharkey [Mon, 24 Sep 2018 19:23:57 +0000 (13:23 -0600)]
RESTRICT AUTOMERGE: Recover shady content:// paths.
The path-permission element offers prefix or regex style matching of
paths, but most providers internally use UriMatcher to decide what
to do with an incoming Uri.
This causes trouble because UriMatcher uses Uri.getPathSegments(),
which quietly ignores "empty" paths. Consider this example:
<path-permission android:pathPrefix="/private" ... />
uriMatcher.addURI("com.example", "/private", CODE_PRIVATE);
content://com.example//private
The Uri above will pass the security check, since it's not
technically a prefix match. But the UriMatcher will then match it
as CODE_PRIVATE, since it ignores the "//" zero-length path.
Since we can't safely change the behavior of either path-permission
or UriMatcher, we're left with recovering these shady paths by
trimming away zero-length paths.
Bug:
112555574
Test: cts-tradefed run cts -m CtsAppSecurityHostTestCases -t android.appsecurity.cts.AppSecurityTests
Change-Id: Ibadbfa4fc904ec54780c8102958735b03293fb9a
(cherry picked from commit
a1ec7b115cc378f0547f10cf1074a5248d42d94f)
Wayne Lin [Thu, 13 Sep 2018 07:34:10 +0000 (15:34 +0800)]
[DO NOT MERGE] Changing SUPL_ES=1 for SUPL end point control
SUPL_ES=1 ensures the GnssLocationProvider and related framework code
accepts incoming SMS SUPL_INIT messages with ES-bit=1
(which allow redirection of the ESLP
end-point e.g. to the current local emergency services provider when
you are travelling) only during an emergency call
Bug:
115331218
Bug:
112159033
Test: Build pass
Change-Id: I5075f7887a184ce18bb1815b35a2ce7acd8bca10
(cherry picked from commit
02f38c7284f183d5e1fc39fe56903a567ff3fc20)
Chih-Wei Huang [Thu, 18 Oct 2018 07:47:19 +0000 (15:47 +0800)]
pm: ignore restorecon failure
On the 9p filesystem, restorecon won't work. It causes apk can't be
installed. Just ignore the errors to workaround it.
Chih-Wei Huang [Tue, 9 Oct 2018 09:32:55 +0000 (17:32 +0800)]
Merge tag 'android-8.1.0_r48' into oreo-x86
Android 8.1.0 release 48
android-build-team Robot [Fri, 28 Sep 2018 23:14:06 +0000 (23:14 +0000)]
Merge cherrypicks of [
5141855] into oc-m8-release
Change-Id: I6cad0b3abf3d6310ad835765629eaa5fc57d2e2f
Atanas Kirilov [Fri, 28 Sep 2018 20:22:08 +0000 (20:22 +0000)]
RESTRICT AUTOMERGE: Revert "RESTRICT AUTOMERGE: Check both self and shared user id package for requested permissions."
This reverts commit
05dc947c63a2304adce53a0aef6b0e0a9db9343a.
Reason for revert: Not a security fix and the security fix needs this cl is reverted.
Bug:
114365189
Change-Id: Id667b1c4d1a1af27837f553d7461283b22e5e41f
(cherry picked from commit
bb4dcd1099cac4e0b3602e3d2ac088b796df3691)
android-build-team Robot [Tue, 11 Sep 2018 23:09:12 +0000 (23:09 +0000)]
Merge cherrypicks of [
4995494,
4995495,
4995496,
4995497,
4997652,
4997881,
4997052,
4997883,
4995518,
4997653,
4997654] into oc-m8-release
Change-Id: Ib795e893dd306cb76180e8b18e1af21e2cd0598a
Michael Wachenschwanz [Sat, 25 Aug 2018 04:50:35 +0000 (21:50 -0700)]
Verify number of Map entries written to Parcel
Make sure the number of entries written by Parcel#writeMapInternal
matches the size written. If a mismatch were allowed, an exploitable
scenario could occur where the data read from the Parcel would not
match the data written.
Fixes:
112859604
Test: cts-tradefed run cts -m CtsOsTestCases -t android.os.cts.ParcelTest
Change-Id: I325d08a8b66b6e80fe76501359c41b6656848607
Merged-In: I325d08a8b66b6e80fe76501359c41b6656848607
(cherry picked from commit
057a01d1f38e9b46d3faa4059fdd7c8717681ea0)
akirilov [Fri, 24 Aug 2018 22:43:05 +0000 (15:43 -0700)]
RESTRICT AUTOMERGE: Check both self and shared user id package for requested permissions.
Bug:
111752150
Test: Manual local test
Change-Id: I0b48a20525f87fc6f5ab8d7e70aa7d11cd747f97
(cherry picked from commit
05dc947c63a2304adce53a0aef6b0e0a9db9343a)
Wale Ogunwale [Wed, 16 May 2018 23:42:29 +0000 (16:42 -0700)]
RESTRICT AUTOMERGE: Hide overlay windows when requesting media projection permission.
1: Cherry-pick ag/
4067454 - Setting PRIVATE_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS
updateNonSystemOverlayWindowsVisibilityIfNeeded on relayoutWindow
2: Cherry-pick ag/
3650369 - If PRIVATE_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS changed on
relayoutWindow() then updateNonSystemOverlayWindowsVisibilityIfNeeded
3: Add permissions to SystemUI to allow it to hide non-system overlays
Bug:
34170870
Test: manual (see bug for poc)
Change-Id: I57cb0f390d9a78e721c5ddce49a377d385002753
(cherry picked from commit
40f7b5832291ec81b921d9d7598447653d926604)
Chih-Wei Huang [Mon, 10 Sep 2018 15:47:11 +0000 (23:47 +0800)]
Merge tag 'android-8.1.0_r46' into oreo-x86
Android 8.1.0 Release 46 (OPM6.171019.030.K1)
android-build-team Robot [Thu, 30 Aug 2018 04:26:34 +0000 (04:26 +0000)]
Merge cherrypicks of [
4897833,
4897834,
4897835] into oc-m8-release
Change-Id: I641b54fb04008ba92c1fc4473ddfccabe947ab7e
Elisa Pascual Trevino [Wed, 29 Aug 2018 23:20:38 +0000 (23:20 +0000)]
Revert "RESTRICT AUTOMERGE: Revoke permissions defined in a to-be removed package."
This reverts commit
821076440434443af4257c5ba0b7b1f037735041.
Reason for revert: b/
111752150
Change-Id: I035cfcacaeaf798b8aea7fe62376624d06c64388
(cherry picked from commit
9cd13a2bd5ca2546da7a15182b0ddf1a81f2e7da)
Mauro Rossi [Thu, 9 Aug 2018 23:12:22 +0000 (01:12 +0200)]
Modify color inversion matrix to swap Red and Blue colors
Instead of color inversion it will produce Red and Blue colors swap,
in order to correct displayed colors for R4xx and other old drivers
still based on KMS API
android-build-team Robot [Thu, 16 Aug 2018 01:24:44 +0000 (01:24 +0000)]
Merge cherrypicks of [
4787660,
4787680,
4787071,
4787700,
4787592,
4787701,
4787720,
4787721,
4787072,
4787073,
4787074,
4787075,
4787076,
4787077,
4787740,
4787760,
4787722,
4787723,
4787724,
4787725,
4787726,
4787727,
4787728,
4787729,
4787730,
4787731] into oc-m8-release
Change-Id: I38f40dabd3b571920f41b122978558e0eac4d060
Seigo Nonaka [Thu, 19 Jul 2018 23:22:02 +0000 (16:22 -0700)]
Fix crash during cursor moving on BiDi text
The crash was introduced by Ib66ef392c19c937718e7101f6d48fac3abe51ad0
The root cause of the crashing is requesting out-of-line access for the
horizontal width. This invalid access is silently ignored by
TextLine#measure() method but new implementation end up with out of
bounds access.
To makes behavior as old implementation, calling getHorizontal instead
of accessing measured result array.
Bug:
78464361,
111580019
Test: Manually done
Change-Id: I5c5778718f6b397adbb1e4f2cf95e9f635f6e5c8
(cherry picked from commit
960647d582911ae7ab8b9491097898e6c313aaf1)
Merged-In: I5c5778718f6b397adbb1e4f2cf95e9f635f6e5c8
(cherry picked from commit
d30c55e3ccf25668fcbccf29c94224fd1d2e67b6)
akirilov [Thu, 19 Jul 2018 00:50:05 +0000 (17:50 -0700)]
RESTRICT AUTOMERGE: Revoke permissions defined in a to-be removed package.
Bug:
67319274
Test: run cts-dev --module CtsPermissionTestCases --test android.permission.cts.RemovePermissionTest#permissionShouldBeRevokedIfRemoved
Change-Id: I2771c048e13529e168121c5a5501aa26fc21e30f
(cherry picked from commit
821076440434443af4257c5ba0b7b1f037735041)
Jeff Sharkey [Wed, 25 Jul 2018 20:52:14 +0000 (14:52 -0600)]
DO NOT MERGE. Extend SQLiteQueryBuilder for update and delete.
Developers often accept selection clauses from untrusted code, and
SQLiteQueryBuilder already supports a "strict" mode to help catch
SQL injection attacks. This change extends the builder to support
update() and delete() calls, so that we can help secure those
selection clauses too.
Bug:
111085900
Test: atest packages/providers/DownloadProvider/tests/
Test: atest cts/tests/app/src/android/app/cts/DownloadManagerTest.java
Test: atest cts/tests/tests/database/src/android/database/sqlite/cts/SQLiteQueryBuilderTest.java
Change-Id: Ib4fc8400f184755ee7e971ab5f2095186341730c
Merged-In: Ib4fc8400f184755ee7e971ab5f2095186341730c
(cherry picked from commit
09d49531334ce6bc4ac45de1d3d0edb1495c0566)
Jeff Sharkey [Wed, 25 Jul 2018 20:01:59 +0000 (14:01 -0600)]
DO NOT MERGE. Execute "strict" queries with extra parentheses.
SQLiteQueryBuilder has a setStrict() mode which can be used to
detect SQL attacks from untrusted sources, which it does by running
each query twice: once with an extra set of parentheses, and if that
succeeds, it runs the original query verbatim.
This sadly doesn't catch inputs of the type "1=1) OR (1=1", which
creates valid statements for both tests above, but the final executed
query ends up leaking data due to SQLite operator precedence.
Instead, we need to continue compiling both variants, but we need
to execute the query with the additional parentheses to ensure
data won't be leaked.
Test: atest cts/tests/tests/database/src/android/database/sqlite/cts/SQLiteQueryBuilderTest.java
Bug:
111085900
Change-Id: I6e8746fa48f9de13adae37d2990de11c9c585381
Merged-In: I6e8746fa48f9de13adae37d2990de11c9c585381
(cherry picked from commit
5a55a72fcd18fb676eb4c114e62048068f71c01a)
Jeff Sharkey [Tue, 7 Aug 2018 21:02:17 +0000 (15:02 -0600)]
DO NOT MERGE. Persistable Uri grants still require permissions.
When FLAG_GRANT_PERSISTABLE_URI_PERMISSION is requested, we still
need to check permissions between the source and target packages,
instead of shortcutting past them.
The spirit of the original change is remains intact: if the caller
requested FLAG_GRANT_PERSISTABLE_URI_PERMISSION, then we avoid
returning "-1", which would prevent the grant data structure from
being allocated.
Bug:
111934948
Test: atest android.appsecurity.cts.AppSecurityTests
Change-Id: Ief0fc922aa09fc3d9bb6a126c2ff5855347cd030
Merged-In: Ief0fc922aa09fc3d9bb6a126c2ff5855347cd030
(cherry picked from commit
05519b7e3d0f3d16ddfe6ee3892c8468a2c10c62)
Mihai Popa [Wed, 9 May 2018 16:31:48 +0000 (17:31 +0100)]
Optimise the hit test algorithm
Layout#getOffsetForHorizontal was running in O(n^2) time, where n is the
length of the current line. The method is used when a touch event
happens on a text line, to compute the cursor offset (and the character)
where it happened. Although this is not an issue in common usecases,
where the number of characters on a line is relatively small, this can
be very inefficient as a consequence of Unicode containing 0-width
(invisible) characters. Specifically, there are characters defining the
text direction (LTR or RTL), which cause our algorithm to touch the
worst case quadratic runtime. For example, a person is able to send a
message containing a few visible characters, and also a lot of these
direction changing invisible ones. When the receiver touches the message
(causing the Layout#getOffsetForHorizontal method to be called), the
receiver's application would become not responsive.
This CL optimizes the method to run in O(n) worst case. This is achieved
by computing the measurements of all line prefixes at first, which can
be done in a single pass. Then, all the prefix measurement queries will
be answered in O(1), rather than O(n) as it was happening before.
Bug:
79215201
Test: manual testing
Change-Id: Ib66ef392c19c937718e7101f6d48fac3abe51ad0
Merged-In: Ib66ef392c19c937718e7101f6d48fac3abe51ad0
(cherry picked from commit
69b589b21d02cd380a6827c39e56cbd12a804ffd)
android-build-team Robot [Fri, 10 Aug 2018 20:33:14 +0000 (20:33 +0000)]
Merge cherrypicks of [
4741663,
4741664,
4741665,
4741666,
4743080,
4743081,
4743082,
4743083,
4741262,
4741263,
4741264,
4741265,
4741266,
4741667,
4743084,
4741242,
4741243,
4741741,
4741742,
4741743,
4741744,
4741822,
4743085,
4741668,
4741338,
4743055,
4743056,
4743070,
4743073,
4743075,
4743076,
4743078,
4743079,
4743161,
4743162,
4743164,
4743165,
4743167,
4743168,
4743169,
4743170,
4741681,
4741682,
4741683,
4741684,
4741685,
4741686,
4741687,
4741688,
4741689,
4741690,
4741691,
4741692,
4741693,
4741694,
4741695,
4741696,
4741697,
4741698,
4741699,
4743240,
4743241,
4743242,
4743243,
4741745,
4741823,
4741824,
4741825,
4741267,
4741268,
4743244,
4743280,
4743281,
4743224,
4743203,
4743204,
4743205,
4741746,
4741747,
4743245,
4741826,
4741827,
4741828,
4741829,
4741748,
4741749,
4741750,
4743233,
4743282,
4741244,
4741245,
4741246,
4741247,
4743206,
4743207,
4743208,
4743209,
4743210,
4743211,
4743212,
4743213,
4743214,
4743215,
4743216,
4743217,
4743218,
4743219,
4743360,
4743361,
4743362,
4743363,
4743364,
4743365,
4743366,
4743367,
4743368,
4743369,
4743370,
4743371,
4743372,
4743373,
4743374,
4743375,
4743376,
4743377,
4743283,
4743284,
4741830,
4742501,
4743246,
4743086,
4743087,
4743378,
4743379,
4741751] into sparse-
4749909-L04200000199131547
Change-Id: I1492186998ee5230a67cd2efaf8c68d8b008cb7e
Robert Shih [Mon, 9 Jul 2018 20:38:31 +0000 (13:38 -0700)]
Fix TrackInfo parcel write
Bug:
77600398
Change-Id: Ia316f1c5dc4879f6851fdb78fe8b9039579be7bc
(cherry picked from commit
0d2dc943dcaa3d7c8479e22ae62be9753ea2643c)
Bernie Innocenti [Mon, 28 May 2018 13:04:37 +0000 (22:04 +0900)]
vpn: allow IPSec traffic through Always-on VPN
This won't leak any traffic outside the VPN as long as there are no
processes owned by uid 0 which generate network traffic (which is
currently the case).
Bug:
69873852
Test: compared the output of 'adb shell ip rule show' before and after
Test: runtest -x frameworks/base/tests/net/java/com/android/server/connectivity/VpnTest.java
Test: local CTS tests run: android.net.cts.VpnServiceTest
Test: local CTS tests run: com.android.cts.devicepolicy.MixedDeviceOwnerTest
Change-Id: I8758e576c9d961d73f62bfcf0559dd7ecee6e8e6
Merged-In: I8758e576c9d961d73f62bfcf0559dd7ecee6e8e6
Merged-In: I1f9b78c8f828ec2df7aba71b39d62be0c4db2550
Merged-In: I8edeb0942e661c8385ff0cd3fdb72e6f62a8f218
(cherry picked from commit
00000fe55a4729f8339afdc7eab5c970b2549813)
(cherry picked from commit
ef2910dc709d698b6476e8d462c608d04c784a26)
Arthur Ishiguro [Mon, 25 Jun 2018 18:31:33 +0000 (11:31 -0700)]
Resolve inconsistent parcel read in NanoAppFilter
Bug:
77599679
Test: Compile only
Change-Id: Ib417a5cb4d51744442d2fb14437cabbe5fd1c266
(cherry picked from commit
abe5a73a4a81e312a1690fbc10a6b99ce98b699a)
Makoto Onuki [Tue, 12 Jun 2018 20:01:42 +0000 (13:01 -0700)]
Backport Prevent shortcut info package name spoofing
Test: cts-tradefed run cts -m CtsShortcutManagerTestCases -t android.content.pm.cts.shortcutmanager.ShortcutManagerFakingPublisherTest
Bug:
109824443
Change-Id: I90443973aaef157d357b98b739572866125b2bbc
Merged-In: I78948446a63b428ae750464194558fd44a658493
(cherry picked from commit
9e21579a11219581a0c08ff5dd6ac4dc22e988a4)
Ryan Mitchell [Wed, 30 May 2018 19:17:01 +0000 (12:17 -0700)]
Fix DynamicRefTable::load security bug
DynamicRefTables parsed from apks are missing bounds checks that prevent
buffer overflows. This changes verifies the bounds of the header before
attempting to preform operations on the chunk.
Bug:
79488511
Test: run cts -m CtsAppSecurityHostTestCases \
-t android.appsecurity.cts.CorruptApkTests
Change-Id: I02c8ad957da244fce777ac68a482e4e8fa70f846
Merged-In: I02c8ad957da244fce777ac68a482e4e8fa70f846
(cherry picked from commit
18a6ada4aa136da4f50f03fff91d61d448ced195)
Ryan Mitchell [Mon, 21 May 2018 20:59:23 +0000 (13:59 -0700)]
ResStringPool: Prevenet boot loop from se fix
Changes the logs adding in a previous security fix to warnings so
devices with malformed APKs currently on them will not undergo DOS when
they are upgraded to P.
Bug:
79724567
Test: run cts -m CtsAppSecurityHostTestCases \
-t android.appsecurity.cts.CorruptApkTests
Change-Id: Ied54e4bb14abdaf79da562022c7ea6075187c1f8
(cherry picked from commit
f05f47b2c1838529e682ad8f931d3da72244b1a1)
(cherry picked from commit
c31cf80008fdb06ea8e1eab9764096653e7854b1)
Todd Kennedy [Thu, 3 May 2018 09:05:04 +0000 (10:05 +0100)]
Make safe label more safe
* limit the absolute maximum size of the label to 50000 characters
[which is probably far more than necessary, but, can be dialed down]
* use a string buffer while processing the string [instead of creating
multiple string objects]
Bug:
62537081
Test: Manual. Install APK in bug and see that it can be uninstalled
Change-Id: Ibf63c2691ad7438a123e92110d95b1f50050f8b1
Merged-In: Ibf63c2691ad7438a123e92110d95b1f50050f8b1
(cherry picked from commit
2263da9539daef134395226a2718ba2d7af7547d)
Adrian Roos [Tue, 22 May 2018 14:56:35 +0000 (16:56 +0200)]
WM: Prevent secondary display focus while keyguard is up
Fixes an issue where input intended for the keyguard could end up going
to a different display.
To prevent this, make sure that only the default display can get focused
when the keyguard is showing.
Change-Id: I6463c44aedca06930d2c9bda7c45ffd93141308c
Merged-In: I6463c44aedca06930d2c9bda7c45ffd93141308c
Fixes:
71786287
Test: atest DisplayContentTests
(cherry picked from commit
3cd5e3d9bbb3255e874b8fa27d7ed506164905dd)
Benedict Wong [Tue, 20 Feb 2018 23:19:59 +0000 (15:19 -0800)]
DO NOT MERGE: Add unit tests to ensure VPN meteredness
These new tests ensure that VPNs report the meteredness of their
underlying networks correctly. The added test verifies VPN meteredness
for cases of metered and unmetered WiFi and Cell
Bug:
78644887
Test: This; ran on walleye-eng
Change-Id: I28bdc71a336bfd97f7908455d4781d774df44b87
(cherry picked from commit
66bc52884b1009fca7917ae89e72e8aa40f394d1)
Benedict Wong [Fri, 4 May 2018 04:07:58 +0000 (21:07 -0700)]
DO NOT MERGE: Fix ConnectivityController meteredness checks
This patch corrects ConnectivityController's meteredness checks to
perform correct meteredness checks while VPNs are running. This fixes a
bug in O-MR1 where any apps using the DownloadProvider with unmetered
network constraints fail to start while the VPN is enabled.
This change adds a bespoke method for ConnectivityController, allowing
it to correctly identify the meteredness without affecting public API
surfaces.
Bug:
78644887
Test: Built, flashed on Walleye, and tested.
Test: Additional test coverage in subsequent patch(es).
Change-Id: Ie1d11d93d51d936ce81cd5984af61bde30325983
(cherry picked from commit
d08ab5a641d9d81314c9439724dd34338fa81d58)
Tony Mak [Thu, 14 Dec 2017 12:40:07 +0000 (12:40 +0000)]
clearCallingIdentity before calling into getPackageUidAsUser
Fix:
70585244
Bug:
69981755
Test: Enable any accessibility service -> inflate work profile
-> Tap on any work app -> no longer crash
Test: cts-tradefed run cts-dev --module DevicePolicyManager --test com.android.cts.devicepolicy.CrossProfileAppsHostSideTest.testPrimaryUserToManagedProfile
Change-Id: I80d18f4e2ab76a228cb0aa2c8312c323a9b5c84d
(cherry picked from commit
857326e3731939f6ec7979e1d86585bf0ea484f4)
Eugene Susla [Mon, 11 Dec 2017 18:07:03 +0000 (10:07 -0800)]
Nullcheck to fix Autofill CTS
Test: presubmit
Fixes:
70506475
Bug:
69981755
Change-Id: I187bed4889a4901a7137a2995178ea651ed09186
(cherry picked from commit
6c68a692880b7cc981e130aace0edb9f2fcffff6)
Ecco Park [Thu, 3 May 2018 21:49:40 +0000 (14:49 -0700)]
Osu: fixed Mismatch between createFromParcel and writeToParcel
Bug:
77600924
Change-Id: I46d765892e8e6839ed5140a3b0d6bb1815ccf9bc
Signed-off-by: Ecco Park <eccopark@google.com>
(cherry picked from commit
9a59cf84506e9fa841524ac2c70ae683449e709a)
Hansong Zhang [Thu, 26 Apr 2018 21:22:39 +0000 (14:22 -0700)]
DO NOT MERGE Truncate newline and tab characters in BluetoothDevice name
Test: manual
Bug:
73173182
Change-Id: I7f2201cab36adf7f01d1a794d783cb78a536811f
(cherry picked from commit
24da173b63b17a0bc6c80b2fcfefa7fe4574a15b)
sqian [Sat, 14 Apr 2018 00:10:05 +0000 (17:10 -0700)]
Fix broken check for TelephonyManager#getForbiddenPlmns
(backport from a fix merged in pi-dev)
Bug:
73884967
Test: Treehugger
Change-Id: I9deaae20893184cde36dcd936fe83708fa60b830
Merged-In: I0cf7920e138892fbcab71fae0eed1293f0b2e404
Merged-In: I9e3456e5f1e479b0e2b102f6c90db57cd0e977fe
(cherry picked from commit
7b52a48d6b10e3ed2806b57d39a2d9211dd4b585)
Philip P. Moltmann [Thu, 12 Apr 2018 21:45:14 +0000 (14:45 -0700)]
DO NOT MERGE (O) Revoke permision when group changed
If a run time permission of a group is already granted we grant the
other permission of the group automatically when requested.
Hence if an already granted permission changed its group during an
update suddenly permission of a potentially not approved group will
get auto-granted.
This is undesirable, hence we revoke the permission during the update
process.
Test: atest android.permission.cts.PermissionGroupChange
Change-Id: Ib2165d1ae53b80455ebe02e07775853e37a2e339
Fixes:
72710897
(cherry picked from commit
0ed1b472af194896fcf421dc862c443343c7c127)
y [Fri, 6 Apr 2018 00:57:27 +0000 (17:57 -0700)]
ResStringPool: Fix security vulnerability
Adds detection of attacker-modified size and data fields passed to
ResStringPool::setTo(). These attacks are modified apks that AAPT would
not normally generate. In the rare case this occurs, the installation
cannot be allowed to continue.
Bug:
71361168
Bug:
71360999
Test: run cts -m CtsAppSecurityHostTestCases \
-t android.appsecurity.cts.CorruptApkTests
Change-Id: If7eb93a9e723b16c8a0556fc4e20006aa0391d57
Merged-In: If7eb93a9e723b16c8a0556fc4e20006aa0391d57
(cherry picked from commit
7e54c3f261d81316b75cb734075319108d8bc1d1)
akirilov [Tue, 27 Mar 2018 20:08:47 +0000 (13:08 -0700)]
RESTRICT AUTOMERGE: Prevent reporting fake package name - framework (backport to oc-mr1-dev)
Test: added AccessibilityEndToEndTest#testPackageNameCannotBeFaked
cts-tradefed run cts -m CtsAccessibilityServiceTestCases
cts-tradefed run cts -m CtsAccessibilityTestCases
Bug:
69981755
Change-Id: If3752e106aa7fdee4645dc9852289af471ceff18
Merged-In: I13304efbee10d1affa087e9c8bc4ec237643283e
(cherry picked from commit
c36db6d473c9988496cd614924ee113b67f7e333)
Fyodor Kupolov [Fri, 16 Mar 2018 19:20:40 +0000 (12:20 -0700)]
Use concrete CREATOR instance for parceling lists
Replaced readTypedArrayList/writeTypedArrayList with
writeTypedList/createTypedArrayList(CREATOR)
Bug:
71508348
Test: CtsAutoFillServiceTestCases pass
Merged-In: I2a8321023b40cc74b7026eb0fb32a9cc5f5543a9
Change-Id: Id17d02e40a4ae567bf2d74d2ea8ba4d8a943bdb7
(cherry picked from commit
4921986db76b1580bcb6ec8b2fd381d1364a6325)
Marco Nelissen [Tue, 7 Nov 2017 21:52:02 +0000 (13:52 -0800)]
Rework thumbnail cleanup
Bug:
63766886
Test: ran CTS tests
Change-Id: I1f92bb014e275eafe3f42aef1f8c817f187c6608
(cherry picked from commit
6d2096f3889d38da60099b1b5678347de4f042bf)
Felipe Leme [Mon, 22 Jan 2018 23:33:40 +0000 (15:33 -0800)]
DO NOT MERGE - fix AFM.getComponentNameFromContext()
This method broke on O-MR1 when I3abf999eb6056c1df7982780bae43b58337c0668
was chery-picked from master.
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases \
-t android.autofillservice.cts.AttachedContextActivityTest#testAutofill
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases
Also individually ran tests that failed (due to flakiness) when ran in a suite:
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases \
-t android.autofillservice.cts.OptionalSaveActivityTest#testDontShowSaveUiWhenUserManuallyFilled_oneDatasetAllRequiredFields
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases -t android.autofillservice.cts.PreSimpleSaveActivityTest #testTapLink_tapBack_thenStartOverBySayingYesAndManualRequest
Fixes:
71960322
Change-Id: Ia093dcefe6699dc9493c46d671e48c2000214b31
Merged-In: I3abf999eb6056c1df7982780bae43b58337c0668
(cherry picked from commit
b25b4736db2ea05dce6b9f03e8a9920ab338dd5a)
Felipe Leme [Mon, 11 Dec 2017 22:37:35 +0000 (14:37 -0800)]
Proper autofill fix to let phone process autofill Settings activity.
Test: adb shell am start com.android.settings/.RadioInfo
Bug:
69981710
Fixes:
70506888
Change-Id: Id29bad2d20b621f7379eb6144c95dcc819949b3d
Merged-In: Id29bad2d20b621f7379eb6144c95dcc819949b3d
(cherry picked from commit
97f16a76db29269619d9a1b45d4cea49026a5b6a)
(cherry picked from commit
92b5d2783a1b97bee476f04754481403839b4e45)
Felipe Leme [Fri, 1 Dec 2017 01:41:57 +0000 (17:41 -0800)]
Make sure apps cannot forge package name on AssistStructure used for Autofill.
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases -t android.autofillservice.cts.VirtualContainerActivityTest#testAppCannotFakePackageName
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases
Bug:
69981710
Change-Id: Id6036cddb51dd8dd0c9128b7212d573f630d693f
Merged-In: Id6036cddb51dd8dd0c9128b7212d573f630d693f
(cherry picked from commit
23e61a9086a34405e277868474e003b37ed1b711)
android-build-team Robot [Fri, 3 Aug 2018 19:20:35 +0000 (19:20 +0000)]
Merge cherrypicks of [
4691111,
4689862,
4690575,
4690576,
4690577,
4690578,
4689866,
4689868,
4689869,
4689870,
4691132,
4689456,
4689963,
4691133,
4691134,
4691156,
4691157,
4691159,
4691161,
4690581,
4689964,
4689460,
4691112,
4690582,
4690583,
4691165,
4691166,
4691167,
4691168,
4691169,
4691170,
4691211,
4691212,
4691213,
4691214,
4691215,
4691216,
4691217,
4691218,
4691219,
4691232,
4691233,
4691234,
4691235,
4691236,
4691237,
4691238,
4691239,
4691240,
4691241,
4691243,
4691245,
4691247,
4691249,
4691250,
4691291,
4691292,
4691293,
4691294,
4691295,
4691296,
4691255,
4689476,
4689477,
4689478,
4691223,
4691224,
4691136,
4689479,
4689480,
4691137,
4691225,
4691226,
4691227,
4691371,
4691228,
4691328,
4689967,
4691138,
4691139,
4691140,
4691433,
4689968,
4689969,
4691395,
4691230,
4691297,
4691298,
4691299,
4691300,
4691396,
4691397,
4691398,
4691399,
4691400,
4691401,
4691402,
4691403,
4691404,
4691405,
4691406,
4691407,
4691408,
4691409,
4691410,
4691471,
4691472,
4691473,
4691474,
4691475,
4691476,
4691477,
4691478,
4691479,
4691480,
4691481,
4691482,
4691483,
4691484,
4691485,
4691486,
4691487,
4691488,
4691143,
4691144,
4691511,
4691113,
4689482,
4691533,
4691145,
4691146,
4691147,
4691148,
4691536] into sparse-
4732991-L01200000196794104
Change-Id: Ia22e17bb167b1d67bcce73a5f95c44c9649f2c08
Robert Shih [Mon, 9 Jul 2018 20:38:31 +0000 (13:38 -0700)]
Fix TrackInfo parcel write
Bug:
77600398
Change-Id: Ia316f1c5dc4879f6851fdb78fe8b9039579be7bc
(cherry picked from commit
0d2dc943dcaa3d7c8479e22ae62be9753ea2643c)
Bernie Innocenti [Mon, 28 May 2018 13:04:37 +0000 (22:04 +0900)]
vpn: allow IPSec traffic through Always-on VPN
This won't leak any traffic outside the VPN as long as there are no
processes owned by uid 0 which generate network traffic (which is
currently the case).
Bug:
69873852
Test: compared the output of 'adb shell ip rule show' before and after
Test: runtest -x frameworks/base/tests/net/java/com/android/server/connectivity/VpnTest.java
Test: local CTS tests run: android.net.cts.VpnServiceTest
Test: local CTS tests run: com.android.cts.devicepolicy.MixedDeviceOwnerTest
Change-Id: I8758e576c9d961d73f62bfcf0559dd7ecee6e8e6
Merged-In: I8758e576c9d961d73f62bfcf0559dd7ecee6e8e6
Merged-In: I1f9b78c8f828ec2df7aba71b39d62be0c4db2550
Merged-In: I8edeb0942e661c8385ff0cd3fdb72e6f62a8f218
(cherry picked from commit
00000fe55a4729f8339afdc7eab5c970b2549813)
(cherry picked from commit
ef2910dc709d698b6476e8d462c608d04c784a26)
Arthur Ishiguro [Mon, 25 Jun 2018 18:31:33 +0000 (11:31 -0700)]
Resolve inconsistent parcel read in NanoAppFilter
Bug:
77599679
Test: Compile only
Change-Id: Ib417a5cb4d51744442d2fb14437cabbe5fd1c266
(cherry picked from commit
abe5a73a4a81e312a1690fbc10a6b99ce98b699a)
Makoto Onuki [Tue, 12 Jun 2018 20:01:42 +0000 (13:01 -0700)]
Backport Prevent shortcut info package name spoofing
Test: cts-tradefed run cts -m CtsShortcutManagerTestCases -t android.content.pm.cts.shortcutmanager.ShortcutManagerFakingPublisherTest
Bug:
109824443
Change-Id: I90443973aaef157d357b98b739572866125b2bbc
Merged-In: I78948446a63b428ae750464194558fd44a658493
(cherry picked from commit
9e21579a11219581a0c08ff5dd6ac4dc22e988a4)
Ryan Mitchell [Wed, 30 May 2018 19:17:01 +0000 (12:17 -0700)]
Fix DynamicRefTable::load security bug
DynamicRefTables parsed from apks are missing bounds checks that prevent
buffer overflows. This changes verifies the bounds of the header before
attempting to preform operations on the chunk.
Bug:
79488511
Test: run cts -m CtsAppSecurityHostTestCases \
-t android.appsecurity.cts.CorruptApkTests
Change-Id: I02c8ad957da244fce777ac68a482e4e8fa70f846
Merged-In: I02c8ad957da244fce777ac68a482e4e8fa70f846
(cherry picked from commit
18a6ada4aa136da4f50f03fff91d61d448ced195)
Ryan Mitchell [Mon, 21 May 2018 20:59:23 +0000 (13:59 -0700)]
ResStringPool: Prevenet boot loop from se fix
Changes the logs adding in a previous security fix to warnings so
devices with malformed APKs currently on them will not undergo DOS when
they are upgraded to P.
Bug:
79724567
Test: run cts -m CtsAppSecurityHostTestCases \
-t android.appsecurity.cts.CorruptApkTests
Change-Id: Ied54e4bb14abdaf79da562022c7ea6075187c1f8
(cherry picked from commit
f05f47b2c1838529e682ad8f931d3da72244b1a1)
(cherry picked from commit
c31cf80008fdb06ea8e1eab9764096653e7854b1)
Todd Kennedy [Thu, 3 May 2018 09:05:04 +0000 (10:05 +0100)]
Make safe label more safe
* limit the absolute maximum size of the label to 50000 characters
[which is probably far more than necessary, but, can be dialed down]
* use a string buffer while processing the string [instead of creating
multiple string objects]
Bug:
62537081
Test: Manual. Install APK in bug and see that it can be uninstalled
Change-Id: Ibf63c2691ad7438a123e92110d95b1f50050f8b1
Merged-In: Ibf63c2691ad7438a123e92110d95b1f50050f8b1
(cherry picked from commit
2263da9539daef134395226a2718ba2d7af7547d)
Adrian Roos [Tue, 22 May 2018 14:56:35 +0000 (16:56 +0200)]
WM: Prevent secondary display focus while keyguard is up
Fixes an issue where input intended for the keyguard could end up going
to a different display.
To prevent this, make sure that only the default display can get focused
when the keyguard is showing.
Change-Id: I6463c44aedca06930d2c9bda7c45ffd93141308c
Merged-In: I6463c44aedca06930d2c9bda7c45ffd93141308c
Fixes:
71786287
Test: atest DisplayContentTests
(cherry picked from commit
3cd5e3d9bbb3255e874b8fa27d7ed506164905dd)
Benedict Wong [Tue, 20 Feb 2018 23:19:59 +0000 (15:19 -0800)]
DO NOT MERGE: Add unit tests to ensure VPN meteredness
These new tests ensure that VPNs report the meteredness of their
underlying networks correctly. The added test verifies VPN meteredness
for cases of metered and unmetered WiFi and Cell
Bug:
78644887
Test: This; ran on walleye-eng
Change-Id: I28bdc71a336bfd97f7908455d4781d774df44b87
(cherry picked from commit
66bc52884b1009fca7917ae89e72e8aa40f394d1)
Benedict Wong [Fri, 4 May 2018 04:07:58 +0000 (21:07 -0700)]
DO NOT MERGE: Fix ConnectivityController meteredness checks
This patch corrects ConnectivityController's meteredness checks to
perform correct meteredness checks while VPNs are running. This fixes a
bug in O-MR1 where any apps using the DownloadProvider with unmetered
network constraints fail to start while the VPN is enabled.
This change adds a bespoke method for ConnectivityController, allowing
it to correctly identify the meteredness without affecting public API
surfaces.
Bug:
78644887
Test: Built, flashed on Walleye, and tested.
Test: Additional test coverage in subsequent patch(es).
Change-Id: Ie1d11d93d51d936ce81cd5984af61bde30325983
(cherry picked from commit
d08ab5a641d9d81314c9439724dd34338fa81d58)
Tony Mak [Thu, 14 Dec 2017 12:40:07 +0000 (12:40 +0000)]
clearCallingIdentity before calling into getPackageUidAsUser
Fix:
70585244
Bug:
69981755
Test: Enable any accessibility service -> inflate work profile
-> Tap on any work app -> no longer crash
Test: cts-tradefed run cts-dev --module DevicePolicyManager --test com.android.cts.devicepolicy.CrossProfileAppsHostSideTest.testPrimaryUserToManagedProfile
Change-Id: I80d18f4e2ab76a228cb0aa2c8312c323a9b5c84d
(cherry picked from commit
857326e3731939f6ec7979e1d86585bf0ea484f4)
Eugene Susla [Mon, 11 Dec 2017 18:07:03 +0000 (10:07 -0800)]
Nullcheck to fix Autofill CTS
Test: presubmit
Fixes:
70506475
Bug:
69981755
Change-Id: I187bed4889a4901a7137a2995178ea651ed09186
(cherry picked from commit
6c68a692880b7cc981e130aace0edb9f2fcffff6)
Ecco Park [Thu, 3 May 2018 21:49:40 +0000 (14:49 -0700)]
Osu: fixed Mismatch between createFromParcel and writeToParcel
Bug:
77600924
Change-Id: I46d765892e8e6839ed5140a3b0d6bb1815ccf9bc
Signed-off-by: Ecco Park <eccopark@google.com>
(cherry picked from commit
9a59cf84506e9fa841524ac2c70ae683449e709a)
Hansong Zhang [Thu, 26 Apr 2018 21:22:39 +0000 (14:22 -0700)]
DO NOT MERGE Truncate newline and tab characters in BluetoothDevice name
Test: manual
Bug:
73173182
Change-Id: I7f2201cab36adf7f01d1a794d783cb78a536811f
(cherry picked from commit
24da173b63b17a0bc6c80b2fcfefa7fe4574a15b)
sqian [Sat, 14 Apr 2018 00:10:05 +0000 (17:10 -0700)]
Fix broken check for TelephonyManager#getForbiddenPlmns
(backport from a fix merged in pi-dev)
Bug:
73884967
Test: Treehugger
Change-Id: I9deaae20893184cde36dcd936fe83708fa60b830
Merged-In: I0cf7920e138892fbcab71fae0eed1293f0b2e404
Merged-In: I9e3456e5f1e479b0e2b102f6c90db57cd0e977fe
(cherry picked from commit
7b52a48d6b10e3ed2806b57d39a2d9211dd4b585)
Philip P. Moltmann [Thu, 12 Apr 2018 21:45:14 +0000 (14:45 -0700)]
DO NOT MERGE (O) Revoke permision when group changed
If a run time permission of a group is already granted we grant the
other permission of the group automatically when requested.
Hence if an already granted permission changed its group during an
update suddenly permission of a potentially not approved group will
get auto-granted.
This is undesirable, hence we revoke the permission during the update
process.
Test: atest android.permission.cts.PermissionGroupChange
Change-Id: Ib2165d1ae53b80455ebe02e07775853e37a2e339
Fixes:
72710897
(cherry picked from commit
0ed1b472af194896fcf421dc862c443343c7c127)
y [Fri, 6 Apr 2018 00:57:27 +0000 (17:57 -0700)]
ResStringPool: Fix security vulnerability
Adds detection of attacker-modified size and data fields passed to
ResStringPool::setTo(). These attacks are modified apks that AAPT would
not normally generate. In the rare case this occurs, the installation
cannot be allowed to continue.
Bug:
71361168
Bug:
71360999
Test: run cts -m CtsAppSecurityHostTestCases \
-t android.appsecurity.cts.CorruptApkTests
Change-Id: If7eb93a9e723b16c8a0556fc4e20006aa0391d57
Merged-In: If7eb93a9e723b16c8a0556fc4e20006aa0391d57
(cherry picked from commit
7e54c3f261d81316b75cb734075319108d8bc1d1)
akirilov [Tue, 27 Mar 2018 20:08:47 +0000 (13:08 -0700)]
RESTRICT AUTOMERGE: Prevent reporting fake package name - framework (backport to oc-mr1-dev)
Test: added AccessibilityEndToEndTest#testPackageNameCannotBeFaked
cts-tradefed run cts -m CtsAccessibilityServiceTestCases
cts-tradefed run cts -m CtsAccessibilityTestCases
Bug:
69981755
Change-Id: If3752e106aa7fdee4645dc9852289af471ceff18
Merged-In: I13304efbee10d1affa087e9c8bc4ec237643283e
(cherry picked from commit
c36db6d473c9988496cd614924ee113b67f7e333)
Fyodor Kupolov [Fri, 16 Mar 2018 19:20:40 +0000 (12:20 -0700)]
Use concrete CREATOR instance for parceling lists
Replaced readTypedArrayList/writeTypedArrayList with
writeTypedList/createTypedArrayList(CREATOR)
Bug:
71508348
Test: CtsAutoFillServiceTestCases pass
Merged-In: I2a8321023b40cc74b7026eb0fb32a9cc5f5543a9
Change-Id: Id17d02e40a4ae567bf2d74d2ea8ba4d8a943bdb7
(cherry picked from commit
4921986db76b1580bcb6ec8b2fd381d1364a6325)
Marco Nelissen [Tue, 7 Nov 2017 21:52:02 +0000 (13:52 -0800)]
Rework thumbnail cleanup
Bug:
63766886
Test: ran CTS tests
Change-Id: I1f92bb014e275eafe3f42aef1f8c817f187c6608
(cherry picked from commit
6d2096f3889d38da60099b1b5678347de4f042bf)
Felipe Leme [Mon, 11 Dec 2017 22:37:35 +0000 (14:37 -0800)]
Proper autofill fix to let phone process autofill Settings activity.
Test: adb shell am start com.android.settings/.RadioInfo
Bug:
69981710
Fixes:
70506888
Change-Id: Id29bad2d20b621f7379eb6144c95dcc819949b3d
Merged-In: Id29bad2d20b621f7379eb6144c95dcc819949b3d
(cherry picked from commit
97f16a76db29269619d9a1b45d4cea49026a5b6a)
(cherry picked from commit
92b5d2783a1b97bee476f04754481403839b4e45)
Chih-Wei Huang [Fri, 13 Jul 2018 07:02:49 +0000 (15:02 +0800)]
Merge tag 'android-8.1.0_r41' into oreo-x86
Android 8.1.0 Release 41 (OPM6.171019.030.E1)
Chih-Wei Huang [Thu, 14 Jun 2018 09:30:24 +0000 (17:30 +0800)]
Merge tag 'android-8.1.0_r33' into oreo-x86
Android 8.1.0 release 33
Chih-Wei Huang [Mon, 18 Jul 2016 14:32:13 +0000 (22:32 +0800)]
ABIPicker: match package name by patterns
PRC apps from different markets usually have different package names.
This change tries to match them by patterns.
To test it, install the Implosion apps from Wandoujia and CoolMarket
and run them OK.
jgu21 [Fri, 1 Apr 2016 04:40:31 +0000 (00:40 -0400)]
Fix the memory leak bug introduced by PRC compatibility feature
Fix the memory leak bug introduced by PRC compatibility feature,
introduced by https://android.intel.com/#/c/471490/
Change-Id: Iaf9bd21afa17f3a81ab700c63ae7c0bb0851a594
Tracked-On: https://jira01.devtools.intel.com/browse/OAM-27449
Signed-off-by: jgu21 <jinghui.gu@intel.com>
Reviewed-on: https://android.intel.com:443/489353
jgu21 [Wed, 30 Mar 2016 06:57:38 +0000 (02:57 -0400)]
Fix KW issues on PRC compatibility
Fix KW issues on PRC compatibility,introduced by below commit.
https://android.intel.com/#/c/484542/
Change-Id: Ib10899655dd2a18569387dbafbe33856acf5df59
Tracked-On: https://jira01.devtools.intel.com/browse/OAM-26904
Signed-off-by: jgu21 <jinghui.gu@intel.com>
Reviewed-on: https://android.intel.com:443/487804
xiajiang [Mon, 21 Mar 2016 16:26:06 +0000 (12:26 -0400)]
Reduce the overhead of the PRC compatibility package feature during system bootup
The PRC compatibility package introduced too heavy overhead
in system bootup. This commit aims to reduce the overhead
in system bootup and improve the performance of PRC
compatibility package.
NOTE: The format of ThirdPartySO has been changed to improve
the performance. From now on, the lib name should be trimmed
as below if want to add into the list. For "libabc_v1_2_3.so",
add "abc_v" into the list, that is, the version information
at the tail of lib name should be removed.
Change-Id: Ic374e363d3d31f9bd69be839b33b1bd65950ef61
Tracked-On:https://jira01.devtools.intel.com/browse/OAM-25819
Signed-off-by: xiajiang <xia1.jiang@intel.com>
Reviewed-on: https://android.intel.com:443/484542
xiajiang [Wed, 17 Feb 2016 18:59:14 +0000 (13:59 -0500)]
Enable the PRC compatibility package feature for PRC market
In PRC market, some APKs are packed in non-standard way, that is,
the x86(_64) libraries aren't workable although they're found in the APK.
This patch intends to relieve the impact from below 2 defects,
which is based-on the heuristic algorithm.
NOTE: To enable this feature, set "PRC_COMPATIBILITY_PACKAGE := true"
in device BoardConfig.mk before enabling houdini.
1. Missing x86(_64) libraries: The x86(_64) libraries are ported and
existing in the APK. But it's incomplete, and not workable.
2. Mixed arm(64) libraries: Several libraries are existing in lib/x86(_64)/
directory in the APK. But some of them are arm(64) libraries,
instead of x86(_64) ones.
All of above always cause APP crash if installed x86(_64) libraries
by PackageManager.
This patch aims to improve PackageManager to figure out these defects
and install arm(64) libraries to run the APP with houdini support.
The basic idea is to compare x86(_64) libraries with arm(64) alternatives
to determine which one should be workable.
To customize it for specific APPs, 3 lists are provided under
/system/vendor/etc/misc/ on the device.
1. /system/vendor/etc/misc/.OEMWhiteList:
This patch will be disabled for the APPs containing in the OEMWhiteList
2. /system/vendor/etc/misc/.OEMBlackList:
The APP is enforced to install the arm(64) libraries if existed.
3. /system/vendor/etc/misc/.ThirdPartySO:
This is another list which contains the names of all 3rd-party libraries,
which will impact on the final decision of APP installation.
Change-Id: I2613d9ebc8fe012c801f4a38fc5dede413f15a91
Tracked-On: https://jira01.devtools.intel.com/browse/OAM-20470
Signed-off-by: xiajiang <xia1.jiang@intel.com>
Reviewed-on: https://android.intel.com:443/471490
android-build-team Robot [Fri, 25 May 2018 18:43:02 +0000 (18:43 +0000)]
Merge cherrypicks of [
4195294,
4195296,
4195440,
4195441,
4186165,
4186166,
4186580,
4195442,
4195443,
4186193,
4186194,
4186195,
4186196,
4186607,
4195444,
4195297,
4186608,
4186609,
4186610,
4186611,
4186612,
4186613,
4186614,
4186649,
4186650,
4186651,
4186652,
4186653,
4186654,
4186655,
4186656,
4186657,
4195518,
4195519,
4195520,
4195521,
4195522,
4186406,
4186407,
4186408,
4195523,
4195558,
4195559,
4186197,
4195524,
4186615,
4195445,
4195446,
4186829,
4186830,
4186831,
4186832,
4186833,
4186834,
4186835,
4186836,
4186837,
4195578,
4195579,
4195580,
4195581,
4195447,
4186581,
4195448,
4195560] into sparse-
4749909-L06000000176800346
Change-Id: I0c1d22050d3841fb9c8e11abf44e608f7c132326
Tony Mak [Thu, 14 Dec 2017 12:40:07 +0000 (12:40 +0000)]
clearCallingIdentity before calling into getPackageUidAsUser
Fix:
70585244
Bug:
69981755
Test: Enable any accessibility service -> inflate work profile
-> Tap on any work app -> no longer crash
Test: cts-tradefed run cts-dev --module DevicePolicyManager --test com.android.cts.devicepolicy.CrossProfileAppsHostSideTest.testPrimaryUserToManagedProfile
Change-Id: I80d18f4e2ab76a228cb0aa2c8312c323a9b5c84d
(cherry picked from commit
857326e3731939f6ec7979e1d86585bf0ea484f4)
Eugene Susla [Mon, 11 Dec 2017 18:07:03 +0000 (10:07 -0800)]
Nullcheck to fix Autofill CTS
Test: presubmit
Fixes:
70506475
Bug:
69981755
Change-Id: I187bed4889a4901a7137a2995178ea651ed09186
(cherry picked from commit
6c68a692880b7cc981e130aace0edb9f2fcffff6)
Ecco Park [Thu, 3 May 2018 21:49:40 +0000 (14:49 -0700)]
Osu: fixed Mismatch between createFromParcel and writeToParcel
Bug:
77600924
Change-Id: I46d765892e8e6839ed5140a3b0d6bb1815ccf9bc
Signed-off-by: Ecco Park <eccopark@google.com>
(cherry picked from commit
9a59cf84506e9fa841524ac2c70ae683449e709a)
Hansong Zhang [Thu, 26 Apr 2018 21:22:39 +0000 (14:22 -0700)]
DO NOT MERGE Truncate newline and tab characters in BluetoothDevice name
Test: manual
Bug:
73173182
Change-Id: I7f2201cab36adf7f01d1a794d783cb78a536811f
(cherry picked from commit
24da173b63b17a0bc6c80b2fcfefa7fe4574a15b)
sqian [Sat, 14 Apr 2018 00:10:05 +0000 (17:10 -0700)]
Fix broken check for TelephonyManager#getForbiddenPlmns
(backport from a fix merged in pi-dev)
Bug:
73884967
Test: Treehugger
Change-Id: I9deaae20893184cde36dcd936fe83708fa60b830
Merged-In: I0cf7920e138892fbcab71fae0eed1293f0b2e404
Merged-In: I9e3456e5f1e479b0e2b102f6c90db57cd0e977fe
(cherry picked from commit
7b52a48d6b10e3ed2806b57d39a2d9211dd4b585)
Philip P. Moltmann [Thu, 12 Apr 2018 21:45:14 +0000 (14:45 -0700)]
DO NOT MERGE (O) Revoke permision when group changed
If a run time permission of a group is already granted we grant the
other permission of the group automatically when requested.
Hence if an already granted permission changed its group during an
update suddenly permission of a potentially not approved group will
get auto-granted.
This is undesirable, hence we revoke the permission during the update
process.
Test: atest android.permission.cts.PermissionGroupChange
Change-Id: Ib2165d1ae53b80455ebe02e07775853e37a2e339
Fixes:
72710897
(cherry picked from commit
0ed1b472af194896fcf421dc862c443343c7c127)
y [Fri, 6 Apr 2018 00:57:27 +0000 (17:57 -0700)]
ResStringPool: Fix security vulnerability
Adds detection of attacker-modified size and data fields passed to
ResStringPool::setTo(). These attacks are modified apks that AAPT would
not normally generate. In the rare case this occurs, the installation
cannot be allowed to continue.
Bug:
71361168
Bug:
71360999
Test: run cts -m CtsAppSecurityHostTestCases \
-t android.appsecurity.cts.CorruptApkTests
Change-Id: If7eb93a9e723b16c8a0556fc4e20006aa0391d57
Merged-In: If7eb93a9e723b16c8a0556fc4e20006aa0391d57
(cherry picked from commit
7e54c3f261d81316b75cb734075319108d8bc1d1)