1###################################
2# System files
3#
4/(vendor|system/vendor)/bin/PktRspTest          u:object_r:diag_exec:s0
5/(vendor|system/vendor)/bin/hvdcp_opti          u:object_r:hvdcp_exec:s0
6/(vendor|system/vendor)/bin/cnd                 u:object_r:cnd_exec:s0
7/(vendor|system/vendor)/bin/diag_callback_client                u:object_r:diag_exec:s0
8/(vendor|system/vendor)/bin/diag_dci_sample                     u:object_r:diag_exec:s0
9/(vendor|system/vendor)/bin/diag_klog                           u:object_r:diag_exec:s0
10/(vendor|system/vendor)/bin/diag_mdlog                          u:object_r:qlogd_exec:s0
11/(vendor|system/vendor)/bin/drmdiagapp          u:object_r:diag_exec:s0
12/(vendor|system/vendor)/bin/diag_qshrink4_daemon                u:object_r:diag_exec:s0
13/(vendor|system/vendor)/bin/diag_socket_log                     u:object_r:diag_exec:s0
14/(vendor|system/vendor)/bin/diag_uart_log                       u:object_r:diag_exec:s0
15/(vendor|system/vendor)/bin/diag_buffering_test                 u:object_r:diag_exec:s0
16/(vendor|system/vendor)/bin/irsc_util                           u:object_r:irsc_util_exec:s0
17/(vendor|system/vendor)/bin/qrtr-cfg                            u:object_r:qrtr_exec:s0
18/(vendor|system/vendor)/bin/qrtr-ns                             u:object_r:qrtr_exec:s0
19/(vendor|system/vendor)/bin/init\.sensors\.sh               u:object_r:qti_init_shell_exec:s0
20/(vendor|system/vendor)/bin/msm_irqbalance      u:object_r:msm_irqbalanced_exec:s0
21/(vendor|system/vendor)/bin/imsdatadaemon       u:object_r:ims_exec:s0
22/(vendor|system/vendor)/bin/imsqmidaemon        u:object_r:ims_exec:s0
23/(vendor|system/vendor)/bin/ims_rtp_daemon      u:object_r:hal_imsrtp_exec:s0
24/(vendor|system/vendor)/bin/netmgrd             u:object_r:netmgrd_exec:s0
25/(vendor|system/vendor)/bin/shsusrd             u:object_r:shsusrd_exec:s0
26/(vendor|system/vendor)/bin/port-bridge         u:object_r:port-bridge_exec:s0
27/(vendor|system/vendor)/bin/sensors.qcom        u:object_r:sensors_exec:s0
28/(vendor|system/vendor)/bin/sensors.qti         u:object_r:sensors_exec:s0
29/(vendor|system/vendor)/bin/test_diag           u:object_r:diag_exec:s0
30/(vendor|system/vendor)/bin/time_daemon         u:object_r:time_daemon_exec:s0
31/(vendor|system/vendor)/bin/rmt_storage         u:object_r:rmt_storage_exec:s0
32/(vendor|system/vendor)/bin/tftp_server         u:object_r:rfs_access_exec:s0
33/(vendor|system/vendor)/bin/hvdcp                               u:object_r:hvdcp_exec:s0
34/(vendor|system/vendor)/bin/qseecomd            u:object_r:tee_exec:s0
35/(vendor|system/vendor)/bin/spdaemon            u:object_r:spdaemon_exec:s0
36/(vendor|system/vendor)/bin/sec_nvm             u:object_r:sec_nvm_exec:s0
37/(vendor|system/vendor)/bin/cnss-daemon         u:object_r:wcnss_service_exec:s0
38/(vendor|system/vendor)/bin/cnss_diag           u:object_r:wcnss_service_exec:s0
39/(vendor|system/vendor)/bin/adsprpcd            u:object_r:adsprpcd_exec:s0
40/(vendor|system/vendor)/bin/cdsprpcd            u:object_r:cdsprpcd_exec:s0
41/vendor/bin/dspservice                          u:object_r:dspservice_exec:s0
42/(vendor|system/vendor)/bin/wpa_cli             u:object_r:wcnss_service_exec:s0
43/(vendor|system/vendor)/bin/mdm_helper          u:object_r:mdm_helper_exec:s0
44/(vendor|system/vendor)/bin/mdm_helper_proxy    u:object_r:mdm_helper_exec:s0
45/(vendor|system/vendor)/bin/ks                                  u:object_r:mdm_helper_exec:s0
46/(vendor|system/vendor)/bin/pm-service          u:object_r:vendor_per_mgr_exec:s0
47/(vendor|system/vendor)/bin/pm-proxy            u:object_r:vendor_per_mgr_exec:s0
48/(vendor|system/vendor)/bin/pd-mapper           u:object_r:vendor_pd_mapper_exec:s0
49/(vendor|system/vendor)/bin/pd-api-test         u:object_r:vendor_pd_mapper_exec:s0
50/(vendor|system/vendor)/xbin/qlogd                              u:object_r:qlogd_exec:s0
51/(vendor|system/vendor)/bin/ssr_setup           u:object_r:vendor_ssr_setup_exec:s0
52/(vendor|system/vendor)/bin/subsystem_ramdump   u:object_r:vendor_subsystem_ramdump_exec:s0
53/(vendor|system/vendor)/bin/ssr_diag            u:object_r:vendor_ssr_diag_exec:s0
54/(vendor|system/vendor)/bin/hw/qcrild           u:object_r:rild_exec:s0
55/(vendor|system/vendor)/bin/hw/android\.hardware\.drm@[0-9]+\.[0-9]+-(service|service-lazy)\.clearkey    u:object_r:hal_drm_clearkey_exec:s0
56/(vendor|system/vendor)/bin/hw/android\.hardware\.drm(@[0-9]+\.[0-9]+)?-(service|service-lazy)\.widevine(-v17)?    u:object_r:hal_drm_widevine_exec:s0
57/(vendor|system/vendor)/bin/hw/android\.hardware\.gnss@.*-service-qti u:object_r:hal_gnss_qti_exec:s0
58/(vendor|system/vendor)/bin/hw/vendor\.qti\.gnss@.*-service u:object_r:hal_gnss_qti_exec:s0
59/(vendor|system/vendor)/bin/hw/android\.hardware\.bluetooth@1\.0-service-qti  u:object_r:hal_bluetooth_default_exec:s0
60/(vendor|system/vendor)/bin/hw/vendor\.display\.color@1\.0-service            u:object_r:hal_display_color_default_exec:s0
61/(vendor|system/vendor)/bin/sscrpcd                                 u:object_r:sensors_exec:s0
62/(vendor|system/vendor)/bin/loc_launcher        u:object_r:location_exec:s0
63/(vendor|system/vendor)/bin/lowi-server         u:object_r:location_exec:s0
64/(vendor|system/vendor)/bin/xtra-daemon         u:object_r:location_exec:s0
65/(vendor|system/vendor)/bin/wcnss_service       u:object_r:wcnss_service_exec:s0
66/(vendor|system/vendor)/bin/hw/android\.hardware\.keymaster@3\.0-service-qti u:object_r:hal_keymaster_qti_exec:s0
67/(vendor|system/vendor)/bin/hw/android\.hardware\.keymaster@4\.0-service-qti u:object_r:hal_keymaster_qti_exec:s0
68/(vendor|system/vendor)/bin/hw/android\.hardware\.keymaster@4\.0-strongbox-service-qti u:object_r:hal_keymaster_qti_exec:s0
69/(vendor|system/vendor)/bin/hw/android\.hardware\.keymaster@4\.1-service-qti u:object_r:hal_keymaster_qti_exec:s0
70/(vendor|system/vendor)/bin/init\.qti\.keymaster\.sh u:object_r:init-qti-keymaster-sh_exec:s0
71/(vendor|system/vendor)/bin/hw/android\.hardware\.gatekeeper@1\.0-service-qti u:object_r:hal_gatekeeper_qti_exec:s0
72/(vendor|system/vendor)/bin/imsrcsd             u:object_r:hal_rcsservice_exec:s0
73/(vendor|system/vendor)/bin/hw/vendor\.qti\.hardware\.qteeconnector@1\.0-service u:object_r:hal_qteeconnector_qti_exec:s0
74/vendor/bin/hw/vendor\.qti\.hardware\.qseecom@1\.0-service                  u:object_r:hal_qseecom_default_exec:s0
75/vendor/bin/vendor\.qti\.qspmhal@1\.0-service                               u:object_r:hal_qspmhal_default_exec:s0
76/(vendor|system/vendor)/bin/chre                u:object_r:chre_exec:s0
77/(vendor|system/vendor)/bin/hw/vendor\.qti\.hardware\.display\.allocator@1\.0-service   u:object_r:hal_graphics_allocator_default_exec:s0
78/(vendor|system/vendor)/bin/hw/vendor\.qti\.hardware\.display\.allocator-service   u:object_r:hal_graphics_allocator_default_exec:s0
79/(vendor|system/vendor)/bin/hw/vendor\.qti\.hardware\.tui_comm@1\.0-service-qti u:object_r:hal_tui_comm_qti_exec:s0
80/(vendor|system/vendor)/bin/hw/vendor\.qti\.media\.c2@1\.0-service u:object_r:mediacodec_exec:s0
81/(vendor|system/vendor)/bin/qti                 u:object_r:qti_exec:s0
82/(vendor|system/vendor)/bin/adpl                u:object_r:adpl_exec:s0
83/(vendor|system/vendor)/bin/ssgtzd              u:object_r:ssgtzd_exec:s0
84/(vendor|system/vendor)/bin/feature_enabler_client              u:object_r:feature_enabler_client_exec:s0
85
86# dev socket nodes
87/dev/socket/chre                                u:object_r:chre_socket:s0
88/dev/socket/msm_irqbalance                      u:object_r:irqbalance_socket:s0
89/dev/socket/qmux_radio(/.*)?                    u:object_r:qmuxd_socket:s0
90/dev/socket/netmgr(/.*)?                        u:object_r:netmgrd_socket:s0
91/dev/socket/ims_qmid                            u:object_r:ims_socket:s0
92/dev/socket/ims_datad                           u:object_r:ims_socket:s0
93/dev/socket/ssgtzd                              u:object_r:ssgtzd_socket:s0
94/dev/socket/adpl_cmd_uds_file                   u:object_r:dataadpl_socket:s0
95
96###################################
97# persist files
98#
99/mnt/vendor/persist/camera(/.*)?                                               u:object_r:persist_camera_file:s0
100/mnt/vendor/persist/drm(/.*)?                                                  u:object_r:persist_drm_file:s0
101/mnt/vendor/persist/sensors(/.*)?                                              u:object_r:sensors_persist_file:s0
102/mnt/vendor/persist/sensors/registry/factory_data(/.*)?                        u:object_r:persist_sensors_reg_fac_file:s0
103/mnt/vendor/persist/time(/.*)?                                                 u:object_r:persist_time_file:s0
104/mnt/vendor/persist/data(/.*)?                                                 u:object_r:persist_drm_file:s0
105/mnt/vendor/persist/data/tz(/.*)?                                              u:object_r:persist_drm_file:s0
106/mnt/vendor/persist/data/sfs(/.*)?                                             u:object_r:persist_drm_file:s0
107/mnt/vendor/persist/hlos_rfs(/.*)?                                             u:object_r:persist_rfs_shared_hlos_file:s0
108/mnt/vendor/persist/display(/.*)?                                              u:object_r:persist_display_file:s0
109/mnt/vendor/persist/rfs.*                                                      u:object_r:persist_rfs_file:s0
110/mnt/vendor/persist/hvdcp_opti(/.*)?                                           u:object_r:persist_hvdcp_file:s0
111/mnt/vendor/persist/audio(/.*)?                                                u:object_r:persist_audio_file:s0
112
113###################################
114# adsp files
115#
116/(vendor|system/vendor)/dsp(/.*)?                                   u:object_r:adsprpcd_file:s0
117/dsp(/.*)?                                                          u:object_r:adsprpcd_file:s0
118
119###################################
120# cache files
121#
122
123###################################
124# vendor files
125#
126/vendor/package(/.*)?/overlay(/.*)?        u:object_r:vendor_overlay_file:s0
127/vendor/package(/.*)?/app(/.*)?            u:object_r:vendor_app_file:s0
128
129# same-process HAL files and their dependencies
130#
131/vendor/lib(64)?/hw/android\.hardware\.graphics\.mapper@2\.0-impl-qti-display\.so   u:object_r:same_process_hal_file:s0
132/vendor/lib(64)?/vendor\.qti\.hardware\.display\.mapper@1\.0\.so   u:object_r:same_process_hal_file:s0
133/vendor/lib(64)?/vendor\.qti\.hardware\.display\.mapper@2\.0\.so   u:object_r:same_process_hal_file:s0
134/vendor/lib(64)?/vendor\.qti\.hardware\.display\.mapperextensions@1\.0\.so   u:object_r:same_process_hal_file:s0
135/vendor/lib(64)?/vendor\.qti\.hardware\.display\.mapperextensions@1\.1\.so   u:object_r:same_process_hal_file:s0
136/vendor/lib(64)?/hw/android\.hardware\.graphics\.mapper@3\.0-impl-qti-display\.so   u:object_r:same_process_hal_file:s0
137/vendor/lib(64)?/vendor\.qti\.hardware\.display\.mapper@3\.0\.so   u:object_r:same_process_hal_file:s0
138/vendor/lib(64)?/hw/android\.hardware\.graphics\.mapper@4\.0-impl-qti-display\.so   u:object_r:same_process_hal_file:s0
139/vendor/lib(64)?/vendor\.qti\.hardware\.display\.mapper@4\.0\.so   u:object_r:same_process_hal_file:s0
140/vendor/lib(64)?/libcamxexternalformatutils\.so                    u:object_r:same_process_hal_file:s0
141/vendor/lib(64)?/libqdMetaData\.so         u:object_r:same_process_hal_file:s0
142/vendor/lib(64)?/libgralloc\.qti\.so       u:object_r:same_process_hal_file:s0
143/vendor/lib(64)?/lib_aion_buffer\.so       u:object_r:same_process_hal_file:s0
144/vendor/lib(64)?/libqservice\.so           u:object_r:same_process_hal_file:s0
145/vendor/lib(64)?/libqdutils\.so            u:object_r:same_process_hal_file:s0
146/vendor/lib(64)?/libadreno_utils\.so       u:object_r:same_process_hal_file:s0
147/vendor/lib(64)?/libgpudataproducer\.so    u:object_r:same_process_hal_file:s0
148/vendor/lib(64)?/libgsl\.so                u:object_r:same_process_hal_file:s0
149/vendor/lib64/libipebpsstriping\.so        u:object_r:same_process_hal_file:s0
150
151/vendor/lib(64)?/libEGL_adreno\.so         u:object_r:same_process_hal_file:s0
152/vendor/lib(64)?/libGLESv1_CM_adreno\.so   u:object_r:same_process_hal_file:s0
153/vendor/lib(64)?/libGLESv2_adreno\.so      u:object_r:same_process_hal_file:s0
154
155/vendor/lib(64)?/libdrmutils\.so           u:object_r:same_process_hal_file:s0
156/vendor/lib(64)?/libdrm\.so                u:object_r:same_process_hal_file:s0
157
158/vendor/lib(64)?/libavenhancements\.so     u:object_r:same_process_hal_file:s0
159/vendor/lib(64)?/libgrallocutils\.so       u:object_r:same_process_hal_file:s0
160/vendor/lib(64)?/libgralloccore\.so        u:object_r:same_process_hal_file:s0
161/vendor/lib(64)?/libExtendedExtractor.so   u:object_r:same_process_hal_file:s0
162# RenderScript dependencies.
163# To test: run cts -m CtsRenderscriptTestCases
164/vendor/lib(64)?/libRSDriver_adreno\.so     u:object_r:same_process_hal_file:s0
165/vendor/lib(64)?/libCB\.so                  u:object_r:same_process_hal_file:s0
166/vendor/lib(64)?/libllvm-qgl\.so            u:object_r:same_process_hal_file:s0
167/vendor/lib(64)?/libbccQTI\.so              u:object_r:same_process_hal_file:s0
168/vendor/lib(64)?/libllvm-qcom\.so           u:object_r:same_process_hal_file:s0
169/vendor/lib(64)?/librs_adreno\.so           u:object_r:same_process_hal_file:s0
170/vendor/lib(64)?/librs_adreno_sha1\.so      u:object_r:same_process_hal_file:s0
171/vendor/lib(64)?/libqti-perfd-client\.so    u:object_r:same_process_hal_file:s0
172# perf-hal client lib (included by libqti-perfd-client.so)
173/vendor/lib(64)?/vendor\.qti\.hardware\.perf@1\.0\.so    u:object_r:same_process_hal_file:s0
174
175# libGLESv2_adreno depends on this
176/vendor/lib(64)?/libllvm-glnext\.so         u:object_r:same_process_hal_file:s0
177
178# libOpenCL-pixel and its dependencies
179/vendor/lib(64)?/libOpenCL-pixel\.so        u:object_r:same_process_hal_file:s0
180/vendor/lib(64)?/libOpenCL\.so              u:object_r:same_process_hal_file:s0
181/vendor/lib(64)?/libq3dtools_adreno\.so     u:object_r:same_process_hal_file:s0
182
183# Game profiling library
184/vendor/lib(64)?/libadreno_app_profiles\.so u:object_r:same_process_hal_file:s0
185/vendor/lib(64)?/vendor\.qti\.qspmhal@1\.0\.so    u:object_r:same_process_hal_file:s0
186
187#Loaded by native loader (zygote) for all processes
188/vendor/lib(64)?/libhalide_hexagon_host\.so u:object_r:same_process_hal_file:s0
189/vendor/lib(64)?/libadsprpc\.so             u:object_r:same_process_hal_file:s0
190/vendor/lib(64)?/libcdsprpc\.so             u:object_r:same_process_hal_file:s0
191/vendor/lib(64)?/libsdsprpc\.so             u:object_r:same_process_hal_file:s0
192/vendor/lib(64)?/vendor\.qti\.hardware\.dsp@1\.0\.so     u:object_r:same_process_hal_file:s0
193/vendor/lib(64)?/libdiag\.so                u:object_r:same_process_hal_file:s0
194/vendor/lib(64)?/libtime_genoff\.so         u:object_r:same_process_hal_file:s0
195
196# libmmi_jni
197/vendor/lib(64)?/libmmi_jni\.so             u:object_r:same_process_hal_file:s0
198
199# Fastcv libs
200/vendor/lib(64)?/libfastcvdsp_stub\.so      u:object_r:same_process_hal_file:s0
201/vendor/lib(64)?/libfastcvadsp_stub\.so     u:object_r:same_process_hal_file:s0
202/vendor/lib(64)?/libfastcvopt\.so           u:object_r:same_process_hal_file:s0
203
204# SVA files
205/vendor/lib(64)?/liblistenjni\.so          u:object_r:same_process_hal_file:s0
206/vendor/lib(64)?/liblistensoundmodel2\.so  u:object_r:same_process_hal_file:s0
207###################################
208# firmware images
209#
210
211#Android NN Driver
212/(vendor|system/vendor)/bin/hw/android\.hardware\.neuralnetworks@1\.3-service-qti u:object_r:hal_neuralnetworks_default_exec:s0
213
214# dev nodes
215/dev/ipa                                        u:object_r:ipa_dev:s0
216/dev/ipa_adpl                                   u:object_r:ipa_dev:s0
217/dev/ipa_odl_ctl                                u:object_r:ipa_dev:s0
218/dev/dpl_ctrl                                   u:object_r:rmnet_device:s0
219/dev/wwan_ioctl                                 u:object_r:ipa_dev:s0
220/dev/ipaNatTable                                u:object_r:ipa_dev:s0
221/dev/sg[0-9]+                                   u:object_r:sg_device:s0
222/dev/qseecom                                    u:object_r:tee_device:s0
223/dev/video([0-9])+                              u:object_r:video_device:s0
224/dev/media([0-9])+                              u:object_r:video_device:s0
225/dev/v4l-subdev.*                               u:object_r:video_device:s0
226/dev/jpeg[0-9]*                                 u:object_r:video_device:s0
227/dev/dri/card0                                  u:object_r:graphics_device:s0
228/dev/adsprpc-smd                                u:object_r:qdsp_device:s0
229/dev/adsprpc-smd-secure                         u:object_r:qdsp_device:s0
230/dev/kgsl-3d0                                   u:object_r:gpu_device:s0
231/dev/wlan                                       u:object_r:wlan_device:s0
232/dev/subsys_modem                               u:object_r:modem_ssr_device:s0
233/dev/diag                                       u:object_r:diag_device:s0
234/dev/btpower                                    u:object_r:hci_attach_dev:s0
235/dev/ttyHS0                                     u:object_r:hci_attach_dev:s0
236/dev/ttyMSM0                                    u:object_r:tty_device:s0
237/dev/block/sda                                  u:object_r:gpt_block_device:s0
238/dev/block/sd[bc]1?                             u:object_r:xbl_block_device:s0
239/dev/block/sde                                  u:object_r:boot_block_device:s0
240/dev/msm_.*                                     u:object_r:audio_device:s0
241/dev/ramdump_.*                                 u:object_r:ramdump_device:s0
242/dev/at_.*                                      u:object_r:at_device:s0
243/dev/smcinvoke                                  u:object_r:smcinvoke_device:s0
244/dev/qce                                        u:object_r:qce_device:s0
245
246# dev socket nodes
247/dev/socket/location(/.*)?                      u:object_r:location_socket:s0
248/dev/socket/wifihal(/.*)?                       u:object_r:wifihal_socket:s0
249
250# files in /vendor
251/vendor/bin/ipacm               u:object_r:hal_tetheroffload_default_exec:s0
252/vendor/bin/ipacm-diag          u:object_r:hal_tetheroffload_default_exec:s0
253
254# data files
255/data/vendor/ipa(/.*)?                 u:object_r:ipa_vendor_data_file:s0
256/data/vendor/sensors(/.*)?             u:object_r:sensors_vendor_data_file:s0
257/data/vendor/rfs/mpss(/.*)?            u:object_r:mpss_rfs_data_file:s0
258/data/vendor/radio(/.*)?               u:object_r:vendor_radio_data_file:s0
259/data/vendor/netmgr(/.*)?              u:object_r:netmgrd_data_file:s0
260/data/vendor/shsusr(/.*)?              u:object_r:shsusr_data_file:s0
261/data/vendor/mediadrm(/.*)?            u:object_r:mediadrm_vendor_data_file:s0
262/data/vendor/nnhal(/.*)?               u:object_r:hal_neuralnetworks_data_file:s0
263/data/vendor/ssrdump(/.*)?             u:object_r:ramdump_vendor_data_file:s0
264/data/vendor/ssrdump/coredump(/.*)?    u:object_r:sscoredump_vendor_data_coredump_file:s0
265/data/vendor/ssrlog(/.*)?              u:object_r:ssr_log_file:s0
266/data/vendor/camera(/.*)?              u:object_r:camera_vendor_data_file:s0
267/data/vendor/location(/.*)?            u:object_r:location_data_file:s0
268/data/vendor/tombstones/rfs(/.*)?      u:object_r:rfs_tombstone_data_file:s0
269/data/vendor/audio(/.*)?               u:object_r:audio_vendor_data_file:s0
270/data/vendor/display(/.*)?             u:object_r:display_vendor_data_file:s0
271/data/vendor/time(/.*)?                u:object_r:time_data_file:s0
272
273# spdaemon and sec_nvm files
274
275# cnss_diag files
276/data/vendor/wifi/cnss_diag(/.*)?               u:object_r:cnss_vendor_data_file:s0
277# iotap_ps.bin file
278/data/vendor/wifi/cnss_daemon(/.*)?             u:object_r:cnss_vendor_data_file:s0
279
280/data/vendor/connectivity(/.*)?                 u:object_r:cnd_data_file:s0
281