blob: 7d43a5786ee8c5f9656ff1222869bd0c2cbb95db (
plain) (
blame)
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
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
|
#!/bin/bash
./chk_config.exp
echo "TESTING: default profiles installed in /etc"
PROFILES=`ls /etc/firejail/*.profile`
for PROFILE in $PROFILES
do
echo "TESTING: $PROFILE"
./test-profile.exp $PROFILE
done
./fscheck.sh
echo "TESTING: environment variables"
./env.exp
echo "TESTING: private-etc"
./private-etc.exp
echo "TESTING: private-bin"
./private-bin.exp
sleep 1
rm -fr dir\ with\ space
mkdir dir\ with\ space
echo "TESTING: blacklist"
./blacklist.exp
sleep 1
rm -fr dir\ with\ space
ln -s auto auto2
ln -s /bin auto3
ln -s /usr/bin auto4
echo "TESTING: blacklist directory link"
./blacklist-link.exp
rm -fr auto2
rm -fr auto3
rm -fr auto4
echo "TESTING: version"
./option_version.exp
echo "TESTING: help"
./option_help.exp
echo "TESTING: man"
./option_man.exp
echo "TESTING: list"
./option_list.exp
echo "TESTING: tree"
./option_tree.exp
if [ -f /proc/self/uid_map ];
then
echo "TESTING: noroot"
./noroot.exp
else
echo "TESTING: user namespaces not available"
fi
echo "TESTING: doubledash"
mkdir -- -testdir
touch -- -testdir/ttt
cp -- /bin/bash -testdir/.
./doubledash.exp
rm -fr -- -testdir
echo "TESTING: trace1"
./option-trace.exp
echo "TESTING: trace2"
rm -f index.html*
./trace.exp
rm -f index.html*
echo "TESTING: extract command"
./extract_command.exp
echo "TESTING: rlimit"
./option_rlimit.exp
echo "TESTING: shutdown"
./option-shutdown.exp
echo "TESTING: join"
./option-join.exp
echo "TESTING: firejail in firejail"
./firejail-in-firejail.exp
echo "TESTING: chroot overlay"
./option_chroot_overlay.exp
echo "TESTING: tmpfs"
./option_tmpfs.exp
echo "TESTING: blacklist directory"
./option_blacklist.exp
echo "TESTING: blacklist file"
./option_blacklist_file.exp
echo "TESTING: bind as user"
./option_bind_user.exp
if [ -d /home/bingo ];
then
echo "TESTING: home sanitize"
./option_version.exp
fi
echo "TESTING: chroot as user"
./fs_chroot.exp
echo "TESTING: /sys"
./fs_sys.exp
echo "TESTING: readonly"
ls -al > tmpreadonly
./option_readonly.exp
sleep 5
rm -f tmpreadonly
echo "TESTING: zsh"
./shell_zsh.exp
echo "TESTING: csh"
./shell_csh.exp
which dash
if [ "$?" -eq 0 ];
then
echo "TESTING: dash"
./shell_dash.exp
else
echo "TESTING: dash not found"
fi
which firefox
if [ "$?" -eq 0 ];
then
echo "TESTING: firefox"
./firefox.exp
else
echo "TESTING: firefox not found"
fi
which midori
if [ "$?" -eq 0 ];
then
echo "TESTING: midori"
./midori.exp
else
echo "TESTING: midori not found"
fi
which chromium
if [ "$?" -eq 0 ];
then
echo "TESTING: chromium"
./chromium.exp
else
echo "TESTING: chromium not found"
fi
which opera
if [ "$?" -eq 0 ];
then
echo "TESTING: opera"
./opera.exp
else
echo "TESTING: opera not found"
fi
which transmission-gtk
if [ "$?" -eq 0 ];
then
echo "TESTING: transmission-gtk"
./transmission-gtk.exp
else
echo "TESTING: transmission-gtk not found"
fi
which transmission-qt
if [ "$?" -eq 0 ];
then
echo "TESTING: transmission-qt"
./transmission-qt.exp
else
echo "TESTING: transmission-qt not found"
fi
which evince
if [ "$?" -eq 0 ];
then
echo "TESTING: evince"
./evince.exp
else
echo "TESTING: evince not found"
fi
which icedove
if [ "$?" -eq 0 ];
then
echo "TESTING: icedove"
./icedove.exp
else
echo "TESTING: icedove not found"
fi
which vlc
if [ "$?" -eq 0 ];
then
echo "TESTING: vlc"
./vlc.exp
else
echo "TESTING: vlc not found"
fi
which fbreader
if [ "$?" -eq 0 ];
then
echo "TESTING: fbreader"
./fbreader.exp
else
echo "TESTING: fbreader not found"
fi
which deluge
if [ "$?" -eq 0 ];
then
echo "TESTING: deluge"
./deluge.exp
else
echo "TESTING: deluge not found"
fi
which gnome-mplayer
if [ "$?" -eq 0 ];
then
echo "TESTING: gnome-mplayer"
./gnome-mplayer.exp
else
echo "TESTING: gnome-mplayer not found"
fi
echo "TESTING: PID"
./pid.exp
echo "TESTING: output"
./output.exp
echo "TESTING: profile no permissions"
./profile_noperm.exp
echo "TESTING: profile syntax"
./profile_syntax.exp
echo "TESTING: profile syntax 2"
./profile_syntax2.exp
echo "TESTING: profile rlimit"
./profile_rlimit.exp
echo "TESTING: profile read-only"
./profile_readonly.exp
echo "TESTING: profile tmpfs"
./profile_tmpfs.exp
echo "TESTING: profile applications"
./profile_apps.exp
echo "TESTING: private"
./private.exp `whoami`
echo "TESTING: private directory"
rm -fr dirprivate
mkdir dirprivate
./private_dir.exp
rm -fr dirprivate
echo "TESTING: private directory profile"
rm -fr dirprivate
mkdir dirprivate
./private_dir_profile.exp
rm -fr dirprivate
echo "TESTING: private keep"
./private-keep.exp
uname -r | grep "3.18"
if [ "$?" -eq 0 ];
then
echo "TESTING: overlayfs on 3.18 kernel"
./fs_overlay.exp
fi
grep "openSUSE" /etc/os-release
if [ "$?" -eq 0 ];
then
echo "TESTING: overlayfs"
./fs_overlay.exp
fi
grep "Ubuntu" /etc/os-release
if [ "$?" -eq 0 ];
then
echo "TESTING: overlayfs"
./fs_overlay.exp
fi
echo "TESTING: seccomp debug"
./seccomp-debug.exp
echo "TESTING: seccomp errno"
./seccomp-errno.exp
echo "TESTING: seccomp su"
./seccomp-su.exp
echo "TESTING: seccomp ptrace"
./seccomp-ptrace.exp
echo "TESTING: seccomp chmod - seccomp lists"
./seccomp-chmod.exp
echo "TESTING: seccomp chmod profile - seccomp lists"
./seccomp-chmod-profile.exp
echo "TESTING: seccomp empty"
./seccomp-empty.exp
echo "TESTING: seccomp bad empty"
./seccomp-bad-empty.exp
echo "TESTING: read/write /var/tmp"
./fs_var_tmp.exp
echo "TESTING: read/write /var/lock"
./fs_var_lock.exp
echo "TESTING: read/write /dev/shm"
./fs_dev_shm.exp
echo "TESTING: quiet"
./quiet.exp
echo "TESTING: local network"
./net_local.exp
echo "TESTING: no network"
./net_none.exp
echo "TESTING: network IP"
./net_ip.exp
echo "TESTING: network MAC"
./net_mac.exp
echo "TESTING: network MTU"
./net_mtu.exp
echo "TESTING: network hostname"
./hostname.exp
echo "TESTING: network bad IP"
./net_badip.exp
echo "TESTING: network no IP test 1"
./net_noip.exp
echo "TESTING: network no IP test 2"
./net_noip2.exp
echo "TESTING: network default gateway test 1"
./net_defaultgw.exp
echo "TESTING: network default gateway test 2"
./net_defaultgw2.exp
echo "TESTING: network default gateway test 3"
./net_defaultgw3.exp
echo "TESTING: netfilter"
./net_netfilter.exp
echo "TESTING: 4 bridges ARP"
./4bridges_arp.exp
echo "TESTING: 4 bridges IP"
./4bridges_ip.exp
echo "TESTING: login SSH"
./login_ssh.exp
echo "TESTING: ARP"
./net_arp.exp
echo "TESTING: DNS"
./dns.exp
echo "TESTING: firemon --arp"
./firemon-arp.exp
echo "TESTING: firemon --route"
./firemon-route.exp
echo "TESTING: firemon --seccomp"
./firemon-seccomp.exp
echo "TESTING: firemon --caps"
./firemon-caps.exp
|