Commit Graph

1857 Commits

Author SHA1 Message Date
Zimuzo
cd6b11575f Add supported PackageInfo to ExplicitHealthCheckService API
With the change in I4f13638598037acaeb30d61c8d5178f45882fcba
to separate the PackageWatchdog package expiry deadline from the explicit
health check deadline. It would be cleaner for ExtServices to supply
this deadline per-package. We now do that as a field in
PackageInfo.

Bug: 120598832
Test: Builds

Change-Id: I29e2d619a5296716c29893ab3aa2f35f69bfb4d7
2019-04-05 16:05:45 +00:00
Felipe Leme
67e9426eb6 Merge "Implemented ContentCaptureConditions APIs." 2019-03-29 06:20:49 +00:00
Chen Xu
9c4a902bef Merge "scrub pii (imsi) from carrierIdentifier logging" 2019-03-29 05:37:54 +00:00
Felipe Leme
a8d33c24f8 Implemented ContentCaptureConditions APIs.
Test: atest ContentCaptureConditionTest \
       CustomViewActivityTest#testContentCaptureConditions \
       CustomViewActivityTest#testContentCaptureConditions_otherPackage
Test: atest CtsContentCaptureServiceTestCases # sanity check (minus usual flakiness)

Fixes: 129266058

Change-Id: I199c3ae99fa6b407da64562a71d8d7581ebf80e6
2019-03-28 18:48:31 -07:00
chen xu
61b2c86719 scrub pii (imsi) from carrierIdentifier logging
Bug: 129229239
Test: Manual
Change-Id: I642d60e4ba1001bfd481aada87fa08dbd19098be
2019-03-28 16:28:45 -07:00
Felipe Leme
080542019a Refactored ContentCapture sessions to use an int id.
This is an internal change that will save memory:
- ids themselves are smaller (one int vs ~20 chars string)
- can be mapped with SparseArrays
- parcel objects will be smaller

Test: atest CtsContentCaptureServiceTestCases \
  FrameworksCoreTests:android.view.contentcapture.ContentCaptureEventTest \
  FrameworksCoreTests:android.view.contentcapture.ContentCaptureSessionTest

Fixes: 121197119

Change-Id: I4b4367bd7238400ade385c2bcc4b0595ed0b1c7b
2019-03-28 13:50:06 -07:00
TreeHugger Robot
b17c4244af Merge "Fix WallpaperEngine object leaked during stress test." 2019-03-28 01:13:08 +00:00
Fabian Kozynski
415fce8dbc Merge "Clarified docs for ACTION_QS_TILE_PREFERENCES" 2019-03-27 19:20:20 +00:00
wilsonshih
b72ff9c60f Fix WallpaperEngine object leaked during stress test.
The wallpaper engine object may not have released due to someone continuously
change wallpaper with the same component, such as image wallpaper.
In this case, server side may receive attached engine to a connection, however,
it could already detached.

Example sequence:
bind wallpaper (A) connection (C1)
  detachWallpaperLocked(lastwallpaper)
  lastwallpaper = A + C1
bind wallpaper (A) connection (C2)
  detachWallpaperLocked(lastwallpaper = A + C1)
  last = A + C2
  attachEngine to C1
Then the connection C1 will never be released because it was be detached.

We can fix this by notify that WallpaperService is detached.
When it was detached, it shall destroy its engine if there is, and doesn't attach
back to WallpaperManagerService anymore.

Bug: 128974839
Test: run atest WallpaperManagerTest, then dump
adb shell dumpsys activity service com.android.systemui/com.android.systemui.ImageWallpaper
to make sure there is only one WallpaperEngine object.

Change-Id: Ifea201fe8860af11376717d344fee77182b38e54
2019-03-27 10:43:21 +08:00
Felipe Leme
df1aa85444 Merge "Defined new APIs to whitelist content capture for specific URLs." 2019-03-26 16:01:10 +00:00
Chen Xu
2f662e6477 Merge "notifyCarrierNetworkChange with subId" 2019-03-26 04:20:52 +00:00
chen xu
5b98d401a0 notifyCarrierNetworkChange with subId
notifyCarrierNetworkChange should only be allowed
for carrier service which has the carrier priviledge.

to find carrierService is notifying which subId,
check which subId the caller has carrier privileges
under at the time of the call and use that to restrict.

Bug: 128989180
Test: Build
Change-Id: I061dd5773f8db87c702c5e60413b198330bee854
2019-03-25 16:20:24 -07:00
Felipe Leme
790be0463b Defined new APIs to whitelist content capture for specific URLs.
Test: m update-api # not implemented yet
Fixes: 129267994

Change-Id: Ibd83368ce79e8dfe901164f921304091c41428fc
2019-03-25 15:35:57 -07:00
Zimuzo Ezeozue
245e9c0af9 Merge "Add ExplicitHealthCheckService API" 2019-03-25 19:46:10 +00:00
Fabian Kozynski
98febfd3ec Clarified docs for ACTION_QS_TILE_PREFERENCES
SystemUI is the process launching the intent, so it can launch
activities that are not exported. This documents how to protect
activities from being launched by other uid.

