Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b6134500 authored by Ludovic Barman's avatar Ludovic Barman
Browse files

Add new signature permission for Population Density Provider

Adds a new signature permission BIND_POPULATION_DENSITY_PROVIDER_SERVICE to the framework. This is to restrict who can call the APIs of the new PopulationDensityProvider introduced in ag/30114155 so it can only be queried by the framework.

Test: None
Flag: android.location.flags.density_based_coarse_locations
Bug: 381283817
Relnote: Add new permission related to the population density provider

Change-Id: Idcf505acfa5c46133074d556b57d8a0efd8da4b6
parent c9b66b17
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -78,6 +78,7 @@ package android {
    field @FlaggedApi("android.app.ondeviceintelligence.flags.enable_on_device_intelligence") public static final String BIND_ON_DEVICE_INTELLIGENCE_SERVICE = "android.permission.BIND_ON_DEVICE_INTELLIGENCE_SERVICE";
    field @FlaggedApi("android.app.ondeviceintelligence.flags.enable_on_device_intelligence") public static final String BIND_ON_DEVICE_SANDBOXED_INFERENCE_SERVICE = "android.permission.BIND_ON_DEVICE_SANDBOXED_INFERENCE_SERVICE";
    field public static final String BIND_PHONE_ACCOUNT_SUGGESTION_SERVICE = "android.permission.BIND_PHONE_ACCOUNT_SUGGESTION_SERVICE";
    field @FlaggedApi("android.location.flags.population_density_provider") public static final String BIND_POPULATION_DENSITY_PROVIDER_SERVICE = "android.permission.BIND_POPULATION_DENSITY_PROVIDER_SERVICE";
    field public static final String BIND_PRINT_RECOMMENDATION_SERVICE = "android.permission.BIND_PRINT_RECOMMENDATION_SERVICE";
    field public static final String BIND_REMOTE_LOCKSCREEN_VALIDATION_SERVICE = "android.permission.BIND_REMOTE_LOCKSCREEN_VALIDATION_SERVICE";
    field public static final String BIND_RESOLVER_RANKER_SERVICE = "android.permission.BIND_RESOLVER_RANKER_SERVICE";
+1 −0
Original line number Diff line number Diff line
@@ -162,6 +162,7 @@ android_app {
        "android.appwidget.flags-aconfig",
        "android.companion.virtualdevice.flags-aconfig",
        "android.content.pm.flags-aconfig",
        "android.location.flags-aconfig",
        "android.media.audio-aconfig",
        "android.provider.flags-aconfig",
        "camera_platform_flags",
+15 −0
Original line number Diff line number Diff line
@@ -2145,6 +2145,21 @@
    <permission android:name="android.permission.CONTROL_AUTOMOTIVE_GNSS"
        android:protectionLevel="signature|privileged" />

    <!-- @SystemApi @hide Allows an application to bind to a
         android.service.PopulationDensityProviderService for the purpose of
         querying population density. This prevents arbitrary clients connecting
         to the service. The system server checks that the provider's intent
         service explicitly sets this permission via the android:permission
         attribute of the service.
         This is only expected to be possessed by the system server outside of
         tests.
         @FlaggedApi(android.location.flags.Flags.FLAG_POPULATION_DENSITY_PROVIDER)
         <p>Protection level: signature
    -->
    <permission android:name="android.permission.BIND_POPULATION_DENSITY_PROVIDER_SERVICE"
        android:featureFlag="android.location.flags.population_density_provider"
        android:protectionLevel="signature" />

    <!-- ======================================= -->
    <!-- Permissions for accessing networks -->
    <!-- ======================================= -->