Felipe Leme
60b765b707
Fixed synchronization when calling cancellation signal.
...
Test: none for this particular issue, but CtsAutoFillServiceTestCases pass
Bug: 64759228
Change-Id: Ifaf0082de55ddb5446af134e190c89f7e10bf1fe
2017-08-17 09:12:41 -07:00
TreeHugger Robot
fac2141f4e
Merge "Fixed NPE when cancellation signal is null." into oc-mr1-dev
2017-08-17 16:02:54 +00:00
TreeHugger Robot
10d176009d
Merge "Revert "Dismiss Autofill Save UI when a new Activity is launched."" into oc-mr1-dev
2017-08-17 03:07:02 +00:00
Felipe Leme
ec63b7d0e1
Fixed NPE when cancellation signal is null.
...
Test: none for this particular issue, but CtsAutoFillServiceTestCases pass
Fixes: 64759228
Change-Id: I34170440ac388ec6ba7ed5632dc38543a84d0327
2017-08-16 18:06:17 -07:00
Felipe Leme
cf1ff6ca3d
Revert "Dismiss Autofill Save UI when a new Activity is launched."
...
This reverts commit 05ea98a3f95a2f5179c01a5bfd4901835a0c1bd8.
Bug: 64693551
Change-Id: I8e7a7b2c5f575cee28f977ae7f3c10752a15d49c
2017-08-16 23:34:06 +00:00
TreeHugger Robot
7876b630be
Merge changes I768830f5,I665bde3a into oc-mr1-dev
...
* changes:
Removed redundant [X] icon used to close Autofill Save UI.
Re-added outer layout on Autofill Save UI that was accidentally removed.
2017-08-16 22:11:12 +00:00
Felipe Leme
05e435cfd1
Removed redundant [X] icon used to close Autofill Save UI.
...
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases
Test: manual verification
Fixes: 64694706
Change-Id: I768830f56db1814aecb82b94cebb9100dd47dd50
2017-08-16 10:00:28 -07:00
TreeHugger Robot
6ba128762f
Merge "Calls CancellationSignal when onFillRequest() times out." into oc-mr1-dev
2017-08-15 22:23:57 +00:00
Felipe Leme
05ea98a3f9
Dismiss Autofill Save UI when a new Activity is launched.
...
Test: manual verification using Settings
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases -tandroid.autofillservice.cts.SimpleSaveActivityTest#testDismissSave_byLaunchingNewActivity
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases -tandroid.autofillservice.cts.LoginActivityTest#testSaveGoesAwayWhenLaunchingNewActivity
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases
Fixes: 64693551
Change-Id: I323031c7285a4b49f9f0ca06618425a0ab7833da
2017-08-14 17:56:30 -07:00
Felipe Leme
052562c40f
Calls CancellationSignal when onFillRequest() times out.
...
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases -t android.autofillservice.cts.LoginActivityTest#testCancellationSignalCalledAfterTimeout
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases
Fixes: 64034169
Change-Id: I501653405e8244543a4c27f736bacfa23d22e6f7
2017-08-10 11:17:27 -07:00
Felipe Leme
cb96f39155
Uses ParceledListSlice to allow larger number of datasets.
...
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases -t android.autofillservice.cts.LoginActivityTest#testAutofillLargeNumberOfDatasets
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases
Fixes: 63669555
Change-Id: If0847da3bafa1bfd80ee8925e17aace82010aec9
2017-07-27 09:44:11 -07:00
Felipe Leme
e802d18f49
Merge "Don't show Save UI when values filled by user belong to a dataset." into oc-mr1-dev
2017-07-27 15:11:22 +00:00
TreeHugger Robot
2790352cd4
Merge "Added sliding motion / animation to Autofill Save UI." into oc-mr1-dev
2017-07-27 04:07:03 +00:00
TreeHugger Robot
db3c4ee787
Merge "Checks if mResponses is null before using it." into oc-mr1-dev
2017-07-27 01:00:58 +00:00
Felipe Leme
7641443f4b
Added sliding motion / animation to Autofill Save UI.
...
Test: manual observation
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases
Fixes: 63680769
Change-Id: I62122733bb0e4b09de3347b091e27e60fbc51333
2017-07-26 17:09:05 -07:00
Felipe Leme
d0b18d665f
Don't show Save UI when values filled by user belong to a dataset.
...
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases
Fixes: 63068654
Change-Id: Ia9c42d57b0e7c316bfd3c0ee29816db18ac478c1
2017-07-26 15:59:38 -07:00
Felipe Leme
afdfe7665c
Checks if mResponses is null before using it.
...
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases -t android.autofillservice.cts.LoginActivityTest#testFillResponseAuthWhenAppCallsCancel
Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases
Fixes: 63806922
Bug: 63985284
Change-Id: I8d7cfa34ba88a1d351967e17717b387c805dd00d
2017-07-24 12:38:47 -07:00
Felipe Leme
325a0b04b5
DO NOT MERGE - Wraps custom save subtitle on ScrollView.
...
(cherrypick from Ided12e8dbce2c3d80c7db8f167109ed9108c904b)
Test: CtsAutoFillServiceTestCases pass
Test: manual verification
Change-Id: Ida44970d68755423cb080f4c562ddcdec90efa6f
Fixes: 62534917
2017-07-24 12:33:24 -07:00
Felipe Leme
7f9ca12b9a
Support list type on CustomDescription.
...
Test: CtsAutoFillServiceTestCases pass
Test: CheckoutActivityTest.testCustomizedSaveUi
Bug: 62534917
Change-Id: I43dbd92a0db9d76b59328f74519147c952c6ab37
2017-07-18 17:40:45 -07:00
Felipe Leme
7fc29dd931
Changed SaveInfo so it supports just optional ids.
...
Test: existing CtsAutoFillServiceTestCases pass
Test: new tests on LoginActivityTest pass
Test: new SaveInfoTest pass
Fixes: 38044993
Change-Id: Iefcf9610b27361585444157616325e9e9a89158f
2017-07-18 17:40:44 -07:00
Felipe Leme
b078212a1e
Don't log content of Autofill filter, since it could contain PII.
...
Test: manual verification
Fixes: 63680114
Change-Id: I92dcb88df6b577ee2f7a4065e8f9b14ba01ba3fb
2017-07-14 10:35:41 -07:00
TreeHugger Robot
d16aeddbd1
Merge "Make CustomDescription safe against crashes"
2017-07-12 22:29:10 +00:00
Philip P. Moltmann
3858aa6736
Make CustomDescription safe against crashes
...
... And allow users of the public APIs use Transformations.
Test: bit CtsAutoFillServiceTestCases:.CustomDescriptionTest
Bug: 62534917
Change-Id: I6b7b7d5e343e78f2f0381303451e08bb16c5c3e6
2017-07-12 09:38:08 -07:00
Philip P. Moltmann
0e3e6f8274
Handle failures in validators
...
Test: cts-tradefed run cts-dev -m CtsAutoFillServiceTestCases
--test=android.autofillservice.cts.ValidatorTest
Bug: 62534917
Change-Id: I3aad06cd2e8b6caf7238e420727aca0cb3703bc5
2017-07-12 08:05:01 -07:00
Svet Ganov
6d1d822894
Merge "Avoid a race in autofill manager service." into oc-dr1-dev am: d622be1754
...
am: 55fbe549d5
Change-Id: If651c4d88017c439432dd93b21944fc43a36dfe3
2017-07-12 02:23:43 +00:00
Svet Ganov
dfa1a47f22
Avoid a race in autofill manager service.
...
Test: manual
bug:63205660
Change-Id: Ie895666da1584e735f7aa7ee9208ea97becb921b
2017-07-05 19:26:37 +00:00
TreeHugger Robot
ee39d54a8d
Merge "Initial implementation of the new Save APIs."
2017-06-29 02:43:36 +00:00
Felipe Leme
979013d027
Initial implementation of the new Save APIs.
...
Test: manual verification with sample app (CTS tests coming later)
Bug: 62534917
Change-Id: I085a9c933bb5e8316d673976e059e13abd7098e5
2017-06-28 15:13:21 -07:00
Philip P. Moltmann
e683f19c49
Allow ALL_USERS in setUserRestrictionForUser
...
This will be used e.g. by the permission granting UI.
Fixes: 35612487
Test: 1. Installed facebook messanger and enabled chat-heads in private
profile
2. Opened work-profile camera which asks for location
permission
3. Chat head disappered during permission check
4. Chat head re-appeared after permission check
Change-Id: Ie9a5e5379c20972f34945c9cb062cd8e3df483d4
2017-06-28 13:06:45 -07:00
TreeHugger Robot
705f300413
Merge "Flush out existing sessions when the Autofill service is changed."
2017-06-22 17:44:45 +00:00
Felipe Leme
2f0d132471
Autofill fixes for secondary users:
...
- Display the SaveUI on all users.
- Dismiss the UI when switching users.
- Fix security check on disableOwnedAutofillServicesLocked()
Test: manual verification
Change-Id: I4e9167314f1feeda618db6c57735cc31d84486c1
Fixes: 62828906
2017-06-21 17:50:51 -07:00
Felipe Leme
6a6cd3fa38
Flush out existing sessions when the Autofill service is changed.
...
Test: LoginActivityTest.testPopupGoesAwayWhenServiceIsChanged
Fixes: 62836529
Change-Id: I9e6fb368f8c2b723668fbcb5ccb57d519ee149f8
2017-06-21 15:21:51 -07:00
Felipe Leme
d013bcea97
Don't add FillEventHistory events to the wrong session.
...
The AutofillSession.getFillEventHistory() method returns only the event history
for the last onFillRequest(). In the scenario where the user switches
activities and the server has multiple sessions open, only the events for the
last session should be recorded.
Test: existing CtsAutoFillServiceTestCases pass
Test: LoginActivityTest.checkFillSelectionFromPreviousSessionIsDiscarded
Fixes: 62802026
Change-Id: I447ed77c2167095867b35d616b5cf2ae43aa28db
2017-06-20 17:31:20 -07:00
Felipe Leme
2e30c6f371
Fixed how FillEventHistory is reset and clarified javadoc.
...
Test: existing CtsAutoFillServiceTestCases pass
Test: checkFillSelectionIsResetAfterReturningNull()
Test: checkFillSelectionIsResetAfterReturningError()
Test: checkFillSelectionIsResetAfterTimeout()
Bug: 62802026
Change-Id: I389d95fc13c08f1056960e5f67e131c8dc306401
2017-06-20 14:54:05 -07:00
Felipe Leme
94b56207a4
Use an optimized findViewNodeByAutofillId(id) to get just one node.
...
Session was using findViewNodesByAutofillIds(ids) before, which not only was
not optimal, but error prone (for example, it could return a non-empty array
with an empty value).
Test: CtsAutoFillServiceTestCases pass
Fixes: 62532979
Change-Id: If984f1263cc3f2aac1d1e098687fe02d73c55211
2017-06-16 11:51:49 -07:00
Svetoslav Ganov
0541862ec5
Merge "Protect autofill UI against redressing" into oc-dev
2017-06-09 20:53:40 +00:00
Svetoslav Ganov
2ee821b675
Protect autofill UI against redressing
...
Test: LoginActivityTest#testAutoFillOneDatasetAndSaveHidingOverlays
bug:62357517
Change-Id: Idcac67e1013178ba6c0d83994d49f8b485b2d334
2017-06-08 17:22:49 -07:00
Felipe Leme
5f97880714
Closes Autofill UIs when back button is pressed.
...
Test: existing CtsAutoFillServiceTestCases pass
Test: LoginActivityTest#testSaveGoesAwayWhenTappingBackButton pass
Fixes: 62272098
Change-Id: Id34767ca32836f040e04790f0f2935ae49d88d71
2017-06-08 13:10:32 -07:00
Felipe Leme
72f2d98c5a
Merge "Fixed autofill filter comparison." into oc-dev
2017-06-07 00:30:53 +00:00
Felipe Leme
be4420cf13
Merge "Improved debug to diagnose Save issues." into oc-dev
2017-06-07 00:26:12 +00:00
Felipe Leme
2e723982d5
Merge "Use initial value on save when value didn't change." into oc-dev
2017-06-07 00:25:11 +00:00
Felipe Leme
b372c74e88
Fixed autofill filter comparison.
...
Test: existing CtsAutoFillServiceTestCases pass
Test: filterTextDifferentPrefixes() pass
Fixes: 62377334
Change-Id: I9edaf500adad7e5775994a838410c3f8f6af2b1a
2017-06-06 13:52:22 -07:00
Felipe Leme
e8f6808079
Use initial value on save when value didn't change.
...
Otherwise, it will fail to call onSaveRequest() in scenarios where the service
required a field that was pre-populated for the app. For example, when the
service requires both a username and password, the app pre-populates the
username, and the user fills the password.
Test: new LoginActivityTest.testSaveOnlyTwoRequiredFieldsOnePrefilled() pass
Test: existing CtsAutoFillServiceTestCases pass
Bug: 62270740
Change-Id: Idbb11a8c2dab6741c18549c55dfdb71b483c2447
2017-06-06 13:49:42 -07:00
Felipe Leme
a844927cb6
Improved debug to diagnose Save issues.
...
Test: manual verification
Bug: 62272098
Change-Id: Id7a6765fbe4228fcabb6cc0df37c5fde102d7077
2017-06-06 08:58:46 -07:00
Felipe Leme
876377d0b2
Catch WindowManager exceptions so they don't crash the system.
...
WindowManager throws an IllegalStateException when adding a view twice; this
should never happen (since show() and hide() are always called in the UIThread),
but when it does, it should not crash the system.
Test: existing CtsAutoFillServiceTestCases pass
Fixes: 62262781
Change-Id: Idfd246ff173f4abb606865b7ba8cc367eb6acaad
2017-06-02 14:48:43 -07:00
TreeHugger Robot
d8d9758363
Merge "Don't automatically autofill when manual request returned just 1 dataset." into oc-dev
2017-05-31 20:43:20 +00:00
Felipe Leme
9b36dfb2b1
Don't call remoteFillService.destroy() until session is removed.
...
Test: CtsAutoFillServiceTestCases pass
Fixes: 62200831
Bug: 62106708
Change-Id: I4e54e28a347e800c0b8353938399c860f213edfa
2017-05-30 19:55:59 -07:00
Felipe Leme
8697a31d3c
Don't automatically autofill when manual request returned just 1 dataset.
...
When the user manually requested autofill and the service returned just 1
dataset, the app was automatically filled with it.
The motivation here was that since the user explicitly asked for autofill,
it'd ok - and better for the user - to release the data to the app without
the selecting a dataset.
This assumption was ok initially, but now the API to manually request autofill
is public, so a malicious app could use to get autofill data without user
interation.
Test: CtsAutoFillServiceTestCases pass
Fixes: 62164695
Change-Id: I47c3d8c557533526572aa67a4240c0a57f54268d
2017-05-30 14:34:27 -07:00
Felipe Leme
350b2dca6c
Disable autofill while user setup is not completed.
...
Test: manual verification with experimental app
Test: manual verification with Autofill with Google on flashed deviced
Test: existing CtsAutoFillServiceTestCases pass
Test: new LoginActivityTest.testSetupComplete pass
Fixes: 62049772
Change-Id: I1e914c44062755f8c88656482338e76aeaafd543
2017-05-26 11:16:04 -07:00
Felipe Leme
c368c0b5ab
Merge "Autofill UI should still show when dataset authentication is cancelled." into oc-dev
2017-05-25 14:32:11 +00:00