diff options
author | 2023-02-28 09:51:26 -0500 | |
---|---|---|
committer | 2023-02-28 09:51:26 -0500 | |
commit | 27c4d069f322fbeca07c88e0e96208233103a5db (patch) | |
tree | fb4b4fdc75eb5e633ab55b8228a60f54176446a0 /test/ssh/login.exp | |
parent | fix cppcheck/scan-build problems (diff) | |
download | firejail-27c4d069f322fbeca07c88e0e96208233103a5db.tar.gz firejail-27c4d069f322fbeca07c88e0e96208233103a5db.tar.zst firejail-27c4d069f322fbeca07c88e0e96208233103a5db.zip |
chroot testing
Diffstat (limited to 'test/ssh/login.exp')
-rwxr-xr-x | test/ssh/login.exp | 52 |
1 files changed, 0 insertions, 52 deletions
diff --git a/test/ssh/login.exp b/test/ssh/login.exp deleted file mode 100755 index 0a05b2dd1..000000000 --- a/test/ssh/login.exp +++ /dev/null | |||
@@ -1,52 +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 -- "ssh firejail-test@0\r" | ||
11 | expect { | ||
12 | timeout {puts "TESTING ERROR 0\n";exit} | ||
13 | -re "Child process initialized in \[0-9\]+.\[0-9\]+ ms" {puts "OK\n"} | ||
14 | "an existing sandbox was detected" {puts "OK\n"} | ||
15 | } | ||
16 | sleep 1 | ||
17 | |||
18 | send -- "ps aux | wc -l\r" | ||
19 | expect { | ||
20 | timeout {puts "TESTING ERROR 1\n";exit} | ||
21 | "5" | ||
22 | } | ||
23 | after 100 | ||
24 | |||
25 | send -- "ls -l /home | grep drw | wc -l\r" | ||
26 | expect { | ||
27 | timeout {puts "TESTING ERROR 2\n";exit} | ||
28 | "1" | ||
29 | } | ||
30 | after 100 | ||
31 | |||
32 | send -- "cat /proc/self/status | grep Seccomp\r" | ||
33 | expect { | ||
34 | timeout {puts "TESTING ERROR 3\n";exit} | ||
35 | "2" | ||
36 | } | ||
37 | after 100 | ||
38 | |||
39 | send -- "cat /proc/self/status | grep CapBnd\r" | ||
40 | expect { | ||
41 | timeout {puts "TESTING ERROR 4\n";exit} | ||
42 | "0000000000000000" | ||
43 | } | ||
44 | after 100 | ||
45 | |||
46 | # preparing scp/sftp tests | ||
47 | send -- "rm testfile\r" | ||
48 | |||
49 | send -- "exit\r" | ||
50 | sleep 1 | ||
51 | |||
52 | puts "\nall done\n" | ||