Removed deprecated BIND_AUTOFILL permission.

Test: cts-tradefed run commandAndExit cts-dev -m CtsAutoFillServiceTestCases

Fixes: 37563972

Change-Id: If751eb94336756da205908deae9e3b9b1c67c4e8
This commit is contained in:
Felipe Leme
2017-08-31 14:26:06 -07:00
parent 44bc284d96
commit fff9f7ed61
2 changed files with 4 additions and 9 deletions

View File

@@ -29,11 +29,12 @@ import android.os.RemoteException;
import android.util.AttributeSet;
import android.util.Log;
import android.util.Xml;
import org.xmlpull.v1.XmlPullParser;
import org.xmlpull.v1.XmlPullParserException;
import com.android.internal.R;
import org.xmlpull.v1.XmlPullParser;
import org.xmlpull.v1.XmlPullParserException;
import java.io.IOException;
/**
@@ -89,9 +90,7 @@ public final class AutofillServiceInfo {
@Nullable
private static TypedArray getMetaDataArray(PackageManager pm, ServiceInfo si) {
// Check for permissions.
// TODO(b/37563972): remove support to BIND_AUTOFILL once clients use BIND_AUTOFILL_SERVICE
if (!Manifest.permission.BIND_AUTOFILL_SERVICE.equals(si.permission)
&& !Manifest.permission.BIND_AUTOFILL.equals(si.permission)) {
if (!Manifest.permission.BIND_AUTOFILL_SERVICE.equals(si.permission)) {
Log.w(TAG, "AutofillService from '" + si.packageName + "' does not require permission "
+ Manifest.permission.BIND_AUTOFILL_SERVICE);
throw new SecurityException("Service does not require permission "

View File

@@ -2635,10 +2635,6 @@
<permission android:name="android.permission.BIND_AUTOFILL_SERVICE"
android:protectionLevel="signature" />
<!-- @hide TODO(b/37563972): remove once clients use BIND_AUTOFILL_SERVICE -->
<permission android:name="android.permission.BIND_AUTOFILL"
android:protectionLevel="signature" />
<!-- Must be required by hotword enrollment application,
to ensure that only the system can interact with it.
@hide <p>Not for use by third-party applications.</p> -->