1<?xml version="1.0" encoding="utf-8"?>
2
3<manifest xmlns:android="http://schemas.android.com/apk/res/android"
4     package="com.android.bluetooth"
5     android:sharedUserId="android.uid.bluetooth">
6
7    <original-package android:name="com.android.bluetooth"/>
8
9    <!-- Allows access to the Bluetooth Share Manager -->
10    <permission android:name="android.permission.ACCESS_BLUETOOTH_SHARE"
11         android:label="@string/permlab_bluetoothShareManager"
12         android:description="@string/permdesc_bluetoothShareManager"
13         android:protectionLevel="signature"/>
14
15    <!--  Allows temporarily acceptlisting Bluetooth addresses for sharing -->
16    <permission android:name="com.android.permission.ALLOWLIST_BLUETOOTH_DEVICE"
17         android:label="@string/permlab_bluetoothAcceptlist"
18         android:description="@string/permdesc_bluetoothAcceptlist"
19         android:protectionLevel="signature"/>
20
21    <uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED"/>
22    <uses-permission android:name="android.permission.ACCESS_BLUETOOTH_SHARE"/>
23    <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>
24    <uses-permission android:name="android.permission.INTERNET"/>
25    <uses-permission android:name="android.permission.BLUETOOTH"/>
26    <uses-permission android:name="android.permission.BLUETOOTH_ADMIN"/>
27    <uses-permission android:name="android.permission.BLUETOOTH_ADVERTISE"/>
28    <uses-permission android:name="android.permission.BLUETOOTH_CONNECT"/>
29    <uses-permission android:name="android.permission.BLUETOOTH_SCAN"/>
30    <uses-permission android:name="android.permission.BLUETOOTH_PRIVILEGED"/>
31    <uses-permission android:name="android.permission.BLUETOOTH_MAP"/>
32    <uses-permission android:name="android.permission.CONTROL_INCALL_EXPERIENCE" />
33    <uses-permission android:name="android.permission.DUMP"/>
34    <uses-permission android:name="android.permission.WAKE_LOCK"/>
35    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
36    <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
37    <uses-permission android:name="android.permission.READ_CONTACTS"/>
38    <uses-permission android:name="android.permission.WRITE_CONTACTS"/>
39    <uses-permission android:name="android.permission.READ_CALL_LOG"/>
40    <uses-permission android:name="android.permission.WRITE_CALL_LOG"/>
41    <uses-permission android:name="android.permission.READ_PRIVILEGED_PHONE_STATE"/>
42    <uses-permission android:name="android.permission.LISTEN_ALWAYS_REPORTED_SIGNAL_STRENGTH"/>
43    <uses-permission android:name="android.permission.WRITE_SETTINGS"/>
44    <uses-permission android:name="android.permission.NFC_HANDOVER_STATUS"/>
45    <uses-permission android:name="android.permission.WRITE_SECURE_SETTINGS"/>
46    <uses-permission android:name="android.permission.WRITE_APN_SETTINGS"/>
47    <uses-permission android:name="android.permission.NET_ADMIN"/>
48    <uses-permission android:name="android.permission.CALL_PRIVILEGED"/>
49    <uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS"/>
50    <uses-permission android:name="android.permission.NET_TUNNELING"/>
51    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
52    <uses-permission android:name="android.permission.CHANGE_NETWORK_STATE"/>
53    <uses-permission android:name="android.permission.CONNECTIVITY_INTERNAL"/>
54    <uses-permission android:name="android.permission.READ_DEVICE_CONFIG"/>
55    <uses-permission android:name="android.permission.NETWORK_FACTORY"/>
56    <uses-permission android:name="android.permission.TETHER_PRIVILEGED"/>
57    <uses-permission android:name="android.permission.MODIFY_PHONE_STATE"/>
58    <uses-permission android:name="android.permission.INTERACT_ACROSS_USERS_FULL"/>
59    <uses-permission android:name="android.permission.BLUETOOTH_STACK"/>
60    <uses-permission android:name="android.permission.INTERACT_ACROSS_USERS"/>
61    <uses-permission android:name="android.permission.MANAGE_USERS"/>
62    <uses-permission android:name="android.permission.GET_ACCOUNTS"/>
63    <uses-permission android:name="android.permission.RECEIVE_SMS"/>
64    <uses-permission android:name="android.permission.SEND_SMS"/>
65    <uses-permission android:name="android.permission.READ_SMS"/>
66    <uses-permission android:name="android.permission.WRITE_SMS"/>
67    <uses-permission android:name="android.permission.MEDIA_CONTENT_CONTROL"/>
68    <uses-permission android:name="android.permission.UPDATE_APP_OPS_STATS"/>
69    <uses-permission android:name="android.permission.MANAGE_APP_OPS_MODES"/>
70    <uses-permission android:name="android.permission.VIBRATE"/>
71    <uses-permission android:name="android.permission.DEVICE_POWER"/>
72    <uses-permission android:name="android.permission.REAL_GET_TASKS"/>
73    <uses-permission android:name="android.permission.MODIFY_AUDIO_ROUTING"/>
74    <uses-permission android:name="android.permission.UPDATE_DEVICE_STATS"/>
75    <uses-permission android:name="android.permission.PACKAGE_USAGE_STATS"/>
76    <uses-permission android:name="android.permission.QUERY_ALL_PACKAGES"/>
77    <uses-permission android:name="android.permission.MANAGE_COMPANION_DEVICES"/>
78    <uses-permission android:name="android.permission.START_FOREGROUND_SERVICES_FROM_BACKGROUND"/>
79    <uses-permission android:name="android.permission.HIDE_OVERLAY_WINDOWS"/>
80
81    <uses-sdk android:minSdkVersion="14"/>
82
83    <!-- For PBAP Owner Vcard Info -->
84    <uses-permission android:name="android.permission.READ_PROFILE"/>
85    <application android:name=".btservice.AdapterApp"
86         android:icon="@mipmap/bt_share"
87         android:persistent="false"
88         android:label="@string/app_name"
89         android:supportsRtl="true"
90         android:usesCleartextTraffic="false"
91         android:directBootAware="true"
92         android:defaultToDeviceProtectedStorage="true"
93         android:memtagMode="async">
94        <uses-library android:name="javax.obex"/>
95        <provider android:name=".opp.BluetoothOppProvider"
96             android:authorities="com.android.bluetooth.opp"
97             android:exported="true"
98             android:process="@string/process">
99            <path-permission android:pathPrefix="/btopp"
100                 android:permission="android.permission.ACCESS_BLUETOOTH_SHARE"/>
101        </provider>
102        <provider android:name=".opp.BluetoothOppFileProvider"
103             android:authorities="com.android.bluetooth.opp.fileprovider"
104             android:grantUriPermissions="true"
105             android:exported="false">
106            <meta-data android:name="android.support.FILE_PROVIDER_PATHS"
107                 android:resource="@xml/file_paths"/>
108        </provider>
109        <service android:process="@string/process"
110             android:name=".btservice.AdapterService"
111             android:exported="true"
112             android:permission="android.permission.ACCESS_BLUETOOTH_SHARE">
113            <intent-filter>
114                <action android:name="android.bluetooth.IBluetooth"/>
115            </intent-filter>
116        </service>
117        <service android:process="@string/process"
118             android:name=".opp.BluetoothOppService"
119             android:permission="android.permission.ACCESS_BLUETOOTH_SHARE"
120             android:enabled="@bool/profile_supported_opp"/>
121        <receiver android:process="@string/process"
122             android:exported="true"
123             android:name=".opp.BluetoothOppReceiver"
124             android:enabled="@bool/profile_supported_opp">
125            <intent-filter>
126                <action android:name="android.btopp.intent.action.OPEN_RECEIVED_FILES"/>
127            </intent-filter>
128        </receiver>
129         <receiver android:process="@string/process"
130              android:name=".opp.BluetoothOppHandoverReceiver"
131              android:permission="com.android.permission.ALLOWLIST_BLUETOOTH_DEVICE"
132              android:exported="true">
133            <intent-filter>
134                <action android:name="android.btopp.intent.action.ACCEPTLIST_DEVICE"/>
135                <action android:name="android.btopp.intent.action.STOP_HANDOVER_TRANSFER"/>
136            </intent-filter>
137            <intent-filter>
138                <action android:name="android.nfc.handover.intent.action.HANDOVER_SEND"/>
139                <category android:name="android.intent.category.DEFAULT"/>
140                <data android:mimeType="*/*"/>
141            </intent-filter>
142            <intent-filter>
143                <action android:name="android.nfc.handover.intent.action.HANDOVER_SEND_MULTIPLE"/>
144                <category android:name="android.intent.category.DEFAULT"/>
145                <data android:mimeType="*/*"/>
146            </intent-filter>
147        </receiver>
148        <activity android:name=".opp.BluetoothOppLauncherActivity"
149             android:process="@string/process"
150             android:theme="@android:style/Theme.Material.Light.Dialog"
151             android:label="@string/bt_share_picker_label"
152             android:enabled="@bool/profile_supported_opp"
153             android:exported="true">
154            <intent-filter>
155                <action android:name="android.intent.action.SEND"/>
156                <category android:name="android.intent.category.DEFAULT"/>
157                <data android:mimeType="image/*"/>
158                <data android:mimeType="video/*"/>
159                <data android:mimeType="audio/*"/>
160                <data android:mimeType="text/x-vcard"/>
161                <data android:mimeType="text/x-vcalendar"/>
162                <data android:mimeType="text/calendar"/>
163                <data android:mimeType="text/plain"/>
164                <data android:mimeType="text/html"/>
165                <data android:mimeType="text/xml"/>
166                <data android:mimeType="application/zip"/>
167                <data android:mimeType="application/vnd.ms-excel"/>
168                <data android:mimeType="application/msword"/>
169                <data android:mimeType="application/vnd.ms-powerpoint"/>
170                <data android:mimeType="application/pdf"/>
171                <data android:mimeType="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"/>
172                <data android:mimeType="application/vnd.openxmlformats-officedocument.wordprocessingml.document"/>
173                <data android:mimeType="application/vnd.openxmlformats-officedocument.presentationml.presentation"/>
174                <data android:mimeType="application/x-hwp"/>
175            </intent-filter>
176            <intent-filter>
177                <action android:name="android.intent.action.SEND_MULTIPLE"/>
178                <category android:name="android.intent.category.DEFAULT"/>
179                <data android:mimeType="image/*"/>
180                <data android:mimeType="video/*"/>
181                <data android:mimeType="x-mixmedia/*"/>
182                <data android:mimeType="text/x-vcard"/>
183            </intent-filter>
184            <intent-filter>
185                <action android:name="android.btopp.intent.action.OPEN"/>
186                <category android:name="android.intent.category.DEFAULT"/>
187                <data android:mimeType="vnd.android.cursor.item/vnd.android.btopp"/>
188            </intent-filter>
189        </activity>
190        <activity android:name=".opp.BluetoothOppBtEnableActivity"
191             android:process="@string/process"
192             android:excludeFromRecents="true"
193             android:theme="@style/dialog"
194             android:enabled="@bool/profile_supported_opp">
195        </activity>
196        <activity android:name=".opp.BluetoothOppBtErrorActivity"
197             android:process="@string/process"
198             android:excludeFromRecents="true"
199             android:theme="@style/dialog">
200        </activity>
201        <activity android:name=".opp.BluetoothOppBtEnablingActivity"
202             android:process="@string/process"
203             android:excludeFromRecents="true"
204             android:theme="@style/dialog"
205             android:enabled="@bool/profile_supported_opp">
206        </activity>
207        <activity android:name=".opp.BluetoothOppIncomingFileConfirmActivity"
208             android:process="@string/process"
209             android:excludeFromRecents="true"
210             android:theme="@style/dialog"
211             android:enabled="@bool/profile_supported_opp">
212        </activity>
213        <activity android:name=".opp.BluetoothOppTransferActivity"
214             android:process="@string/process"
215             android:excludeFromRecents="true"
216             android:theme="@style/dialog"
217             android:enabled="@bool/profile_supported_opp">
218        </activity>
219        <activity android:name=".opp.BluetoothOppTransferHistory"
220             android:process="@string/process"
221             android:label=""
222             android:excludeFromRecents="true"
223             android:configChanges="orientation|keyboardHidden"
224             android:enabled="@bool/profile_supported_opp"
225             android:theme="@android:style/Theme.DeviceDefault.Settings"
226             android:exported="true">
227            <intent-filter>
228                <action android:name="com.android.bluetooth.action.TransferHistory"/>
229                <category android:name="android.intent.category.DEFAULT"/>
230            </intent-filter>
231        </activity>
232        <activity android:name=".pbap.BluetoothPbapActivity"
233             android:process="@string/process"
234             android:excludeFromRecents="true"
235             android:theme="@style/dialog"
236             android:enabled="@bool/profile_supported_pbap">
237        </activity>
238        <service android:process="@string/process"
239             android:permission="android.permission.BLUETOOTH_PRIVILEGED"
240             android:name=".pbap.BluetoothPbapService"
241             android:enabled="@bool/profile_supported_pbap"
242             android:exported="true">
243            <intent-filter>
244                <action android:name="android.bluetooth.IBluetoothPbap"/>
245            </intent-filter>
246        </service>
247        <service android:process="@string/process"
248             android:name=".map.BluetoothMapService"
249             android:enabled="@bool/profile_supported_map"
250             android:exported="true">
251            <intent-filter>
252                <action android:name="android.bluetooth.IBluetoothMap"/>
253                <action android:name="android.btmap.intent.action.SHOW_MAPS_SETTINGS"/>
254                <action android:name="com.android.bluetooth.map.USER_CONFIRM_TIMEOUT"/>
255            </intent-filter>
256        </service>
257         <activity android:name=".map.BluetoothMapSettings"
258              android:process="@string/process"
259              android:label="@string/bluetooth_map_settings_title"
260              android:excludeFromRecents="true"
261              android:configChanges="orientation|keyboardHidden"
262              android:enabled="@bool/profile_supported_map">
263        </activity>
264        <provider android:name=".map.MmsFileProvider"
265             android:authorities="com.android.bluetooth.map.MmsFileProvider"
266             android:enabled="true"
267             android:grantUriPermissions="true"
268             android:exported="false">
269        </provider>
270        <service android:process="@string/process"
271             android:name=".mapclient.MapClientService"
272             android:enabled="@bool/profile_supported_mapmce"
273             android:exported="true">
274            <intent-filter>
275                <action android:name="android.bluetooth.IBluetoothMapClient"/>
276            </intent-filter>
277        </service>
278        <service android:process="@string/process"
279             android:name=".sap.SapService"
280             android:enabled="@bool/profile_supported_sap"
281             android:exported="true">
282            <intent-filter>
283                <action android:name="android.bluetooth.IBluetoothSap"/>
284            </intent-filter>
285        </service>
286        <service android:process="@string/process"
287             android:name=".gatt.GattService"
288             android:enabled="@bool/profile_supported_gatt"
289             android:exported="true"
290             android:permission="android.permission.ACCESS_BLUETOOTH_SHARE">
291            <intent-filter>
292                <action android:name="android.bluetooth.IBluetoothGatt"/>
293            </intent-filter>
294        </service>
295        <service android:process="@string/process"
296             android:name=".hfp.HeadsetService"
297             android:enabled="@bool/profile_supported_hs_hfp"
298             android:exported="true">
299            <intent-filter>
300                <action android:name="android.bluetooth.IBluetoothHeadset"/>
301            </intent-filter>
302        </service>
303        <service android:process="@string/process"
304             android:name=".a2dp.A2dpService"
305             android:enabled="@bool/profile_supported_a2dp"
306             android:exported="true">
307            <intent-filter>
308                <action android:name="android.bluetooth.IBluetoothA2dp"/>
309            </intent-filter>
310        </service>
311        <service android:process="@string/process"
312             android:name=".a2dpsink.A2dpSinkService"
313             android:enabled="@bool/profile_supported_a2dp_sink"
314             android:exported="true">
315            <intent-filter>
316                <action android:name="android.bluetooth.IBluetoothA2dpSink"/>
317            </intent-filter>
318        </service>
319        <service android:process="@string/process"
320             android:name=".avrcpcontroller.BluetoothMediaBrowserService"
321             android:exported="true"
322             android:enabled="@bool/profile_supported_a2dp_sink"
323             android:label="@string/a2dp_sink_mbs_label">
324            <intent-filter>
325                <action android:name="android.media.browse.MediaBrowserService"/>
326            </intent-filter>
327        </service>
328
329        <activity android:name=".BluetoothPrefs"
330             android:exported="@bool/profile_supported_a2dp_sink"
331             android:enabled="@bool/profile_supported_a2dp_sink">
332            <intent-filter>
333                <action android:name="android.intent.action.APPLICATION_PREFERENCES"/>
334            </intent-filter>
335        </activity>
336
337        <service android:process="@string/process"
338             android:name=".avrcp.AvrcpTargetService"
339             android:enabled="@bool/profile_supported_avrcp_target"
340             android:exported="true">
341            <intent-filter>
342                <action android:name="android.bluetooth.IBluetoothAvrcp"/>
343            </intent-filter>
344        </service>
345        <service android:process="@string/process"
346             android:name=".avrcpcontroller.AvrcpControllerService"
347             android:enabled="@bool/profile_supported_avrcp_controller"
348             android:exported="true">
349            <intent-filter>
350                <action android:name="android.bluetooth.IBluetoothAvrcpController"/>
351            </intent-filter>
352        </service>
353        <provider android:process="@string/process"
354             android:name=".avrcpcontroller.AvrcpCoverArtProvider"
355             android:authorities="com.android.bluetooth.avrcpcontroller.AvrcpCoverArtProvider"
356             android:enabled="@bool/avrcp_controller_enable_cover_art"
357             android:grantUriPermissions="true"
358             android:exported="true">
359        </provider>
360        <service android:process="@string/process"
361             android:name=".hid.HidHostService"
362             android:enabled="@bool/profile_supported_hid_host"
363             android:exported="true">
364            <intent-filter>
365                <action android:name="android.bluetooth.IBluetoothHidHost"/>
366            </intent-filter>
367        </service>
368        <service android:process="@string/process"
369             android:name=".hid.HidDeviceService"
370             android:enabled="@bool/profile_supported_hid_device"
371             android:exported="true">
372            <intent-filter>
373                <action android:name="android.bluetooth.IBluetoothHidDevice"/>
374            </intent-filter>
375        </service>
376        <service android:process="@string/process"
377             android:name=".pan.PanService"
378             android:enabled="@bool/profile_supported_pan"
379             android:exported="true">
380            <intent-filter>
381                <action android:name="android.bluetooth.IBluetoothPan"/>
382            </intent-filter>
383        </service>
384        <service android:process="@string/process"
385             android:name=".hfpclient.HeadsetClientService"
386             android:enabled="@bool/profile_supported_hfpclient"
387             android:exported="true">
388            <intent-filter>
389                <action android:name="android.bluetooth.IBluetoothHeadsetClient"/>
390            </intent-filter>
391        </service>
392        <service android:process="@string/process"
393             android:name=".hfpclient.connserv.HfpClientConnectionService"
394             android:permission="android.permission.BIND_CONNECTION_SERVICE"
395             android:enabled="@bool/hfp_client_connection_service_enabled"
396             android:exported="true">
397            <intent-filter>
398                <!-- Mechanism for Telecom stack to connect -->
399                <action android:name="android.telecom.ConnectionService"/>
400            </intent-filter>
401        </service>
402        <service android:process="@string/process"
403             android:name=".pbapclient.PbapClientService"
404             android:enabled="@bool/profile_supported_pbapclient"
405             android:exported="true">
406            <intent-filter>
407                <action android:name="android.bluetooth.IBluetoothPbapClient"/>
408            </intent-filter>
409        </service>
410        <service android:process="@string/process"
411             android:name=".hearingaid.HearingAidService"
412             android:exported="true">
413            <intent-filter>
414                <action android:name="android.bluetooth.IBluetoothHearingAid"/>
415            </intent-filter>
416        </service>
417        <service
418            android:process="@string/process"
419            android:name = ".le_audio.LeAudioService"
420            android:exported = "true">
421            <intent-filter>
422                <action android:name="android.bluetooth.IBluetoothLeAudio" />
423            </intent-filter>
424        </service>
425        <!-- Authenticator for PBAP account. -->
426        <service android:process="@string/process"
427             android:name=".pbapclient.AuthenticationService"
428             android:exported="true"
429             android:enabled="@bool/profile_supported_pbapclient">
430            <intent-filter>
431                <action android:name="android.accounts.AccountAuthenticator"/>
432            </intent-filter>
433            <meta-data android:name="android.accounts.AccountAuthenticator"
434                 android:resource="@xml/authenticator"/>
435        </service>
436        <service
437            android:name=".telephony.BluetoothInCallService"
438            android:permission="android.permission.BIND_INCALL_SERVICE"
439            android:process="@string/process"
440            android:enabled="@bool/profile_supported_hfp_incallservice"
441            android:exported="true">
442            <meta-data android:name="android.telecom.INCLUDE_SELF_MANAGED_CALLS"
443                       android:value="true" />
444            <intent-filter>
445              <action android:name="android.telecom.InCallService"/>
446            </intent-filter>
447         </service>
448    </application>
449</manifest>
450