Permissions Updates In Android 11

oered.org11 gives users the ability lớn specify more granularpermissions for location, microphone, and camera. Additionally, the systemresets the permissions of unused apps that target oered.org11 orhigher, and apps might need lớn update the permissions that they declare if theyuse the system alert window or read information related lớn phone numbers.

Bạn đang xem: Permissions Updates In Android 11

One-time permissions

Starting in oered.org11, whenever your tiện ích requests a permissionrelated to lớn location, microphone, or camera, the user-facing permissions dialogcontains an option called Only this time. If the user selects this option inthe dialog, your ứng dụng is granted a temporary one-time permission.

Learn more about how the system handles one-timepermissions.

Note: If your ứng dụng already follows best practices when it requests runtimepermissions, you don't need khổng lồ change yourapp khổng lồ tư vấn one-time permissions.

Auto-reset permissions from unused apps

If your phầm mềm targets oered.org11 or higher và isn't used for a fewmonths, the system protects user data by automatically resetting the sensitiveruntime permissions that the user had granted your ứng dụng. This action has the sameeffect as if the user viewed a permission in system settings and changed yourapp's access level khổng lồ Deny. If your app follows best practices forrequesting permissions at runtime, youshouldn't need khổng lồ make any changes to lớn your ứng dụng. That's because, as the userinteracts with features in your phầm mềm, you should verify that the features havethe permissions that they need.

Note: The system resets only runtimepermissions,which are the permissions that display a runtime prompt to lớn the user whenrequested.

Learn more about how the system auto-resets permissions of unusedapps.

Permission dialog visibility

Starting in oered.org11, if the user taps Deny for aspecific permission more than once during your app's lifetime of installation ona device, the user doesn't see the system permissions dialog if your apprequests that permission again. The user's action implies "don't ask again." Onprevious versions, users would see the system permissions dialog each time yourphầm mềm requested a permission, unless the user had previously selected a "don't askagain" checkbox or option. This behavior change in 11 discouragesrepeated requests for permissions that users have chosen khổng lồ deny.

Note: If your tiện ích already follows best practices related topermissions, you don't need lớn change yourphầm mềm lớn support this behavior change.

Xem thêm:

Learn more about how lớn handle permissiondenial in your tiện ích.

System alert window changes

oered.org11 makes several changes to lớn how apps are granted theSYSTEM_ALERT_WINDOWpermission. The changes are intended to lớn protect users by making the permissiongrant more intentional.

Certain apps are automatically granted SYSTEM_ALERT_WINDOW permission upon request

Certain classes of apps are automatically granted the SYSTEM_ALERT_WINDOWpermission upon request:

These apps vì chưng not need lớn sendACTION_MANAGE_OVERLAY_PERMISSIONto lớn get the SYSTEM_ALERT_WINDOW permission; the apps can simply requestSYSTEM_ALERT_WINDOW directly.

MANAGE_OVERLAY_PERMISSION intents always bring user khổng lồ system permissions screen

Beginning with oered.org11,ACTION_MANAGE_OVERLAY_PERMISSIONintents always bring the user to lớn the top-màn chơi Settings screen, where theuser can grant or revoke theSYSTEM_ALERT_WINDOWpermissions for apps. Any package: data in the intent is ignored.

In earlier versions of, the ACTION_MANAGE_OVERLAY_PERMISSION intentcould specify a package, which would bring the user to an app-specific screenfor managing the permission. This functionality isn't supported as ofoered.org11. Instead, the user must first select the ứng dụng they wishto grant or revoke the permission to lớn. This change is intended to protect usersby making the permission grant more intentional.

Phone numbers

oered.org11 changes the phone-related permission that your appuses when reading phone numbers.

If your phầm mềm targets oered.org11 or higher and needs to lớn access thephone number APIs shown in the following menu, you must request theREAD_PHONE_NUMBERSpermission, instead of the READ_PHONE_STATE permission.

If your app declares READ_PHONE_STATE to Call methods other than the ones inthe previous list, you can continue lớn request READ_PHONE_STATE across versions. If you use the READ_PHONE_STATE permission only for themethods in the previous danh mục, however, update your manifest tệp tin as follows:

Change your declaration of READ_PHONE_STATE so that your phầm mềm uses thepermission only on 10 (API cấp độ 29) and lower.Add the READ_PHONE_NUMBERS permission.

The following manifest declaration snippet demonstrates this process:

Additional resources

For more information about the changes to permissions in 11, view thefollowing materials:


Developing with the lathử nghiệm privacy changes 11

Content và code samples on this page are subject khổng lồ the licenses described in the Content License. Java is a registered trademark of Oracle and/or its affiliates.

< "type": "thumb-down", "id": "missingTheInformationINeed", "label":"Missing the information I need" , "type": "thumb-down", "id": "tooComplicatedTooManySteps", "label":"Too complicated / too many steps" , "type": "thumb-down", "id": "outOfDate", "label":"Out of date" , "type": "thumb-down", "id": "samplesCodeIssue", "label":"Samples / code issue" , "type": "thumb-down", "id": "otherDown", "label":"Other" > < "type": "thumb-up", "id": "easyToUnderstand", "label":"Easy to lớn understand" , "type": "thumb-up", "id": "solvedMyProblem", "label":"Solved my problem" , "type": "thumb-up", "id": "otherUp", "label":"Other" >


Discover Devices


Documentation and Downloads


Language English Bahasa Indonesia Español – América Latimãng cầu Português – Brasil 中文 – 简体 日本語 한국어