Move base directories to /var/games
[selinux.git] / bf1942 / bf1942.te
1 policy_module(bf1942, 0.1.7)
2
3 require {
4     type games_data_t;
5 }
6
7 # File context for the executable process
8 type bf1942_t;
9 type bf1942_exec_t;
10
11 type bf1942_rw_t;
12 files_type(bf1942_rw_t)
13
14 type bf1942_ro_t;
15 files_type(bf1942_ro_t)
16
17 init_daemon_domain(bf1942_t, bf1942_exec_t)
18 init_nnp_daemon_domain(bf1942_t, bf1942_exec_t)
19
20 corenet_udp_sendrecv_generic_port(bf1942_t)
21 corenet_udp_bind_generic_port(bf1942_t)
22 corenet_udp_bind_generic_node(bf1942_t)
23
24 read_files_pattern(bf1942_t, bf1942_ro_t, bf1942_ro_t)
25 read_lnk_files_pattern(bf1942_t, bf1942_ro_t, bf1942_ro_t)
26 list_dirs_pattern(bf1942_t, bf1942_ro_t, bf1942_ro_t)
27
28 manage_files_pattern(bf1942_t, bf1942_rw_t, bf1942_rw_t)
29 manage_dirs_pattern(bf1942_t, bf1942_rw_t, bf1942_rw_t)
30 setattr_files_pattern(bf1942_t, bf1942_rw_t, bf1942_rw_t)
31
32 sysnet_dns_name_resolve(bf1942_t)
33
34 kernel_read_system_state(bf1942_t)
35 allow bf1942_t self:process execmem;
36
37 # The BF1942 binary executes itself
38 allow bf1942_t bf1942_exec_t:file execute_no_trans;
39
40 list_dirs_pattern(bf1942_t, games_data_t, games_data_t)