blob: 1ea4b65d67eea119925a8621a944aecead61ea06 [file] [log] [blame]
Avijit Kanti Das2b495d02014-10-20 17:43:13 -07001# General definitions
2type ipacm, domain;
3type ipacm-diag, domain;
4type ipacm_exec, exec_type, file_type;
5type ipacm-diag_exec, exec_type, file_type;
6init_daemon_domain(ipacm)
7init_daemon_domain(ipacm-diag)
8
Skylar Chang2c06c3a2015-03-09 12:58:40 -07009# associate netdomain to use for accessing internet sockets
10net_domain(ipacm)
11
Avijit Kanti Das2b495d02014-10-20 17:43:13 -070012userdebug_or_eng(`
13 # Allow using the logging file between ipacm and ipacm-diag
14 allow ipacm ipacm-diag:unix_dgram_socket sendto;
15 allow ipacm ipacm_socket:sock_file write;
16')
17
18# Allow capabilities to perform network operations and interactions with network interfaces
19allow ipacm kernel:system module_request;
20allow ipacm ipacm:capability net_admin;
21
22# Allow operations with /dev/ipa, /dev/wwan_ioctl and /dev/ipaNatTable
23allow ipacm ipa_dev:chr_file rw_file_perms;
24
25# Allow querying the network stack via IOCTLs
26allow ipacm ipacm:udp_socket { create ioctl };
27
28# Allow receiving NETLINK messages
29allow ipacm ipacm:netlink_route_socket { create getopt setopt bind read };
30allow ipacm ipacm:netlink_socket { create setopt bind getattr read write };
31
32# Allow creating and modifying the PID file
33allow ipacm ipacm_data_file:file create_file_perms;
34allow ipacm ipacm_data_file:dir w_dir_perms;