aboutsummaryrefslogtreecommitdiffstats
path: root/test/apps/opera.exp
diff options
context:
space:
mode:
authorLibravatar netblue30 <netblue30@yahoo.com>2016-04-22 09:46:07 -0400
committerLibravatar netblue30 <netblue30@yahoo.com>2016-04-22 09:46:07 -0400
commit47be57441f2f49baddebaca884fc65199b234714 (patch)
tree67d975d9a2a58b1c9790caeafde9924dd20fb0e5 /test/apps/opera.exp
parentcherrytree profile fixes (diff)
downloadfirejail-47be57441f2f49baddebaca884fc65199b234714.tar.gz
firejail-47be57441f2f49baddebaca884fc65199b234714.tar.zst
firejail-47be57441f2f49baddebaca884fc65199b234714.zip
make test-apps
Diffstat (limited to 'test/apps/opera.exp')
-rwxr-xr-xtest/apps/opera.exp80
1 files changed, 80 insertions, 0 deletions
diff --git a/test/apps/opera.exp b/test/apps/opera.exp
new file mode 100755
index 000000000..23eed5504
--- /dev/null
+++ b/test/apps/opera.exp
@@ -0,0 +1,80 @@
1#!/usr/bin/expect -f
2
3set timeout 10
4spawn $env(SHELL)
5match_max 100000
6
7send -- "firejail opera www.gentoo.org\r"
8expect {
9 timeout {puts "TESTING ERROR 0\n";exit}
10 "Reading profile /etc/firejail/opera.profile"
11}
12expect {
13 timeout {puts "TESTING ERROR 1\n";exit}
14 "Child process initialized"
15}
16sleep 10
17
18spawn $env(SHELL)
19send -- "firejail --list\r"
20expect {
21 timeout {puts "TESTING ERROR 3\n";exit}
22 ":firejail"
23}
24expect {
25 timeout {puts "TESTING ERROR 3.1\n";exit}
26 "opera"
27}
28sleep 1
29
30# grsecurity exit
31send -- "file /proc/sys/kernel/grsecurity\r"
32expect {
33 timeout {puts "TESTING ERROR - grsecurity detection\n";exit}
34 "grsecurity: directory" {puts "grsecurity present, exiting...\n";exit}
35 "cannot open" {puts "grsecurity not present\n"}
36}
37
38send -- "firejail --name=blablabla\r"
39expect {
40 timeout {puts "TESTING ERROR 4\n";exit}
41 "Child process initialized"
42}
43sleep 2
44
45spawn $env(SHELL)
46send -- "firemon --seccomp\r"
47expect {
48 timeout {puts "TESTING ERROR 5\n";exit}
49 ":firejail opera"
50}
51expect {
52 timeout {puts "TESTING ERROR 5.1\n";exit}
53 "Seccomp: 0"
54}
55expect {
56 timeout {puts "TESTING ERROR 5.1\n";exit}
57 "name=blablabla"
58}
59sleep 1
60send -- "firemon --caps\r"
61expect {
62 timeout {puts "TESTING ERROR 6\n";exit}
63 ":firejail opera"
64}
65expect {
66 timeout {puts "TESTING ERROR 6.1\n";exit}
67 "CapBnd:"
68}
69expect {
70 timeout {puts "TESTING ERROR 6.2\n";exit}
71 "fffffffff"
72}
73expect {
74 timeout {puts "TESTING ERROR 6.3\n";exit}
75 "name=blablabla"
76}
77sleep 1
78
79puts "\n"
80