Yusin commited on
Commit
ea90641
1 Parent(s): d9923c6

Update aberconnect.sh

Browse files
Files changed (1) hide show
  1. aberconnect.sh +27 -12
aberconnect.sh CHANGED
@@ -1,12 +1,27 @@
1
- #!/bin/bash
2
- /usr/bin/expect <<EOF
3
- set timeout -1
4
- set username yuxing.chen@unitn.it
5
- set password cyx521301
6
- spawn ./openconnect --protocol=gp vpn.icts.unitn.it --user=$username
7
- expect {
8
- "Password:*" {
9
- send -- "$password\r"
10
- }
11
- }
12
- EOF
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #!/usr/bin/expect -f
2
+
3
+ set timeout -1
4
+
5
+ set username yuxing.chen@unitn.it
6
+ set password cyx521301
7
+
8
+ spawn ./openconnect --protocol=gp vpn.icts.unitn.it --user=$username
9
+
10
+ expect "Password:*"
11
+ send -- "$password\r"
12
+
13
+ expect eof
14
+
15
+
16
+ ##!/bin/bash
17
+ #/usr/bin/expect <<EOF
18
+ # set timeout -1
19
+ # set username yuxing.chen@unitn.it
20
+ # set password cyx521301
21
+ # spawn ./openconnect --protocol=gp vpn.icts.unitn.it --user=$username
22
+ # expect {
23
+ # "Password:*" {
24
+ # send -- "$password\r"
25
+ # }
26
+ # }
27
+ #EOF