Changeset View
Changeset View
Standalone View
Standalone View
autotests/folding/usr.bin.apparmor-profile-test.fold
Show First 20 Lines • Show All 87 Lines • ▼ Show 20 Line(s) | 87 | profile hello_world <beginfold id='2'>{</beginfold id='2'> | |||
---|---|---|---|---|---|
88 | # File rules (three different ways) | 88 | # File rules (three different ways) | ||
89 | <beginfold id='1'>file</beginfold id='1'> /usr/lib{,32,64}/helloworld/**.so mr<endfold id='1'>,</endfold id='1'> | 89 | <beginfold id='1'>file</beginfold id='1'> /usr/lib{,32,64}/helloworld/**.so mr<endfold id='1'>,</endfold id='1'> | ||
90 | /usr/lib{,32,64}/helloworld/** r<endfold id='1'>,</endfold id='1'> | 90 | /usr/lib{,32,64}/helloworld/** r<endfold id='1'>,</endfold id='1'> | ||
91 | rk /usr/lib{,32,64}/helloworld/hello,file<endfold id='1'>,</endfold id='1'> | 91 | rk /usr/lib{,32,64}/helloworld/hello,file<endfold id='1'>,</endfold id='1'> | ||
92 | 92 | | |||
93 | # Link rules (two ways) | 93 | # Link rules (two ways) | ||
94 | l /foo1 -> /bar<endfold id='1'>,</endfold id='1'> | 94 | l /foo1 -> /bar<endfold id='1'>,</endfold id='1'> | ||
95 | <beginfold id='1'>link</beginfold id='1'> /foo2 -> bar<endfold id='1'>,</endfold id='1'> | 95 | <beginfold id='1'>link</beginfold id='1'> /foo2 -> bar<endfold id='1'>,</endfold id='1'> | ||
96 | <beginfold id='1'>link</beginfold id='1'> /foo3 to bar<endfold id='1'>,</endfold id='1'> | | |||
97 | <beginfold id='1'>link</beginfold id='1'> subset /link* -> /**<endfold id='1'>,</endfold id='1'> | 96 | <beginfold id='1'>link</beginfold id='1'> subset /link* -> /**<endfold id='1'>,</endfold id='1'> | ||
98 | 97 | | |||
99 | # Network rules | 98 | # Network rules | ||
100 | <beginfold id='1'>network</beginfold id='1'> inet6 tcp<endfold id='1'>,</endfold id='1'> | 99 | <beginfold id='1'>network</beginfold id='1'> inet6 tcp<endfold id='1'>,</endfold id='1'> | ||
101 | <beginfold id='1'>network</beginfold id='1'> netlink dgram<endfold id='1'>,</endfold id='1'> | 100 | <beginfold id='1'>network</beginfold id='1'> netlink dgram<endfold id='1'>,</endfold id='1'> | ||
102 | <beginfold id='1'>network</beginfold id='1'> bluetooth<endfold id='1'>,</endfold id='1'> | 101 | <beginfold id='1'>network</beginfold id='1'> bluetooth<endfold id='1'>,</endfold id='1'> | ||
103 | <beginfold id='1'>network</beginfold id='1'> unspec dgram<endfold id='1'>,</endfold id='1'> | 102 | <beginfold id='1'>network</beginfold id='1'> unspec dgram<endfold id='1'>,</endfold id='1'> | ||
104 | 103 | | |||
Show All 21 Lines | |||||
126 | <beginfold id='1'>unix</beginfold id='1'> (send,receive) type=(stream) protocol=0 peer=(addr=none)<endfold id='1'>,</endfold id='1'> | 125 | <beginfold id='1'>unix</beginfold id='1'> (send,receive) type=(stream) protocol=0 peer=(addr=none)<endfold id='1'>,</endfold id='1'> | ||
127 | <beginfold id='1'>unix</beginfold id='1'> peer=(label=@{profile_name},addr=@helloworld)<endfold id='1'>,</endfold id='1'> | 126 | <beginfold id='1'>unix</beginfold id='1'> peer=(label=@{profile_name},addr=@helloworld)<endfold id='1'>,</endfold id='1'> | ||
128 | 127 | | |||
129 | # Rlimit rule | 128 | # Rlimit rule | ||
130 | set <beginfold id='1'>rlimit</beginfold id='1'> data <= 100M<endfold id='1'>,</endfold id='1'> | 129 | set <beginfold id='1'>rlimit</beginfold id='1'> data <= 100M<endfold id='1'>,</endfold id='1'> | ||
131 | set <beginfold id='1'>rlimit</beginfold id='1'> nproc <= 10<endfold id='1'>,</endfold id='1'> | 130 | set <beginfold id='1'>rlimit</beginfold id='1'> nproc <= 10<endfold id='1'>,</endfold id='1'> | ||
132 | set <beginfold id='1'>rlimit</beginfold id='1'> memlock <= 2GB<endfold id='1'>,</endfold id='1'> | 131 | set <beginfold id='1'>rlimit</beginfold id='1'> memlock <= 2GB<endfold id='1'>,</endfold id='1'> | ||
133 | set <beginfold id='1'>rlimit</beginfold id='1'> rss <= infinity<endfold id='1'>,</endfold id='1'> | 132 | set <beginfold id='1'>rlimit</beginfold id='1'> rss <= infinity<endfold id='1'>,</endfold id='1'> | ||
133 | set <beginfold id='1'>rlimit</beginfold id='1'> nice <= -12<endfold id='1'>,</endfold id='1'> | ||||
134 | 134 | | |||
135 | # Change Profile rules | 135 | # Change Profile rules | ||
136 | <beginfold id='1'>change_profile</beginfold id='1'> unsafe /** -> [^u/]**<endfold id='1'>,</endfold id='1'> | 136 | <beginfold id='1'>change_profile</beginfold id='1'> unsafe /** -> [^u/]**<endfold id='1'>,</endfold id='1'> | ||
137 | <beginfold id='1'>change_profile</beginfold id='1'> unsafe /** -> {u,un,unc,unco,uncon,unconf,unconfi,unconfin,unconfine}<endfold id='1'>,</endfold id='1'> | 137 | <beginfold id='1'>change_profile</beginfold id='1'> unsafe /** -> {u,un,unc,unco,uncon,unconf,unconfi,unconfin,unconfine}<endfold id='1'>,</endfold id='1'> | ||
138 | <beginfold id='1'>change_profile</beginfold id='1'> /bin/bash -> | 138 | <beginfold id='1'>change_profile</beginfold id='1'> /bin/bash -> | ||
139 | new_profile//hat<endfold id='1'>,</endfold id='1'> | 139 | new_profile//hat<endfold id='1'>,</endfold id='1'> | ||
140 | <endfold id='2'>}</endfold id='2'> | 140 | <endfold id='2'>}</endfold id='2'> | ||
141 | 141 | | |||
▲ Show 20 Lines • Show All 134 Lines • Show Last 20 Lines |