Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
R
re6stnet
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
2
Issues
2
List
Boards
Labels
Milestones
Merge Requests
4
Merge Requests
4
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
re6stnet
Commits
6a9571a9
Commit
6a9571a9
authored
Apr 26, 2013
by
Jondy Zhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add all tap-drivers at startup;
Add subnet route at artup; Remove --persist-tun for openvpn;
parent
e599e3aa
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
3 deletions
+11
-3
re6st/plib.py
re6st/plib.py
+1
-1
re6stnet
re6stnet
+10
-2
No files found.
re6st/plib.py
View file @
6a9571a9
...
...
@@ -10,7 +10,7 @@ def openvpn(iface, encrypt, *args, **kw):
args
=
[
'openvpn'
,
'--dev-type'
,
'tap'
,
'--dev-node'
if
sys
.
platform
==
'cygwin'
else
'--dev'
,
iface
,
'--persist-tun'
,
'
'
if
sys
.
platform
==
'cygwin'
else
'
--persist-tun'
,
'--persist-key'
,
'--script-security'
,
'2'
,
'--up'
,
ovpn_client
,
...
...
re6stnet
View file @
6a9571a9
...
...
@@ -270,8 +270,11 @@ def main():
# WKRD: Removed this useless route now, since the kernel does
# not even remove it on exit.
subprocess
.
call
(
if_rt
)
if_rt
[
4
]
=
my_subnet
cleanup
.
append
(
lambda
:
subprocess
.
call
(
if_rt
))
if_rt
[
4
]
=
my_subnet
if
sys
.
platform
==
'cygwin'
:
ip
(
'route'
,
my_subnet
,
'dev'
,
config
.
main_interface
)
else
:
cleanup
.
append
(
lambda
:
subprocess
.
call
(
if_rt
))
x
=
[
my_network
]
if
config
.
table
:
x
+=
'table'
,
str
(
config
.
table
)
...
...
@@ -302,6 +305,11 @@ def main():
for
cmd
in
config
.
daemon
or
():
cleanup
.
append
(
utils
.
Popen
(
cmd
,
shell
=
True
).
stop
)
# adding tap-windows driver will break others, so we add
# all drivers here
if
sys
.
platform
==
'cygwin'
:
[
ip
(
'vpntap'
,
'dev'
,
x
)
for
x
in
tunnel_interfaces
]
# main loop
if
tunnel_manager
is
None
:
sys
.
exit
(
os
.
WEXITSTATUS
(
os
.
wait
()[
1
]))
...
...
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