diff options
author | netblue30 <netblue30@yahoo.com> | 2015-11-15 13:53:08 -0500 |
---|---|---|
committer | netblue30 <netblue30@yahoo.com> | 2015-11-15 13:53:08 -0500 |
commit | 2efec6d0109d38693fa8ff8f5a13713ebf0844e9 (patch) | |
tree | e5e20ddb269aaa4eba9c2bddb4ed4f1c30440f68 /test | |
parent | servers testing (diff) | |
download | firejail-2efec6d0109d38693fa8ff8f5a13713ebf0844e9.tar.gz firejail-2efec6d0109d38693fa8ff8f5a13713ebf0844e9.tar.zst firejail-2efec6d0109d38693fa8ff8f5a13713ebf0844e9.zip |
server testing
Diffstat (limited to 'test')
-rwxr-xr-x | test/servers.exp | 36 | ||||
-rwxr-xr-x | test/test-root.sh | 3 |
2 files changed, 0 insertions, 39 deletions
diff --git a/test/servers.exp b/test/servers.exp deleted file mode 100755 index 60f584919..000000000 --- a/test/servers.exp +++ /dev/null | |||
@@ -1,36 +0,0 @@ | |||
1 | #!/usr/bin/expect -f | ||
2 | |||
3 | set timeout 10 | ||
4 | spawn $env(SHELL) | ||
5 | match_max 100000 | ||
6 | |||
7 | send -- "sudo ls; sudo whoami; sudo pwd\r" | ||
8 | expect { | ||
9 | timeout {puts "TESTING ERROR: you need to root run this test as root\n";exit} | ||
10 | "root" | ||
11 | } | ||
12 | |||
13 | send -- "firejail --net=br0 --ip=10.10.20.5 --seccomp\r" | ||
14 | expect { | ||
15 | timeout {puts "TESTING ERROR 0\n";exit} | ||
16 | "Child process initialized" | ||
17 | } | ||
18 | sleep 2 | ||
19 | |||
20 | |||
21 | send -- "/etc/init.d/rsyslog start;sleep 1;/etc/init.d/ssh start\r" | ||
22 | sleep 3 | ||
23 | |||
24 | send -- "ps aux; pwd\r" | ||
25 | expect { | ||
26 | timeout {puts "TESTING ERROR 1\n";exit} | ||
27 | "rsyslogd" | ||
28 | } | ||
29 | expect { | ||
30 | timeout {puts "TESTING ERROR 2\n";exit} | ||
31 | "sshd" | ||
32 | } | ||
33 | |||
34 | send -- "exit\r" | ||
35 | sleep 1 | ||
36 | puts "\n" | ||
diff --git a/test/test-root.sh b/test/test-root.sh index 3c57532a3..ac6b2ef00 100755 --- a/test/test-root.sh +++ b/test/test-root.sh | |||
@@ -8,9 +8,6 @@ echo "TESTING: network interfaces" | |||
8 | echo "TESTING: chroot" | 8 | echo "TESTING: chroot" |
9 | ./fs_chroot_asroot.exp | 9 | ./fs_chroot_asroot.exp |
10 | 10 | ||
11 | echo "TESTING: servers rsyslogd, sshd, nginx" | ||
12 | ./servers.exp | ||
13 | |||
14 | if [ -f /etc/init.d/snmpd ] | 11 | if [ -f /etc/init.d/snmpd ] |
15 | then | 12 | then |
16 | echo "TESTING: servers snmpd, private-dev" | 13 | echo "TESTING: servers snmpd, private-dev" |