diff options
Diffstat (limited to 'test/root/seccomp-chown.exp')
-rwxr-xr-x | test/root/seccomp-chown.exp | 50 |
1 files changed, 0 insertions, 50 deletions
diff --git a/test/root/seccomp-chown.exp b/test/root/seccomp-chown.exp deleted file mode 100755 index e17bbc4bb..000000000 --- a/test/root/seccomp-chown.exp +++ /dev/null | |||
@@ -1,50 +0,0 @@ | |||
1 | #!/usr/bin/expect -f | ||
2 | # This file is part of Firejail project | ||
3 | # Copyright (C) 2014-2023 Firejail Authors | ||
4 | # License GPL v2 | ||
5 | |||
6 | set timeout 10 | ||
7 | spawn $env(SHELL) | ||
8 | match_max 100000 | ||
9 | |||
10 | send -- "firejail --seccomp=chown,fchown,fchownat,lchown --private\r" | ||
11 | expect { | ||
12 | timeout {puts "TESTING ERROR 0\n";exit} | ||
13 | -re "Child process initialized in \[0-9\]+.\[0-9\]+ ms" | ||
14 | } | ||
15 | sleep 2 | ||
16 | |||
17 | send -- "stty -echo\r" | ||
18 | after 100 | ||
19 | send -- "touch testfile; echo done\r" | ||
20 | expect { | ||
21 | timeout {puts "TESTING ERROR 1\n";exit} | ||
22 | "done" | ||
23 | } | ||
24 | after 100 | ||
25 | |||
26 | send -- "ls -l testfile; echo done\r" | ||
27 | expect { | ||
28 | timeout {puts "TESTING ERROR 2\n";exit} | ||
29 | "testfile" | ||
30 | } | ||
31 | expect { | ||
32 | timeout {puts "TESTING ERROR 3\n";exit} | ||
33 | "done" | ||
34 | } | ||
35 | after 100 | ||
36 | |||
37 | send -- "chown netblue:netblue testfile; echo done\r" | ||
38 | expect { | ||
39 | timeout {puts "TESTING ERROR 2\n";exit} | ||
40 | "Bad system call" | ||
41 | } | ||
42 | expect { | ||
43 | timeout {puts "TESTING ERROR 3\n";exit} | ||
44 | "done" | ||
45 | } | ||
46 | |||
47 | |||
48 | send -- "exit\r" | ||
49 | after 100 | ||
50 | puts "\nall done\n" | ||