Commit Graph

3099 Commits

Author SHA1 Message Date
Ahaan Ugale
37430509cf Merge "Add OnDevice to TranslationManager method names." into sc-dev am: 342ddee557
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/14012904

Change-Id: I9a1c0e90d27922c434eb9790b4ba81e2f9fa9e86
2021-03-30 06:28:54 +00:00
Ahaan Ugale
342ddee557 Merge "Add OnDevice to TranslationManager method names." into sc-dev 2021-03-30 06:13:22 +00:00
George Chang
26717af683 Merge changes from topic "update_NFCC_Always_on" am: 7b7b809587 am: 6a6d92ff09 am: f5dcd90370 am: 03259bf7a4
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1655107

Change-Id: If0f2753def656a3f74181a00a7f0401f5c414359
2021-03-30 04:14:09 +00:00
James Lin
340de4d666 Merge "Updated the RcsCapabilityExchangeImplBase APIs" am: 47dc400888 am: 4f4713ec67 am: a4829f365a am: 3afabac191
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1652213

Change-Id: I5a97bca774ce86cfc122259be267e2b88944290e
2021-03-30 04:13:31 +00:00
George Chang
03259bf7a4 Merge changes from topic "update_NFCC_Always_on" am: 7b7b809587 am: 6a6d92ff09 am: f5dcd90370
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1655107

Change-Id: I57b2db68bb05750718298d776ba2d365bea44a8b
2021-03-30 03:59:15 +00:00
James Lin
3afabac191 Merge "Updated the RcsCapabilityExchangeImplBase APIs" am: 47dc400888 am: 4f4713ec67 am: a4829f365a
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1652213

Change-Id: I9baf8f72e5dfe33d2e27554f7b8e952ab73ce95d
2021-03-30 03:57:54 +00:00
George Chang
7b7b809587 Merge changes from topic "update_NFCC_Always_on"
* changes:
  Make NFC_UID TestApi
  Update SetAlwaysOn to SetControllerAlwaysOn
  Add new permission to set NFC always on states
2021-03-30 02:17:03 +00:00
James Lin
47dc400888 Merge "Updated the RcsCapabilityExchangeImplBase APIs" 2021-03-30 01:57:10 +00:00
Makoto Onuki
43052bcc01 Merge "Add TEMPORARY_ALLOW_LIST_TYPE_NONE." into sc-dev am: d0b0f4ce83
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13957707

Change-Id: If6a03bf079c5c1e07735e446db7d2b9a944c77a9
2021-03-29 22:03:08 +00:00
Makoto Onuki
d0b0f4ce83 Merge "Add TEMPORARY_ALLOW_LIST_TYPE_NONE." into sc-dev 2021-03-29 21:32:40 +00:00
Svetoslav Ganov
77591d9942 Merge "Runtime permission attribution improvements" into sc-dev am: a6c3d6ad39
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13692058

Change-Id: Ibad155ee212f6e71800e288a44bbed6012d32838
2021-03-29 21:05:00 +00:00
Brad Ebinger
220bc70f97 Merge "Enforce READ_PHONE_STATE for APIs involving call state" into sc-dev am: 3bf5cbb891
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13986047

Change-Id: I185ceb19fc96b1c38731d68757668cd54cdff412
2021-03-29 21:03:52 +00:00
Svetoslav Ganov
a6c3d6ad39 Merge "Runtime permission attribution improvements" into sc-dev 2021-03-29 21:03:06 +00:00
Brad Ebinger
3bf5cbb891 Merge "Enforce READ_PHONE_STATE for APIs involving call state" into sc-dev 2021-03-29 20:49:36 +00:00
Ahaan Ugale
9b2f82c8a6 Add OnDevice to TranslationManager method names.
Makes the API easier to evolve in case we add user-selectable
TranslationServices later, like we do for RecognitionService.

Also makes the create.. name consistent with
SpeechRecognizer#createOnDeviceSpeechRecognizer().

Bug: 176208267
Test: atest CtsTranslationTestCases
Change-Id: I1a66bd045202025b9c5f669018c989654bcaa1ad
2021-03-29 13:10:17 -07:00
Mustafa Emre Acer
6cbc4013d5 Merge "Expose TimeManager.suggestExternalTime()" into sc-dev am: 7c4f635b3b
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13981165

