Fix SecurityException in Autofill

Clear binder identity in AutofillManagerService calls.

Autofill server assume the identity of the provider when making calls to DeviceState. Since some providers could be instantiated before Autofill Manager finishes addClient(), this could trigger a SecurityException. Fixing by clearing the binder identity before calls to DeviceState - this will make it so all calls to DeviceState has system server identity.

Fixes: 285042748
Bug: 278209634

Test: CtsAutoFillServiceTestCases
Change-Id: I7cc11e0880a35266c8b1d8da36ad1e89a2afd50d
1 file changed