blob: ffdfc8d144e2a6a00b4f9cbd1add182fd4e0fa12 [file] [log] [blame]
Divya Sharmaf4978362017-06-16 16:19:31 -07001# Copyright (c) 2017, The Linux Foundation. All rights reserved.
2#
3# Redistribution and use in source and binary forms, with or without
4# modification, are permitted provided that the following conditions are
5# met:
6# * Redistributions of source code must retain the above copyright
7# notice, this list of conditions and the following disclaimer.
8# * Redistributions in binary form must reproduce the above
9# copyright notice, this list of conditions and the following
10# disclaimer in the documentation and/or other materials provided
11# with the distribution.
12# * Neither the name of The Linux Foundation nor the names of its
13# contributors may be used to endorse or promote products derived
14# from this software without specific prior written permission.
15#
16# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED
17# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
18# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT
19# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
20# BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
21# # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
22# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
23# BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
24# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
25# OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
26# IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27
28type seempd, domain, mlstrustedsubject, coredomain;
Ravi Kumar Siddojigari8d082302018-10-15 13:07:00 -070029type seempd_exec, system_file_type, exec_type, file_type;
Divya Sharmaf4978362017-06-16 16:19:31 -070030
31init_daemon_domain(seempd)
32
Divya Sharmaf4978362017-06-16 16:19:31 -070033allow seempd seemplog_device:chr_file rw_file_perms;
34#TODO: create the dir from init.rc instead.
35allow seempd seemp_data_file:dir create_dir_perms;
36allow seempd seemp_data_file:{ file fifo_file } create_file_perms;
37
Divya Sharmaf4978362017-06-16 16:19:31 -070038#allow access to packages.list
39allow seempd system_data_file:file r_file_perms;
40
41#allow binder calls
42binder_use(seempd)
43binder_call(seempd, system_server)
44binder_call(seempd, appdomain)
45
Yida Wang826b91c2017-08-30 09:24:09 -040046allow seempd MinkBinderSvc:service_manager { find };
Yida Wang0a41d022017-08-22 18:51:39 -040047
Divya Sharmaf4978362017-06-16 16:19:31 -070048#for seemp
49allow seempd seemp_service:service_manager { find add };
50allow seempd self:binder call;
51allow seempd ion_device:chr_file r_file_perms;
52
53#for package verifier
Yida Wangbecfa822017-06-19 15:38:00 -040054allow seempd { apk_data_file apk_tmp_file apk_private_tmp_file }:dir r_dir_perms;
55allow seempd { apk_data_file apk_tmp_file apk_private_tmp_file }:file r_file_perms;
Divya Sharmaf4978362017-06-16 16:19:31 -070056allow seempd storage_file:dir r_dir_perms;
57allow seempd storage_file:lnk_file r_file_perms;
58allow seempd mnt_user_file:dir r_dir_perms;
59allow seempd mnt_user_file:lnk_file r_file_perms;
60allow seempd fuse:dir r_dir_perms;
61allow seempd fuse:file r_file_perms;
Yida Wangbecfa822017-06-19 15:38:00 -040062
63#for read network state data
64allow seempd proc_net:file r_file_perms;
Preeti Nagara48b6402018-03-29 15:51:05 +053065
66#for read of network statistics data
67allow seempd proc_qtaguid_stat:file r_file_perms;