Change-Id: I97665672ed668ee770874573ada04069f559ac7f
2021-03-29 19:04:12 +00:00
Mustafa Emre Acer
7c4f635b3b Merge "Expose TimeManager.suggestExternalTime()" into sc-dev 2021-03-29 18:46:59 +00:00
Sudheer Shanka
88ee72e46d Merge "Add API to allow apps with location permission to access data blobs." into sc-dev am: 624f4c5274
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13988108

Change-Id: Ied01741fd93f0be96d28eeee8e5a2b501ab89063
2021-03-29 18:40:26 +00:00
Sudheer Shanka
624f4c5274 Merge "Add API to allow apps with location permission to access data blobs." into sc-dev 2021-03-29 18:25:11 +00:00
Sudheer Shanka
d88145e1b5 Merge "Remove NetworkPolicyManager.isUidBlocked() API." am: 9cff99d059 am: 433c866186 am: 4b3348f115 am: 05f75c2553
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1652550

Change-Id: Ife9ded09ec8547baecebc29c68612e9e6d34ae7c
2021-03-29 18:22:03 +00:00
Sudheer Shanka
05f75c2553 Merge "Remove NetworkPolicyManager.isUidBlocked() API." am: 9cff99d059 am: 433c866186 am: 4b3348f115
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1652550

Change-Id: Ic5c9fb2603a010976bc93e5059e5548ee782005e
2021-03-29 17:45:42 +00:00
Richard Ho
2a7d583156 Merge changes from topic "nearby-streaming-policy" into sc-dev am: 2335acd9a2
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13957770

Change-Id: I2dbe281b81b87ecf394977da3e66e42dd4ac10dc
2021-03-29 17:22:30 +00:00
Richard Ho
5829c6d4cc Add policy for nearby notification streaming am: f15e43f250
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13758569

Change-Id: I68eaa704c436187d5b43cc76c1a41697da4c5354
2021-03-29 17:22:24 +00:00
Richard Ho
2335acd9a2 Merge changes from topic "nearby-streaming-policy" into sc-dev
* changes:
  Add policy for nearby app streaming
  Add policy for nearby notification streaming
2021-03-29 17:12:03 +00:00
Svet Ganov
8d2ed50604 Runtime permission attribution improvements
When an app is proxying access to runtime permission protected
data it needs to check whether the calling app has a permission
to the data it is about to proxy which leaves a trace in app ops
that the requesting app perofmed a data access. However, then the
app doing the work needs to get the protected data itself from the
OS which access gets attributed only to itself. As a result there
are two data accesses in app ops where only the first one is a
proxy one that app A got access to Foo through app B - that is the
one we want to show in the permission tracking UIs - and one
for the data access - that is the one we would want to blame on
the calling app, and in fact, these two accesses should be one -
that app A accessed Foo though B. This limitation requires fragile
one off workarounds where both accesses use the same attribution
tag and sys UI has hardcoded rules to dedupe. Since this is not
documented we cannot expect that the ecosystem would reliably
do this workaround in apps that that the workaround in the OS
would be respected by every OEM.

This change adds a mechaism to resolve this issue. It allows for
an app to create an attribution context for another app and then
any private data access thorugh this context would result in a
single app op blame that A accessed Foo though B, i.e. we no longer
have double accounting. Also this can be nested through apps, e.g.
app A asks app B which asks app C for contacts. In this case app
B creates an attribution context for app A and calls into app C
which creates an attribution context for app B. When app C gets
contacts the entire attribution chain would get a porper, single
blame: that C accessed the data, that B got the data from C, and
that A got the data form B. Furthermore, this mechanism ensures
that apps cannot forget to check permissions for the caller
before proxying private data. In our example B and C don't need
to check the permisisons for A and B, respectively, since the
permisisons for the entire attribution chain are checked before
data delivery. Attribution chains are not forgeable preventing
a bad actor to create an arbitrary one - each attribution is
created by the app it refers to and points to a chain of
attributions created by their corresponding apps.

This change also fixes a bug where all content provider accesses
were double counted in app ops due to double noting. While at
this it also fixes that apps can now access their own last ops.
There was a bug where one could not pass null getting the attributed
ops from a historical package ops while this is a valid use case
since if there is no attribution everything is mapped to the null
tag. There were some app op APIs not being piped thorough the app
ops delegate and by extension through the app ops policy. Also
now that we have nice way to express the permission chain in a
call we no longer need the special casing in activity manager to
handle content provider accesses through the OS. Fixed a bug
where we don't properly handle the android.os.shell calls with
an invlaid tag which was failing while the shell can do any tag.

