Extend trampoline to show dialogs.
[android/platform/packages/providers/DownloadProvider.git] / AndroidManifest.xml
1 <?xml version="1.0" encoding="utf-8"?>
2 <manifest xmlns:android="http://schemas.android.com/apk/res/android"
3         package="com.android.providers.downloads"
4         android:sharedUserId="android.media">
5
6     <!-- Allows access to the Download Manager -->
7     <permission android:name="android.permission.ACCESS_DOWNLOAD_MANAGER"
8         android:label="@string/permlab_downloadManager"
9         android:description="@string/permdesc_downloadManager"
10         android:protectionLevel="signatureOrSystem" />
11
12     <!-- Allows advanced access to the Download Manager -->
13     <permission android:name="android.permission.ACCESS_DOWNLOAD_MANAGER_ADVANCED"
14         android:label="@string/permlab_downloadManagerAdvanced"
15         android:description="@string/permdesc_downloadManagerAdvanced"
16         android:protectionLevel="signatureOrSystem" />
17
18     <!-- Allows to send download completed intents -->
19     <permission android:name="android.permission.SEND_DOWNLOAD_COMPLETED_INTENTS"
20         android:label="@string/permlab_downloadCompletedIntent"
21         android:description="@string/permdesc_downloadCompletedIntent"
22         android:protectionLevel="signature" />
23
24     <!-- Allows to download non-purgeable files to the cache partition through the public API -->
25     <permission android:name="android.permission.DOWNLOAD_CACHE_NON_PURGEABLE"
26         android:label="@string/permlab_downloadCacheNonPurgeable"
27         android:description="@string/permdesc_downloadCacheNonPurgeable"
28         android:protectionLevel="signatureOrSystem"/>
29
30     <!-- Allows to queue downloads without a notification shown while the download runs. -->
31     <permission android:name="android.permission.DOWNLOAD_WITHOUT_NOTIFICATION"
32         android:permissionGroup="android.permission-group.NETWORK"
33         android:label="@string/permlab_downloadWithoutNotification"
34         android:description="@string/permdesc_downloadWithoutNotification"
35         android:protectionLevel="normal"/>
36
37     <!-- Allows an app to access all downloads in the system via the /all_downloads/ URIs.  The
38          protection level could be relaxed in the future to support third-party download
39          managers. -->
40     <permission android:name="android.permission.ACCESS_ALL_DOWNLOADS"
41         android:label="@string/permlab_accessAllDownloads"
42         android:description="@string/permdesc_accessAllDownloads"
43         android:protectionLevel="signature"/>
44
45     <uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
46     <uses-permission android:name="android.permission.ACCESS_DOWNLOAD_MANAGER" />
47     <uses-permission android:name="android.permission.ACCESS_CACHE_FILESYSTEM" />
48     <uses-permission android:name="android.permission.SEND_DOWNLOAD_COMPLETED_INTENTS" />
49     <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
50     <uses-permission android:name="android.permission.INTERNET" />
51     <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
52     <uses-permission android:name="android.permission.ACCESS_ALL_DOWNLOADS" />
53     <uses-permission android:name="android.permission.UPDATE_DEVICE_STATS" />
54     <!-- TODO: replace with READ_NETWORK_POLICY permission when it exists -->
55     <uses-permission android:name="android.permission.CONNECTIVITY_INTERNAL" />
56     <uses-permission android:name="android.permission.MODIFY_NETWORK_ACCOUNTING" />
57
58     <application android:process="android.process.media"
59                  android:label="@string/app_label"
60                  android:icon="@mipmap/ic_launcher_download">
61
62         <provider android:name=".DownloadProvider"
63                   android:authorities="downloads" android:exported="true">
64           <!-- Anyone can access /my_downloads, the provider internally restricts access by UID for
65                these URIs -->
66           <path-permission android:pathPrefix="/my_downloads"
67                            android:permission="android.permission.INTERNET"/>
68           <!-- to access /all_downloads, ACCESS_ALL_DOWNLOADS permission is required -->
69           <path-permission android:pathPrefix="/all_downloads"
70                            android:permission="android.permission.ACCESS_ALL_DOWNLOADS"/>
71           <!-- Temporary, for backwards compatibility -->
72           <path-permission android:pathPrefix="/download"
73                            android:permission="android.permission.INTERNET"/>
74           <!-- Apps with access to /all_downloads/... can grant permissions, allowing them to share
75                downloaded files with other viewers -->
76           <grant-uri-permission android:pathPrefix="/all_downloads/"/>
77           <!-- Apps with access to /my_downloads/... can grant permissions, allowing them to share
78                downloaded files with other viewers -->
79           <grant-uri-permission android:pathPrefix="/my_downloads/"/>
80         </provider>
81
82         <provider
83             android:name=".DownloadStorageProvider"
84             android:authorities="com.android.providers.downloads.documents"
85             android:grantUriPermissions="true"
86             android:exported="true"
87             android:permission="android.permission.MANAGE_DOCUMENTS">
88             <meta-data
89                 android:name="android.content.DOCUMENT_PROVIDER"
90                 android:resource="@xml/document_provider" />
91         </provider>
92
93         <service android:name=".DownloadService"
94                 android:permission="android.permission.ACCESS_DOWNLOAD_MANAGER" />
95         <receiver android:name=".DownloadReceiver" android:exported="false">
96             <intent-filter>
97                 <action android:name="android.intent.action.BOOT_COMPLETED" />
98                 <action android:name="android.net.conn.CONNECTIVITY_CHANGE" />
99             </intent-filter>
100             <intent-filter>
101                 <action android:name="android.intent.action.MEDIA_MOUNTED" />
102                 <data android:scheme="file" />
103             </intent-filter>
104         </receiver>
105
106         <activity android:name=".SizeLimitActivity"
107                   android:launchMode="singleTask"
108                   android:theme="@style/Theme.Translucent"/>
109     </application>
110 </manifest>