From b4e7e9475c9aeaa768bc7c023efe2e96f463fe9d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1s=20Touceda?= Date: Thu, 15 Aug 2013 12:01:20 -0300 Subject: Add LEAPOPENVPN=1 command line env var to the vpnlauncher --- changes/bug_improve_openvpn_detection | 3 +++ src/leap/bitmask/services/eip/vpnlaunchers.py | 13 +++++++++++++ 2 files changed, 16 insertions(+) create mode 100644 changes/bug_improve_openvpn_detection diff --git a/changes/bug_improve_openvpn_detection b/changes/bug_improve_openvpn_detection new file mode 100644 index 00000000..99f43a07 --- /dev/null +++ b/changes/bug_improve_openvpn_detection @@ -0,0 +1,3 @@ + o Improve OpenVPN detection by searching for a specific leap-only + string in the command line. This makes it possible to run other + VPN instances while also using EIP. Fixes #3268 and #3364. \ No newline at end of file diff --git a/src/leap/bitmask/services/eip/vpnlaunchers.py b/src/leap/bitmask/services/eip/vpnlaunchers.py index 8a127ce9..31a1c17b 100644 --- a/src/leap/bitmask/services/eip/vpnlaunchers.py +++ b/src/leap/bitmask/services/eip/vpnlaunchers.py @@ -402,6 +402,10 @@ class LinuxVPNLauncher(VPNLauncher): openvpn = first(openvpn_possibilities) args = [] + args += [ + '--setenv', "LEAPOPENVPN", "1" + ] + pkexec = self.maybe_pkexec() if pkexec: args.append(openvpn) @@ -658,6 +662,10 @@ class DarwinVPNLauncher(VPNLauncher): openvpn = first(openvpn_possibilities) args = [openvpn] + args += [ + '--setenv', "LEAPOPENVPN", "1" + ] + if openvpn_verb is not None: args += ['--verb', '%d' % (openvpn_verb,)] @@ -825,6 +833,11 @@ class WindowsVPNLauncher(VPNLauncher): openvpn = first(openvpn_possibilities) args = [] + + args += [ + '--setenv', "LEAPOPENVPN", "1" + ] + if openvpn_verb is not None: args += ['--verb', '%d' % (openvpn_verb,)] -- cgit v1.2.3