Finally, to ensure the mechanims is validated and works end-to-end
we are adding support for a voice recognizer to blame the client
app for the mic access. The recognition service can create a blaming
context when opening the mic and if the mic is open, which would
do all permission checks, we would not do so again. Since changes
to PermissionChercker for handling attribution sources were made
the CL also hooks up renounced permissoins in the request permission
flow and in the permission checks.

bug:158792096
bug:180647319

Test:atest CtsPermissionsTestCases
     atest CtsPermissions2TestCases
     atest CtsPermissions3TestCases
     atest CtsPermissions4TestCases
     atest CtsPermissions5TestCases
     atest CtsAppOpsTestCases
     atest CtsAppOps2TestCases

Change-Id: Ib04585515d3dc3956966005ae9d94955b2f3ee08
2021-03-29 16:49:33 +00:00
Lucas Dupin
ad0e94debe Merge "Add luma capabilities to ColorStateList" into sc-dev am: 10c1b4f3f9
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13986547

Change-Id: I1f2ac8ffd6406c42dcc207558d7fb144598ee561
2021-03-29 15:52:39 +00:00
Joanne Chung
a5941dfc50 Merge "Add translation APIs for virtual views." into sc-dev am: 2e3ea6a2ab
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13982294

Change-Id: I14e9e8bf9914b27616eefba5528181cb91c89e84
2021-03-29 15:51:55 +00:00
Lucas Dupin
10c1b4f3f9 Merge "Add luma capabilities to ColorStateList" into sc-dev 2021-03-29 15:47:05 +00:00
Joanne Chung
2e3ea6a2ab Merge "Add translation APIs for virtual views." into sc-dev 2021-03-29 15:28:23 +00:00
Kriti Dang
7010f95cb2 Hdr format settings [Backend]
Adding new APIs in display manager to get the user disabled formats, to get the formats
supported by device and get formats reported by display.

Bug: 172905874
Test: N/A
Change-Id: I58a7714f03a3e165bbd22f2fa7a021ad90b41b39
Merged-In: I58a7714f03a3e165bbd22f2fa7a021ad90b41b39
(cherry picked from commit 25f1822005)
2021-03-29 13:21:14 +00:00
Sudheer Shanka
d3ba15beeb Remove NetworkPolicyManager.isUidBlocked() API.
It isn't used by ConnectivityService any more and even if
it needs such utility method in the future, we could create
one which is part of connectivity module and doesn't need
to be exposed as part of NetworkPolicyManager API surface.

Bug: 183696103
Test: atest ./tests/net/java/com/android/server/ConnectivityServiceTest.java
Change-Id: Ie3c681f88e4b2b9bb92d2224c5ea96b074f155d5
2021-03-29 12:39:12 +00:00
Joanne Chung
e1b23cd423 Add translation APIs for virtual views.
Bug: 178046780
Test: manual
Test: atest CtsTranslationTestCases
CTS-Coverage-Bug: 177960696

Change-Id: I99caed0d42b3a164a25c2707eba7057c42c19140
2021-03-29 20:36:40 +08:00
Peter Li
d3b9b7d0f5 Merge "Add callback to report HotwordDetectionService status" into sc-dev am: 378b540fa1
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13974087

Change-Id: Idc441a5d54c25e58803bc4d8e609c57514a5416f
2021-03-29 12:04:21 +00:00
lpeter
6f2a263810 Add callback to report HotwordDetectionService status
Bug: 182788844
Test: Test: atest CtsVoiceInteractionTestCases
Test: atest CtsVoiceInteractionTestCases --instant
Change-Id: I12f0a265fc4fce0bbfe0983f39b4dcd947e3cf64
2021-03-29 17:41:24 +08:00
George Chang
ba34121efc Make NFC_UID TestApi
Bug: 182979907
Test: atest android.permission.cts.NfcPermissionTest
Test: atest android.net.wifi.cts.WifiManagerTest
Change-Id: Id007984bcd03b5892bd774673c8c0ab836032fc9
2021-03-28 22:28:06 +08:00
George Chang
5052189dd8 Update SetAlwaysOn to SetControllerAlwaysOn
Bug: 182979907
Test: atest NfcNciInstrumentationTests
Change-Id: I6b794259ec597e5d7f86e94705017b8fe169a102
2021-03-28 22:20:52 +08:00
George Chang
abd045e95c Add new permission to set NFC always on states
Bug: 182979907
Test: atest NfcNciInstrumentationTests
Change-Id: I9a82c37f0b6716e68dc4c2d7e0f171d892f09112
2021-03-28 22:06:34 +08:00
Kriti Dang
e713ee6c60 Merge changes from topic "cherrypick-Display settings HDR formats-mumvl547ah" into sc-dev
* changes:
  Handling Number Format Exception in DiscreteValueIntegerListValidator
  Hdr format settings [Backend]
