aboutsummaryrefslogtreecommitdiffstats
path: root/test/root/login_nobody.exp
diff options
context:
space:
mode:
Diffstat (limited to 'test/root/login_nobody.exp')
-rwxr-xr-xtest/root/login_nobody.exp35
1 files changed, 35 insertions, 0 deletions
diff --git a/test/root/login_nobody.exp b/test/root/login_nobody.exp
new file mode 100755
index 000000000..8e9ec4367
--- /dev/null
+++ b/test/root/login_nobody.exp
@@ -0,0 +1,35 @@
1#!/usr/bin/expect -f
2# This file is part of Firejail project
3# Copyright (C) 2014-2018 Firejail Authors
4# License GPL v2
5
6set timeout 10
7cd /home
8spawn $env(SHELL)
9match_max 100000
10
11send -- "su - nobody -s /usr/bin/firejail\r"
12expect {
13 timeout {puts "TESTING ERROR 0\n";exit}
14 "Child process initialized"
15}
16after 100
17
18send -- "cat /proc/self/status | grep Seccomp\r"
19expect {
20 timeout {puts "TESTING ERROR 3\n";exit}
21 "2"
22}
23after 100
24
25send -- "cat /proc/self/status | grep CapBnd\r"
26expect {
27 timeout {puts "TESTING ERROR 4\n";exit}
28 "0000000000000000"
29}
30after 100
31
32send -- "exit\r"
33sleep 1
34
35puts "\nall done\n"