diff options
author | netblue30 <netblue30@yahoo.com> | 2015-08-08 19:12:30 -0400 |
---|---|---|
committer | netblue30 <netblue30@yahoo.com> | 2015-08-08 19:12:30 -0400 |
commit | 1379851360349d6617ad32944a25ee5e2bb74fc2 (patch) | |
tree | f69b48e90708bfa3c2723d5a27ed3e024c827b43 /test/firefox.exp | |
parent | delete files (diff) | |
download | firejail-1379851360349d6617ad32944a25ee5e2bb74fc2.tar.gz firejail-1379851360349d6617ad32944a25ee5e2bb74fc2.tar.zst firejail-1379851360349d6617ad32944a25ee5e2bb74fc2.zip |
Baseline firejail 0.9.28
Diffstat (limited to 'test/firefox.exp')
-rwxr-xr-x | test/firefox.exp | 74 |
1 files changed, 74 insertions, 0 deletions
diff --git a/test/firefox.exp b/test/firefox.exp new file mode 100755 index 000000000..c2e64e04f --- /dev/null +++ b/test/firefox.exp | |||
@@ -0,0 +1,74 @@ | |||
1 | #!/usr/bin/expect -f | ||
2 | |||
3 | set timeout 10 | ||
4 | spawn $env(SHELL) | ||
5 | match_max 100000 | ||
6 | |||
7 | send -- "firejail firefox www.gentoo.org\r" | ||
8 | expect { | ||
9 | timeout {puts "TESTING ERROR 0\n";exit} | ||
10 | "Reading profile /etc/firejail/firefox.profile" | ||
11 | } | ||
12 | expect { | ||
13 | timeout {puts "TESTING ERROR 1\n";exit} | ||
14 | "Child process initialized" | ||
15 | } | ||
16 | sleep 10 | ||
17 | |||
18 | spawn $env(SHELL) | ||
19 | send -- "firejail --list\r" | ||
20 | expect { | ||
21 | timeout {puts "TESTING ERROR 3\n";exit} | ||
22 | ":firejail" | ||
23 | } | ||
24 | expect { | ||
25 | timeout {puts "TESTING ERROR 3.1\n";exit} | ||
26 | "firefox" {puts "firefox detected\n";} | ||
27 | "iceweasel" {puts "iceweasel detected\n";} | ||
28 | } | ||
29 | sleep 1 | ||
30 | send -- "firejail --name=blablabla\r" | ||
31 | expect { | ||
32 | timeout {puts "TESTING ERROR 4\n";exit} | ||
33 | "Child process initialized" | ||
34 | } | ||
35 | sleep 2 | ||
36 | |||
37 | spawn $env(SHELL) | ||
38 | send -- "firemon --seccomp\r" | ||
39 | expect { | ||
40 | timeout {puts "TESTING ERROR 5\n";exit} | ||
41 | " firefox" {puts "firefox detected\n";} | ||
42 | " iceweasel" {puts "iceweasel detected\n";} | ||
43 | } | ||
44 | expect { | ||
45 | timeout {puts "TESTING ERROR 5.1 (seccomp)\n";exit} | ||
46 | "Seccomp: 2" | ||
47 | } | ||
48 | expect { | ||
49 | timeout {puts "TESTING ERROR 5.1\n";exit} | ||
50 | "name=blablabla" | ||
51 | } | ||
52 | sleep 1 | ||
53 | send -- "firemon --caps\r" | ||
54 | expect { | ||
55 | timeout {puts "TESTING ERROR 6\n";exit} | ||
56 | " firefox" {puts "firefox detected\n";} | ||
57 | " iceweasel" {puts "iceweasel detected\n";} | ||
58 | } | ||
59 | expect { | ||
60 | timeout {puts "TESTING ERROR 6.1\n";exit} | ||
61 | "CapBnd:" | ||
62 | } | ||
63 | expect { | ||
64 | timeout {puts "TESTING ERROR 6.2\n";exit} | ||
65 | "0000000000000000" | ||
66 | } | ||
67 | expect { | ||
68 | timeout {puts "TESTING ERROR 6.3\n";exit} | ||
69 | "name=blablabla" | ||
70 | } | ||
71 | sleep 1 | ||
72 | |||
73 | puts "\n" | ||
74 | |||