2021-03-28 12:25:32 +00:00
Ahaan Ugale
590a6b8938 Merge "Implement dispatchRequestTranslation for getting translation information." into sc-dev am: 80348b5baf
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13971785

Change-Id: Ic4191aa0084aae6c6dede0d38c0f5ecb9ed752ea
2021-03-26 18:38:35 +00:00
Ahaan Ugale
80348b5baf Merge "Implement dispatchRequestTranslation for getting translation information." into sc-dev 2021-03-26 18:28:17 +00:00
Sergey Volnov
06cff513a1 Merge "Introduce the concept of software and external hotword." into sc-dev am: 86d7e7d2e0
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13727287

Change-Id: I45cd1c6be4d6cc14eb52681fdf4f8367d52af031
2021-03-26 13:08:11 +00:00
Sudheer Shanka
e0237fa50b Add API to allow apps with location permission to access data blobs.
This is a new access mode that apps can use while committing data
blobs to specify that only apps with location permission can the
data blobs.

Bug: 158705914
CTS-Coverage-Bug: 158705914
Test: atest --test-mapping apex/blobstore
Change-Id: If69a2ea317719315f782e71a993cec361fef027f
2021-03-26 08:00:10 +00:00
Sergey Volnov
baceb11e71 Introduce the concept of software and external hotword.
Follow-up: implement circular buffer and integrate with the flows.

Bug: 182788844
Bug: 168305377
CTS-Coverage-Bug: 183425641
Test: atest CtsVoiceInteractionTestCases
Change-Id: I654a06afb27bb961bfb547a6636e08eb72a031fc
2021-03-26 00:10:44 -07:00
Joanne Chung
f51da99ac1 Implement dispatchRequestTranslation for getting translation information.
This change doesn't contain the virtual view part and the API, it
will be done in the next change.

Bug: 178046780
Test: manual
Test: atest CtsTranslationTestCases
CTS-Coverage-Bug: 177960696

Change-Id: Idba66a882a90168ecdd93423c0d5d054ab040dad
2021-03-25 22:31:54 -07:00
Jiabin Huang
88375244d8 Merge "Add short audio descriptor and encapsulation type in AudioProfile." into sc-dev am: ae6711b2a7
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13784568

Change-Id: I4859329c63608a6679727d9111e2212d5154eca6
2021-03-26 04:36:12 +00:00
Jiabin Huang
ae6711b2a7 Merge "Add short audio descriptor and encapsulation type in AudioProfile." into sc-dev 2021-03-26 04:08:33 +00:00
Chiachang Wang
8c0f6af40c Merge "Expose BIP and VSIM relavent definitions" into sc-dev am: e87a4dacd7
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13989590

Change-Id: I41f60fb738a288b2f6fb755b6074c8bddaf6b0f4
2021-03-26 02:51:40 +00:00
Chiachang Wang
e87a4dacd7 Merge "Expose BIP and VSIM relavent definitions" into sc-dev 2021-03-26 02:38:34 +00:00
Alex Buynytskyy
e0a7ab9b69 Merge "Making the rest of Streaming installation API public." into sc-dev am: f8d0c5584e
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13991021

Change-Id: I44c8f524796805e4572fafa56a3d178b8a39c83c
2021-03-26 00:21:37 +00:00
Chris Tate
fbdfb043a0 Merge "Make FGS notification deferral control tri-state" into sc-dev am: d8022c3d5b
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/13634653

Change-Id: I02cb24b41a076c42e5905b6a14530475b63a840f
2021-03-26 00:19:36 +00:00