Test: no test
Fixes: 80284344

Change-Id: Iaad0107a071ece50cb14571859e7b01e500d6051
2019-03-25 13:36:24 -04:00
Lucas Dupin
49f040258d Merge "Simplify the AttentionService API" 2019-03-25 16:36:27 +00:00
Zimuzo
a3bb67d1ed Add ExplicitHealthCheckService API
The ExplicitHealthCheckService implementation will live in ExtServices
so it can be updated outside of a platform update. It will contain
logic to assist the PackageWatchdog with observing packages, e.g
ensuring that the device can successfully connect to WiFi after a
mainline update.

Test: Builds
Bug: 120598832
Change-Id: If658567ca41bb0328e279735897fc50ab76abc11
2019-03-25 16:25:30 +00:00
TreeHugger Robot
c4ef64285d Merge "Make adjustNotification working no matter the notification is just enqueued or already posted" 2019-03-25 16:13:10 +00:00
Tony Mak
dcef8e393b Make adjustNotification working no matter the notification is just
enqueued or already posted

BUG: 129042820

Test: atest frameworks/base/packages/ExtServices/tests/src/android/ext/services/notification/

Change-Id: I5df96b0e971e9b037b3efa9204c3fad3bfcf1081
2019-03-25 13:47:29 +00:00
TreeHugger Robot
8b6cecb841 Merge "Api feedback for status bar icon api" 2019-03-23 06:00:18 +00:00
TreeHugger Robot
4f3f18dec3 Merge "Fixed Content Capture workflow when service package is updated." 2019-03-22 23:00:01 +00:00
Felipe Leme
e6f86a34d9 Merge "Renamed ContentCaptureService.disableContentCaptureServices to disableSelf()" 2019-03-22 21:53:34 +00:00
Julia Reynolds
6d2b7e6a85 Api feedback for status bar icon api
Test: make
Fixes: 125800873
Change-Id: Iafcf378c36d8a17ba7f29504541a003ea5195872
2019-03-22 15:19:44 -04:00
TreeHugger Robot
25ad27eb6c Merge "New method ContentCaptureManager.getServiceSettingsComponentName()" 2019-03-22 18:35:58 +00:00
Felipe Leme
bedcd617c1 Renamed ContentCaptureService.disableContentCaptureServices to disableSelf()
Test: atest CtsContentCaptureServiceTestCases
Test: m update-api

Fixes: 128426640

Change-Id: I54c68ae64969f2e15c0c3a53cb6dbdb59b7931ab
2019-03-22 10:39:38 -07:00
TreeHugger Robot
6d623e495b Merge "Updating onLocation related APIs to onLaunchLocation as per API review" 2019-03-22 15:24:29 +00:00
Alex Salo
eeba023303 Simplify the AttentionService API
Remove the request code as the callback identifies itself

Bug: 128134941
Test: manully verified the lifecycle
Change-Id: I1f92a6bcd48f9780072ed444cc73ab8a4d2aad77
2019-03-21 22:12:44 -07:00
Alex Salo
8871b31ac4 Merge "Add disableSelf() and more failure codes" 2019-03-22 03:18:12 +00:00
Brad Stenning
75eaf771f8 Merge "Provide a hook for forcing all system bars to be displayed at all times" 2019-03-22 02:18:58 +00:00
Felipe Leme
2f28843249 Fixed Content Capture workflow when service package is updated.
The workflow already handles the case where the service dies and the framework re-establishes
the binder connection, but that didn't work when it died because the package was being updated.

This CL fixes this scenario by gracefully pausing the existing sessions before the package is
updated, then resuming them afterwards.

Test: manual verification
Test: atest CtsContentCaptureServiceTestCases # sanity check minus flakiness

Bug: 126266412
Fixes: 129072171

Change-Id: Ibc6b723c7bc08b4f920436f365d6006bc8fac7b6
2019-03-21 18:15:05 -07:00
Alex Salo
b4a617767b Add disableSelf() and more failure codes
disableSelf() allows the implementer of the service to notify the system
about the intent to disable self, e.g. in case it does not have sufficient
permissions to perform the task.

New failure codes are introduced to communicate the absense of the
camera permission and a cancellation event.

Bug: 128921381, 111939367
Test: manually
Change-Id: Id9a2a8e8d51d422e966a5858c85f8a73ca37ded7
2019-03-21 14:43:51 -07:00
Andrei-Valentin Onea
bb5089fbd9 Merge "Add @UnsupportedAppUsage annotations" 2019-03-21 19:11:51 +00:00
Sunny Goyal
c2baa4d724 Updating onLocation related APIs to onLaunchLocation as per API review
Bug: 126179809
Bug: 126180256
Test: everything compiles

