Skip to content

Commit 63be7a7

Browse files
krutonJean-Baptiste Queru
authored andcommitted
Grant ACCESS_ALL_DOWNLOADS to DefaultContainerService
Be compatible with the old DownloadProvider behavior of being able to operate on content URIs returned from .insert() Bug: 3242328 Change-Id: Ibd2ed553c87ea694d4b09a8265c7131fae588719
1 parent 210e9c4 commit 63be7a7

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

core/java/android/provider/Downloads.java

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -600,7 +600,14 @@ private Impl() {}
600600
"android.permission.ACCESS_DOWNLOAD_MANAGER_ADVANCED";
601601

602602
/**
603-
* The permission to directly access the download manager's cache directory
603+
* The permission to access the all the downloads in the manager.
604+
*/
605+
public static final String PERMISSION_ACCESS_ALL =
606+
"android.permission.ACCESS_ALL_DOWNLOADS";
607+
608+
/**
609+
* The permission to directly access the download manager's cache
610+
* directory
604611
*/
605612
public static final String PERMISSION_CACHE = "android.permission.ACCESS_CACHE_FILESYSTEM";
606613

packages/DefaultContainerService/AndroidManifest.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
22
package="com.android.defcontainer">
33
<uses-permission android:name="android.permission.ACCESS_DOWNLOAD_MANAGER"/>
4+
<uses-permission android:name="android.permission.ACCESS_ALL_DOWNLOADS"/>
45
<uses-permission android:name="android.permission.ASEC_ACCESS"/>
56
<uses-permission android:name="android.permission.ASEC_CREATE"/>
67
<uses-permission android:name="android.permission.ASEC_DESTROY"/>

0 commit comments

Comments
 (0)