1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201
|
/*
* This file contains a set of old feature files that are used under different
* circumstances.
*
* match_n_abi: feature abi for oldest match_file (pre features) abi.
*
* match_c_abi: features abi for match_file (pre features) abi that supports
* create.
*
* match_cn_abi: features abi for match_file (pre features) abi that supports
* create and network.
*
* default_features_abi: is the feature abi used when policy is not tagged
* with an abi and no featuere-abi was specified to the
* parser.
*/
#include "parser.h"
const char *match_n_abi =
"caps {mask {chown dac_override dac_read_search fowner fsetid kill setgid setuid setpcap linux_immutable net_bind_service net_broadcast net_admin net_raw ipc_lock ipc_owner sys_module sys_rawio sys_chroot sys_ptrace sys_pacct sys_admin sys_boot sys_nice sys_resource sys_time sys_tty_config mknod lease audit_write audit_control setfcap mac_override mac_admin syslog wake_alarm block_suspend audit_read\
}\
}\
rlimit {mask {cpu fsize data stack core rss nproc nofile memlock as locks sigpending msgqueue nice rtprio rttime\
}\
}\
capability {0xffffff\
}\
network {af_unix {yes\
}\
af_mask {unspec unix inet ax25 ipx appletalk netrom bridge atmpvc x25 inet6 rose netbeui security key netlink packet ash econet atmsvc rds sna irda pppox wanpipe llc ib mpls can tipc bluetooth iucv rxrpc isdn phonet ieee802154 caif alg nfc vsock kcm qipcrtr smc xdp\
}\
}\
file {mask {read write exec append mmap_exec link lock\
}\
}\
domain {change_profile {yes\
}\
change_onexec {yes\
}\
change_hatv {yes\
}\
change_hat {yes\
}\
}\
policy {\
v6 {yes\
}\
v5 {yes\
}\
}\
}\
";
/****************************** match_c_abi *******************************/
const char *match_c_abi =
"caps {mask {chown dac_override dac_read_search fowner fsetid kill setgid setuid setpcap linux_immutable net_bind_service net_broadcast net_admin net_raw ipc_lock ipc_owner sys_module sys_rawio sys_chroot sys_ptrace sys_pacct sys_admin sys_boot sys_nice sys_resource sys_time sys_tty_config mknod lease audit_write audit_control setfcap mac_override mac_admin syslog wake_alarm block_suspend audit_read\
}\
}\
rlimit {mask {cpu fsize data stack core rss nproc nofile memlock as locks sigpending msgqueue nice rtprio rttime\
}\
}\
capability {0xffffff\
}\
file {mask {create read write exec append mmap_exec link lock\
}\
}\
domain {change_profile {yes\
}\
change_onexec {yes\
}\
change_hatv {yes\
}\
change_hat {yes\
}\
}\
policy {\
v6 {yes\
}\
v5 {yes\
}\
}\
}\
";
/****************************** match_cn_abi ******************************/
const char *match_cn_abi =
"caps {mask {chown dac_override dac_read_search fowner fsetid kill setgid setuid setpcap linux_immutable net_bind_service net_broadcast net_admin net_raw ipc_lock ipc_owner sys_module sys_rawio sys_chroot sys_ptrace sys_pacct sys_admin sys_boot sys_nice sys_resource sys_time sys_tty_config mknod lease audit_write audit_control setfcap mac_override mac_admin syslog wake_alarm block_suspend audit_read\
}\
}\
rlimit {mask {cpu fsize data stack core rss nproc nofile memlock as locks sigpending msgqueue nice rtprio rttime\
}\
}\
capability {0xffffff\
}\
network {af_unix {yes\
}\
af_mask {unspec unix inet ax25 ipx appletalk netrom bridge atmpvc x25 inet6 rose netbeui security key netlink packet ash econet atmsvc rds sna irda pppox wanpipe llc ib mpls can tipc bluetooth iucv rxrpc isdn phonet ieee802154 caif alg nfc vsock kcm qipcrtr smc xdp\
}\
}\
file {mask {create read write exec append mmap_exec link lock\
}\
}\
domain {change_profile {yes\
}\
change_onexec {yes\
}\
change_hatv {yes\
}\
change_hat {yes\
}\
}\
policy {\
v6 {yes\
}\
v5 {yes\
}\
}\
}\
";
/************************** deafult_features_abi ***************************/
const char *default_features_abi =
"query {label {multi_transaction {yes\
}\
data {yes\
}\
perms {allow deny audit quiet\
}\
}\
}\
dbus {mask {acquire send receive\
}\
}\
signal {mask {hup int quit ill trap abrt bus fpe kill usr1 segv usr2 pipe alrm term stkflt chld cont stop stp ttin ttou urg xcpu xfsz vtalrm prof winch io pwr sys emt lost\
}\
}\
ptrace {mask {read trace\
}\
}\
caps {mask {chown dac_override dac_read_search fowner fsetid kill setgid setuid setpcap linux_immutable net_bind_service net_broadcast net_admin net_raw ipc_lock ipc_owner sys_module sys_rawio sys_chroot sys_ptrace sys_pacct sys_admin sys_boot sys_nice sys_resource sys_time sys_tty_config mknod lease audit_write audit_control setfcap mac_override mac_admin syslog wake_alarm block_suspend audit_read perfmon bpf\
}\
}\
rlimit {mask {cpu fsize data stack core rss nproc nofile memlock as locks sigpending msgqueue nice rtprio rttime\
}\
}\
capability {0xffffff\
}\
namespaces {pivot_root {no\
}\
profile {yes\
}\
}\
mount {mask {mount umount pivot_root\
}\
}\
network {af_unix {yes\
}\
af_mask {unspec unix inet ax25 ipx appletalk netrom bridge atmpvc x25 inet6 rose netbeui security key netlink packet ash econet atmsvc rds sna irda pppox wanpipe llc ib mpls can tipc bluetooth iucv rxrpc isdn phonet ieee802154 caif alg nfc vsock kcm qipcrtr smc xdp\
}\
}\
file {mask {create read write exec append mmap_exec link lock\
}\
}\
domain {version {1.2\
}\
}\
computed_longest_left {yes\
}\
post_nnp_subset {yes\
}\
fix_binfmt_elf_mmap {yes\
}\
stack {yes\
}\
change_profile {yes\
}\
change_onexec {yes\
}\
change_hatv {yes\
}\
change_hat {yes\
}\
}\
policy {set_load {yes\
}\
versions {v8 {yes\
}\
v7 {yes\
}\
v6 {yes\
}\
v5 {yes\
}\
}\
}\
";
|