diff options
Diffstat (limited to 'test/features')
-rwxr-xr-x | test/features/1.2.exp | 30 | ||||
-rwxr-xr-x | test/features/1.8.exp | 18 | ||||
-rwxr-xr-x | test/features/3.5.exp | 10 | ||||
-rwxr-xr-x | test/features/3.6.exp | 11 | ||||
-rwxr-xr-x | test/features/3.8.exp | 8 |
5 files changed, 34 insertions, 43 deletions
diff --git a/test/features/1.2.exp b/test/features/1.2.exp index 6f7cae888..bcb227304 100755 --- a/test/features/1.2.exp +++ b/test/features/1.2.exp | |||
@@ -34,7 +34,7 @@ expect { | |||
34 | } | 34 | } |
35 | expect { | 35 | expect { |
36 | timeout {puts "TESTING ERROR 1.4\n";exit} | 36 | timeout {puts "TESTING ERROR 1.4\n";exit} |
37 | "proc /proc/sysrq-trigger proc" | 37 | "/proc/sysrq-trigger" |
38 | } | 38 | } |
39 | #expect { | 39 | #expect { |
40 | # timeout {puts "TESTING ERROR 1.5\n";exit} | 40 | # timeout {puts "TESTING ERROR 1.5\n";exit} |
@@ -42,11 +42,11 @@ expect { | |||
42 | #} | 42 | #} |
43 | expect { | 43 | expect { |
44 | timeout {puts "TESTING ERROR 1.6\n";exit} | 44 | timeout {puts "TESTING ERROR 1.6\n";exit} |
45 | "proc /proc/irq proc" | 45 | "/proc/irq" |
46 | } | 46 | } |
47 | expect { | 47 | expect { |
48 | timeout {puts "TESTING ERROR 1.7\n";exit} | 48 | timeout {puts "TESTING ERROR 1.7\n";exit} |
49 | "proc /proc/bus proc" | 49 | "/proc/bus" |
50 | } | 50 | } |
51 | after 100 | 51 | after 100 |
52 | send -- "exit\r" | 52 | send -- "exit\r" |
@@ -115,22 +115,22 @@ if { $chroot == "chroot" } { | |||
115 | timeout {puts "TESTING ERROR 5.3\n";exit} | 115 | timeout {puts "TESTING ERROR 5.3\n";exit} |
116 | "proc /proc/sys proc" | 116 | "proc /proc/sys proc" |
117 | } | 117 | } |
118 | expect { | 118 | # expect { |
119 | timeout {puts "TESTING ERROR 5.4\n";exit} | 119 | # timeout {puts "TESTING ERROR 5.4\n";exit} |
120 | "proc /proc/sysrq-trigger proc" | 120 | # "proc /proc/sysrq-trigger proc" |
121 | } | 121 | # } |
122 | # expect { | 122 | # expect { |
123 | # timeout {puts "TESTING ERROR 5.5\n";exit} | 123 | # timeout {puts "TESTING ERROR 5.5\n";exit} |
124 | # "proc /proc/sys/kernel/hotplug" | 124 | # "proc /proc/sys/kernel/hotplug" |
125 | # } | 125 | # } |
126 | expect { | 126 | # expect { |
127 | timeout {puts "TESTING ERROR 5.6\n";exit} | 127 | # timeout {puts "TESTING ERROR 5.6\n";exit} |
128 | "proc /proc/irq proc" | 128 | # "proc /proc/irq proc" |
129 | } | 129 | # } |
130 | expect { | 130 | # expect { |
131 | timeout {puts "TESTING ERROR 5.7\n";exit} | 131 | # timeout {puts "TESTING ERROR 5.7\n";exit} |
132 | "proc /proc/bus proc" | 132 | # "proc /proc/bus proc" |
133 | } | 133 | # } |
134 | after 100 | 134 | after 100 |
135 | send -- "exit\r" | 135 | send -- "exit\r" |
136 | sleep 1 | 136 | sleep 1 |
diff --git a/test/features/1.8.exp b/test/features/1.8.exp index 493a87328..4c6d3f3dc 100755 --- a/test/features/1.8.exp +++ b/test/features/1.8.exp | |||
@@ -20,12 +20,6 @@ expect { | |||
20 | } | 20 | } |
21 | sleep 1 | 21 | sleep 1 |
22 | 22 | ||
23 | send -- "ls /etc/firejail\r" | ||
24 | expect { | ||
25 | timeout {puts "TESTING ERROR 1\n";exit} | ||
26 | "Permission denied" | ||
27 | } | ||
28 | after 100 | ||
29 | send -- "ls ~/.config/firejail\r" | 23 | send -- "ls ~/.config/firejail\r" |
30 | expect { | 24 | expect { |
31 | timeout {puts "TESTING ERROR 1.1\n";exit} | 25 | timeout {puts "TESTING ERROR 1.1\n";exit} |
@@ -77,12 +71,6 @@ if { $overlay == "overlay" } { | |||
77 | "Child process initialized" {puts "normal system\n"} | 71 | "Child process initialized" {puts "normal system\n"} |
78 | } | 72 | } |
79 | sleep 1 | 73 | sleep 1 |
80 | send -- "ls /etc/firejail\r" | ||
81 | expect { | ||
82 | timeout {puts "TESTING ERROR 3\n";exit} | ||
83 | "Permission denied" | ||
84 | } | ||
85 | after 100 | ||
86 | send -- "ls ~/.config/firejail\r" | 74 | send -- "ls ~/.config/firejail\r" |
87 | expect { | 75 | expect { |
88 | timeout {puts "TESTING ERROR 3.1\n";exit} | 76 | timeout {puts "TESTING ERROR 3.1\n";exit} |
@@ -134,12 +122,6 @@ if { $chroot == "chroot" } { | |||
134 | "Child process initialized" | 122 | "Child process initialized" |
135 | } | 123 | } |
136 | sleep 1 | 124 | sleep 1 |
137 | send -- "ls /etc/firejail\r" | ||
138 | expect { | ||
139 | timeout {puts "TESTING ERROR 5\n";exit} | ||
140 | "Permission denied" | ||
141 | } | ||
142 | after 100 | ||
143 | send -- "ls ~/.config/firejail\r" | 125 | send -- "ls ~/.config/firejail\r" |
144 | expect { | 126 | expect { |
145 | timeout {puts "TESTING ERROR 5.1\n";exit} | 127 | timeout {puts "TESTING ERROR 5.1\n";exit} |
diff --git a/test/features/3.5.exp b/test/features/3.5.exp index aed5fe836..f4b544b3d 100755 --- a/test/features/3.5.exp +++ b/test/features/3.5.exp | |||
@@ -22,8 +22,8 @@ sleep 1 | |||
22 | send -- "ls -l /dev | wc -l\r" | 22 | send -- "ls -l /dev | wc -l\r" |
23 | expect { | 23 | expect { |
24 | timeout {puts "TESTING ERROR 1.1\n";exit} | 24 | timeout {puts "TESTING ERROR 1.1\n";exit} |
25 | "12" { puts "Debian\n"} | 25 | "13" { puts "Debian\n"} |
26 | "11" { puts "Centos\n"} | 26 | "12" { puts "Centos\n"} |
27 | } | 27 | } |
28 | 28 | ||
29 | after 100 | 29 | after 100 |
@@ -45,8 +45,8 @@ if { $overlay == "overlay" } { | |||
45 | send -- "ls -l /dev | wc -l\r" | 45 | send -- "ls -l /dev | wc -l\r" |
46 | expect { | 46 | expect { |
47 | timeout {puts "TESTING ERROR 3.1\n";exit} | 47 | timeout {puts "TESTING ERROR 3.1\n";exit} |
48 | "12" { puts "Debian\n"} | 48 | "13" { puts "Debian\n"} |
49 | "11" { puts "Centos\n"} | 49 | "12" { puts "Centos\n"} |
50 | } | 50 | } |
51 | 51 | ||
52 | after 100 | 52 | after 100 |
@@ -68,7 +68,7 @@ if { $chroot == "chroot" } { | |||
68 | send -- "ls -l /dev | wc -l\r" | 68 | send -- "ls -l /dev | wc -l\r" |
69 | expect { | 69 | expect { |
70 | timeout {puts "TESTING ERROR 5.1\n";exit} | 70 | timeout {puts "TESTING ERROR 5.1\n";exit} |
71 | "11" | 71 | "12" |
72 | } | 72 | } |
73 | 73 | ||
74 | after 100 | 74 | after 100 |
diff --git a/test/features/3.6.exp b/test/features/3.6.exp index a00517716..389e63a1d 100755 --- a/test/features/3.6.exp +++ b/test/features/3.6.exp | |||
@@ -60,14 +60,19 @@ if { $chroot == "chroot" } { | |||
60 | expect { | 60 | expect { |
61 | timeout {puts "TESTING ERROR 4\n";exit} | 61 | timeout {puts "TESTING ERROR 4\n";exit} |
62 | "chroot option is not available" {puts "grsecurity\n"; exit} | 62 | "chroot option is not available" {puts "grsecurity\n"; exit} |
63 | "private-etc feature is disabled in chroot" | ||
64 | } | ||
65 | expect { | ||
66 | timeout {puts "TESTING ERROR 5\n";exit} | ||
67 | "chroot option is not available" {puts "grsecurity\n"; exit} | ||
63 | "Child process initialized" | 68 | "Child process initialized" |
64 | } | 69 | } |
65 | sleep 1 | 70 | sleep 1 |
66 | 71 | ||
67 | send -- "ls -al /etc | wc -l\r" | 72 | send -- "ls /etc | grep firejail\r" |
68 | expect { | 73 | expect { |
69 | timeout {puts "TESTING ERROR 5.1\n";exit} | 74 | timeout {puts "TESTING ERROR 6\n";exit} |
70 | "10" | 75 | "firejail" |
71 | } | 76 | } |
72 | 77 | ||
73 | after 100 | 78 | after 100 |
diff --git a/test/features/3.8.exp b/test/features/3.8.exp index 94a1abf67..d941fa9b7 100755 --- a/test/features/3.8.exp +++ b/test/features/3.8.exp | |||
@@ -61,14 +61,18 @@ if { $chroot == "chroot" } { | |||
61 | send -- "firejail --noprofile --chroot=/tmp/chroot --private-bin=bash,cat,cp,ls,wc\r" | 61 | send -- "firejail --noprofile --chroot=/tmp/chroot --private-bin=bash,cat,cp,ls,wc\r" |
62 | expect { | 62 | expect { |
63 | timeout {puts "TESTING ERROR 4\n";exit} | 63 | timeout {puts "TESTING ERROR 4\n";exit} |
64 | "private-bin feature is disabled in chroot" | ||
65 | } | ||
66 | expect { | ||
67 | timeout {puts "TESTING ERROR 5\n";exit} | ||
64 | "Child process initialized" | 68 | "Child process initialized" |
65 | } | 69 | } |
66 | sleep 1 | 70 | sleep 1 |
67 | 71 | ||
68 | send -- "ls -l /usr/bin | wc -l\r" | 72 | send -- "ls -l /usr/bin | wc -l\r" |
69 | expect { | 73 | expect { |
70 | timeout {puts "TESTING ERROR 5.1\n";exit} | 74 | timeout {puts "TESTING ERROR 6\n";exit} |
71 | "6" | 75 | "9" |
72 | } | 76 | } |
73 | 77 | ||
74 | after 100 | 78 | after 100 |