aboutsummaryrefslogtreecommitdiffstats
path: root/test/net_macvlan.exp
diff options
context:
space:
mode:
authorLibravatar netblue30 <netblue30@yahoo.com>2016-05-03 08:41:24 -0400
committerLibravatar netblue30 <netblue30@yahoo.com>2016-05-03 08:41:24 -0400
commit57bea6c8c4d1bd666ce57057b1cbb681b3cc4afc (patch)
tree60f90718665a1a812b552f589bc4d85616232df1 /test/net_macvlan.exp
parentMerge branch 'master' of https://github.com/netblue30/firejail (diff)
downloadfirejail-57bea6c8c4d1bd666ce57057b1cbb681b3cc4afc.tar.gz
firejail-57bea6c8c4d1bd666ce57057b1cbb681b3cc4afc.tar.zst
firejail-57bea6c8c4d1bd666ce57057b1cbb681b3cc4afc.zip
networking features testing
Diffstat (limited to 'test/net_macvlan.exp')
-rwxr-xr-xtest/net_macvlan.exp88
1 files changed, 0 insertions, 88 deletions
diff --git a/test/net_macvlan.exp b/test/net_macvlan.exp
deleted file mode 100755
index 20d022de9..000000000
--- a/test/net_macvlan.exp
+++ /dev/null
@@ -1,88 +0,0 @@
1#!/usr/bin/expect -f
2
3set timeout 10
4spawn $env(SHELL)
5match_max 100000
6
7# check the existing address
8spawn $env(SHELL)
9send -- "firejail --net=eth0 --ip=192.168.1.60\r"
10expect {
11 timeout {puts "TESTING ERROR 1.1\n";puts "Please open a sandbox on 192.168.1.60\n";exit}
12 "the address 192.168.1.60 is already in use"
13}
14
15
16
17# grab 30 ip addresses
18set MAXi 229
19set i 200
20while { $i <= $MAXi } {
21 spawn $env(SHELL)
22 send -- "firejail --net=eth0 --ip=192.168.1.$i\r"
23 expect {
24 timeout {puts "TESTING ERROR 0\n";exit}
25 "Child process initialized"
26 }
27 incr i
28 after 100
29}
30
31
32# check an existing address
33spawn $env(SHELL)
34send -- "firejail --net=eth0 --ip=192.168.1.200\r"
35expect {
36 timeout {puts "TESTING ERROR 1\n";exit}
37 "the address 192.168.1.200 is already in use"
38}
39
40
41set MAXi 254
42set i 2
43while { $i <= $MAXi } {
44 spawn $env(SHELL)
45 send -- "firejail --net=eth0\r"
46 expect {
47 timeout {puts "TESTING ERROR 2.1\n";exit}
48 "192.168.1.60" {puts "TESTING ERROR 2.2\n";exit}
49 "192.168.1.200" {puts "TESTING ERROR 3\n";exit}
50 "192.168.1.201" {puts "TESTING ERROR 3\n";exit}
51 "192.168.1.202" {puts "TESTING ERROR 3\n";exit}
52 "192.168.1.203" {puts "TESTING ERROR 3\n";exit}
53 "192.168.1.204" {puts "TESTING ERROR 3\n";exit}
54 "192.168.1.205" {puts "TESTING ERROR 3\n";exit}
55 "192.168.1.206" {puts "TESTING ERROR 3\n";exit}
56 "192.168.1.207" {puts "TESTING ERROR 3\n";exit}
57 "192.168.1.208" {puts "TESTING ERROR 3\n";exit}
58 "192.168.1.209" {puts "TESTING ERROR 3\n";exit}
59 "192.168.1.210" {puts "TESTING ERROR 3\n";exit}
60 "192.168.1.211" {puts "TESTING ERROR 3\n";exit}
61 "192.168.1.212" {puts "TESTING ERROR 3\n";exit}
62 "192.168.1.213" {puts "TESTING ERROR 3\n";exit}
63 "192.168.1.214" {puts "TESTING ERROR 3\n";exit}
64 "192.168.1.215" {puts "TESTING ERROR 3\n";exit}
65 "192.168.1.216" {puts "TESTING ERROR 3\n";exit}
66 "192.168.1.217" {puts "TESTING ERROR 3\n";exit}
67 "192.168.1.218" {puts "TESTING ERROR 3\n";exit}
68 "192.168.1.219" {puts "TESTING ERROR 3\n";exit}
69 "192.168.1.220" {puts "TESTING ERROR 3\n";exit}
70 "192.168.1.221" {puts "TESTING ERROR 3\n";exit}
71 "192.168.1.222" {puts "TESTING ERROR 3\n";exit}
72 "192.168.1.223" {puts "TESTING ERROR 3\n";exit}
73 "192.168.1.224" {puts "TESTING ERROR 3\n";exit}
74 "192.168.1.225" {puts "TESTING ERROR 3\n";exit}
75 "192.168.1.226" {puts "TESTING ERROR 3\n";exit}
76 "192.168.1.227" {puts "TESTING ERROR 3\n";exit}
77 "192.168.1.228" {puts "TESTING ERROR 3\n";exit}
78 "192.168.1.229" {puts "TESTING ERROR 3\n";exit}
79 "Child process initialized"
80 }
81 puts "************ $i ******************\n"
82 incr i
83 after 100
84# sleep 1
85}
86
87puts "\n"
88