Change-Id: I583f96bd5f5b5042131488a9ad5950cbad298071
2019-03-21 18:03:48 +00:00
Andrei Onea
e30e3928f9 Add @UnsupportedAppUsage annotations
For packages:
  android.companion
  android.filterfw
  android.hardware.camera2.utils
  android.inputmethodservice
  android.net.nsd
  android.os
  android.preference
  android.security.keymaster
  android.service.dreams
  android.telecom
  android.telephony.ims.compat.feature
  android.telephony
  android.util
  android.view.accessibility
  android.media.effect

This is an automatically generated CL. See go/UnsupportedAppUsage
for more details.

Exempted-From-Owner-Approval: Mechanical changes to the codebase
which have been approved by Android API council and announced on
android-eng@

Bug: 110868826
Test: m
Change-Id: I9c2f8347952f3cc65759472b0e1a2717b285e44e
2019-03-21 14:04:57 +00:00
Julia Reynolds
a5516ba016 Merge "Add the ability to turn off NAS capabilities individually" 2019-03-21 13:09:00 +00:00
Jiuyu Sun
a596e74485 Merge "Fix the assumption in GetEuiccProfileInfoListResult." 2019-03-21 03:06:15 +00:00
Brad Stenning
e057369877 Provide a hook for forcing all system bars to be displayed at all times
Bug: 121257946

Test: manual
Change-Id: Ibbf41a03b0229b62366a42543e542af954a0ea8b
2019-03-20 16:27:47 -07:00
Holly Jiuyu Sun
5265dc5fc3 Fix the assumption in GetEuiccProfileInfoListResult.
Under error cases, LPA can return a GetEuiccProfileInfoListResult
with either null profiles or empty profiles.

Bug: 127376266
Test: build
Change-Id: Id29c8f00183660d2195c58c96eb4154454623eb6
2019-03-20 15:41:22 -07:00
Felipe Leme
f8b8778468 New method ContentCaptureManager.getServiceSettingsComponentName()
Test: manual verification

Test: atest CtsContentCaptureServiceTestCases # sanity check

Bug: 119264902

Change-Id: I3f387386652dad7b187ae04b29f16512ff444ca1
2019-03-20 14:58:53 -07:00
TreeHugger Robot
f48b706f27 Merge "Fixed logic on update()." 2019-03-20 19:08:31 +00:00
Felipe Leme
1047cba3e8 Merge "Added manifest metadata to define the content capture settings activity." 2019-03-20 18:04:06 +00:00
Felipe Leme
a5d5e2db8f Added manifest metadata to define the content capture settings activity.
Test: m update-api
Test: mmm frameworks/base/:doc-comment-check-docs
Test: adb shell dumpsys content_capture
Test: CtsContentCaptureServiceTestCases

Bug: 119264902

Change-Id: I656c50d9a45f68312898c8857572d5fe3f55c193
2019-03-20 08:36:24 -07:00
Felipe Leme
34b24bd409 Merge "New ContentCapture constant: ActivityEvent.TYPE_ACTIVITY_DESTROYED" 2019-03-20 14:33:21 +00:00
Julia Reynolds
ad6dd3575c Add the ability to turn off NAS capabilities individually
Test: atest
Bug: 127825514
Change-Id: Ic59e4be40ec71c70703eacf004ef32333e3356c9
2019-03-20 09:09:56 -04:00
Julia Reynolds
8180db886c Merge "Add notification opPkg to logs" 2019-03-20 12:36:37 +00:00
Felipe Leme
29eb0bc25b New ContentCapture constant: ActivityEvent.TYPE_ACTIVITY_DESTROYED
Test: m update-api
Test: atest ChildlessActivityTest#testLaunchAnotherActivity_onTopOfIt
Test: atest CtsContentCaptureServiceTestCases # sanity check
Fixes: 128904560

Change-Id: I32169c6a74d834858d8e22ec6adeb478b676bece
2019-03-19 13:14:20 -07:00
Adam He
36c8a0d088 Fixed logic on update().
Bug: 127062800
Test: atest android.autofillservice.cts.augmented.AugmentedLoginActivityTest
Change-Id: I99c7d1884b774cb1f5c77692b8c6fd2df083849d
2019-03-19 10:56:45 -07:00
Julia Reynolds
9846076a9b Add notification opPkg to logs
Test: bugreport
Fixes: 128636744
Change-Id: Ib977e65f690e49d523abeb53161b4455a5502381
2019-03-19 09:25:08 -04:00
Adam He
234030a0c5 Don't show fill ui if fillrequest times out.
Fixes: 127062800
Test: atest
android.autofillservice.cts.augmented.AugmentedLoginActivityTest

Change-Id: Iad067c79746a829334f64b2b340021876e341dd4
2019-03-18 11:51:34 -07:00
Adam He
52577fcc24 Implemented CancellationSignal for augmented autofill requests.
Fixes: 122728762
Bug: 127062800
Test: atest android.autofillservice.cts.augmented.AugmentedLoginActivityTest#testCancellationSignalCalledAfterTimeout
Change-Id: Id6f0d6f5ac4e47b07e32c255fdbb02af878b6921
2019-03-18 11:42:33 -07:00