Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.package.keep
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ivan Tyagov
slapos.package.keep
Commits
f3647964
Commit
f3647964
authored
Apr 26, 2013
by
Jondy Zhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
No check devcon/cscript when tap has been installed;
Add publish=yes when adding route.
parent
62333501
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
6 deletions
+8
-6
windows/scripts/ip
windows/scripts/ip
+8
-6
No files found.
windows/scripts/ip
View file @
f3647964
...
...
@@ -324,10 +324,8 @@ function install_tap_driver()
{
local
FILENAME
=
"/etc/openvpn/driver/OemWin2k.inf"
local
DEVFILE
=
$(
cygpath
-w
$FILENAME
)
local
DEVCON
=
$(
which devcon.exe
)
local
HWID
=
tap0901
local
CHECKSCRIPT
=
$(
cygpath
-m
/etc/openvpn/check_driver_signing_dialog.vbs
)
local
CSCRIPT
=
$(
which cscript
)
local
GETSCRIPT
=
$(
cygpath
-m
/etc/openvpn/get_last_connection.vbs
)
# check if ifname has been installed
...
...
@@ -344,11 +342,13 @@ function install_tap_driver()
return
1
fi
local
DEVCON
=
$(
which devcon.exe
)
if
[[
!
-x
$DEVCON
]]
;
then
echo
"Error: no devcon.exe found"
return
1
fi
local
CSCRIPT
=
$(
which cscript.exe
)
if
[[
!
-x
$CSCRIPT
]]
;
then
echo
"Error: no cscript.exe found"
return
1
...
...
@@ -425,7 +425,7 @@ function uninstall_tap_driver()
local
DEVCON
=
$(
which devcon.exe
)
local
CSCRIPT
=
$(
which cscript.exe
)
local
GETSCRIPT
=
$(
cygpath
-m
/etc/openvpn/get_pnpid_connection.vbs
)
if
[[
"
$1
"
==
""
]]
;
then
echo
"Error: missing connection name"
return
1
...
...
@@ -721,7 +721,7 @@ elif [[ $object == "route" ]] ; then
if
[[
"
$opt_family
"
==
"ipv4"
||
"
$opt_family
"
==
""
]]
;
then
# rtmroute need that the Routing and Remote Access Service is running
ipcmd
=
"netsh routing ip
$command
rtmroute"
# ipcmd="netsh routing ip $command rtmroute"
# ipcmd="netsh routing ip $command persistentroute"
if
[[
$command
==
"list"
]]
;
then
route print
...
...
@@ -733,12 +733,14 @@ elif [[ $object == "route" ]] ; then
mask
=
$(
prefix_to_netmask
$(
basename
$prefix
))
ipcmd
=
"route
$command
$address
MASK
$mask
$nexthop
"
elif
[[
"
$opt_family
"
==
"ipv6"
]]
;
then
if
[[
$command
==
"list"
]]
;
then
if
[[
$command
==
"add"
]]
;
then
publish
=
"publish=yes"
elif
[[
$command
==
"list"
]]
;
then
command
=
"show"
elif
[[
$command
==
"change"
]]
;
then
command
=
"set"
fi
ipcmd
=
"netsh interface ipv6
$command
route
$prefix
\"
$interface
\"
$nexthop
"
ipcmd
=
"netsh interface ipv6
$command
route
$prefix
\"
$interface
\"
$nexthop
$publish
"
else
echo
$orig_cmd
echo
"Error: unsupported family
\"
$opt_family
\"
"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment