aboutsummaryrefslogtreecommitdiffstats
path: root/test/features/3.7.exp
diff options
context:
space:
mode:
Diffstat (limited to 'test/features/3.7.exp')
-rwxr-xr-xtest/features/3.7.exp95
1 files changed, 0 insertions, 95 deletions
diff --git a/test/features/3.7.exp b/test/features/3.7.exp
deleted file mode 100755
index f7f5fa67f..000000000
--- a/test/features/3.7.exp
+++ /dev/null
@@ -1,95 +0,0 @@
1#!/usr/bin/expect -f
2# This file is part of Firejail project
3# Copyright (C) 2014-2023 Firejail Authors
4# License GPL v2
5#
6# private-tmp
7#
8
9set timeout 10
10spawn $env(SHELL)
11match_max 100000
12set overlay [lindex $argv 0]
13set chroot [lindex $argv 1]
14
15#
16# N
17#
18send -- "touch /tmp/test1\r"
19sleep 1
20send -- "touch /tmp/test2\r"
21sleep 1
22send -- "firejail --noprofile --private-tmp\r"
23expect {
24 timeout {puts "TESTING ERROR 0\n";exit}
25 -re "Child process initialized in \[0-9\]+.\[0-9\]+ ms"
26}
27sleep 1
28
29send -- "ls -al /tmp | wc -l\r"
30expect {
31 timeout {puts "TESTING ERROR 1.1\n";exit}
32 "3"
33}
34
35
36after 100
37send -- "exit\r"
38sleep 1
39
40#
41# O
42#
43if { $overlay == "overlay" } {
44 send -- "touch /tmp/test1\r"
45 sleep 1
46 send -- "touch /tmp/test2\r"
47 sleep 1
48 send -- "firejail --noprofile --overlay --private-tmp\r"
49 expect {
50 timeout {puts "TESTING ERROR 2\n";exit}
51 "overlay option is not available" {puts "grsecurity\n"; exit}
52 -re "Child process initialized in \[0-9\]+.\[0-9\]+ ms" {puts "normal system\n"}
53 }
54 sleep 1
55
56 send -- "ls -al /tmp | wc -l\r"
57 expect {
58 timeout {puts "TESTING ERROR 3.1\n";exit}
59 "3"
60 }
61
62
63 after 100
64 send -- "exit\r"
65 sleep 1
66}
67
68#
69# C
70#
71if { $chroot == "chroot" } {
72 send -- "touch /tmp/test1\r"
73 sleep 1
74 send -- "touch /tmp/test2\r"
75 sleep 1
76 send -- "firejail --noprofile --chroot=/tmp/chroot --private-tmp\r"
77 expect {
78 timeout {puts "TESTING ERROR 4\n";exit}
79 -re "Child process initialized in \[0-9\]+.\[0-9\]+ ms"
80 }
81 sleep 1
82
83 send -- "ls -al /tmp | wc -l\r"
84 expect {
85 timeout {puts "TESTING ERROR 5.1\n";exit}
86 "3"
87 }
88
89 after 100
90 send -- "exit\r"
91 sleep 1
92}
93
94
95puts "\nall done\n"