blob: 9863e9a8cf6d1fda49e85dc256ae54588da8e815 [file] [log] [blame]
Ravi Kumar Siddojigari5c426bf2014-09-08 20:57:41 +05301# Adding allow rule for search on /fuse
Avijit Kanti Das441bad42015-05-12 14:07:41 -07002allow init fuse:dir { search mounton };
Avijit Kanti Dasd01b3b32014-10-21 10:30:09 -07003allow init self:capability sys_module;
Avijit Kanti Das19272f32015-08-10 14:30:34 -07004allow init {
5 adsprpcd_file
6 cache_file
7 persist_file
8 storage_file
9}:dir mounton;
10allow init kmsg_device:chr_file write;
Avijit Kanti Dasfec952f2015-08-14 15:39:51 -070011
Sivan Reinsteinc2365272016-03-01 12:48:52 -080012#Allow triggering IPA FWs loading
13allow init ipa_dev:chr_file write;
14
William Clark2c0774d2015-09-25 14:14:52 -070015#For insmod to search module key for signature verification
16allow init kernel:key search;
17
Avijit Kanti Dasfec952f2015-08-14 15:39:51 -070018#For sdcard
19allow init tmpfs:lnk_file create_file_perms;
Sanket Khidkikar2e10de32015-10-05 20:26:00 -070020
21#Certain domains needs LD_PRELOAD passed from init
22#allow it for most domain. Do not honor LD_PRELOAD
23#for lmkd
Divya Sharmad8172c12017-01-20 14:29:16 -080024#allow init { domain -lmkd }:process noatsecure;
Mayank Ranab7e7fad2016-04-28 12:09:33 -070025
26#For configfs file permission
27allow init configfs:dir r_dir_perms;
Bhasker Reddy Komatireddy181d6392017-11-10 12:19:17 +053028allow init configfs:file { create_file_perms link };
Harshal Trivedid057af12016-06-02 15:24:59 -070029allow init configfs:lnk_file create_file_perms;
Ameya Thakur992e1f72016-09-22 16:26:35 -070030
31#Allow init to mount non-hlos partitions in A/B builds
32allow init firmware_file:dir { mounton };
33allow init bt_firmware_file:dir { mounton };
Biswajit Paul22cbbd82016-09-21 15:05:19 -070034
Paresh Purabhiya9c8461b2017-12-20 20:25:15 +053035allow init sysfs_boot_adsp:file w_file_perms;
Bharath Gopal8788d5a2018-03-21 18:29:10 +053036allow init sysfs_graphics:file setattr;
Paresh Purabhiya9c8461b2017-12-20 20:25:15 +053037
Biswajit Paul22cbbd82016-09-21 15:05:19 -070038#dontaudit non configfs usb denials
39dontaudit init sysfs:dir write;
Biswajit Paulf63bd142017-03-16 16:41:02 -070040
Rajiv Ranjan522565c2017-06-22 12:42:45 +053041#load /vendor/lib/modules/qca_cld3/qca_cld3_wlan.ko
Lior David4420cfc2017-05-23 10:40:44 +030042#load /vendor/lib/modules/wil6210.ko
Rajiv Ranjan522565c2017-06-22 12:42:45 +053043allow init vendor_file:system module_load;
Ameya Thakurb9523d22017-05-24 16:19:11 -070044
45#Needed for restorecon. Init already has these permissions
46#for generic block devices, but is unable to access those
47#which have a custom lable added by us.
48allow init {
49 custom_ab_block_device
50 boot_block_device
51 xbl_block_device
52 ssd_device
53 modem_block_device
54 mdtp_device
55}:{ blk_file lnk_file } relabelto;
Clarence Wong689108c2017-04-07 15:28:30 -070056
57#rawdump
58allow init rawdump_block_device:blk_file setattr;
Bhasker Reddy Komatireddy181d6392017-11-10 12:19:17 +053059
60#cpu.rt_period_us and _runtime_us need this
61allow init cgroup:file create;
Nicholas Lima2eb2492019-10-18 01:53:15 +080062
63# Allow init to bind mount loader config for media swcodec
64allow init system_file:file mounton;