diff options
author | kali <kali@leap.se> | 2012-09-12 10:32:22 +0900 |
---|---|---|
committer | kali <kali@leap.se> | 2012-09-12 10:32:22 +0900 |
commit | 99058b9f6536a3717ab82a9d77b09d5489334eb5 (patch) | |
tree | 3ad3b3c32153b6d19d7a6c2b2dd17c30becc0c65 /src/leap/eip/openvpnconnection.py | |
parent | 65b953117765a88ec6fb6ba9f3b36bc1434133a4 (diff) |
add openvpn-verb option to cli.
Closes #534. accepts int [1-6] that get passed to openvpn invocation.
We should filter out the polling "state"/"status" commands from the log if
we want it to be real useful.
Diffstat (limited to 'src/leap/eip/openvpnconnection.py')
-rw-r--r-- | src/leap/eip/openvpnconnection.py | 22 |
1 files changed, 6 insertions, 16 deletions
diff --git a/src/leap/eip/openvpnconnection.py b/src/leap/eip/openvpnconnection.py index 2ab0622e..c280f70d 100644 --- a/src/leap/eip/openvpnconnection.py +++ b/src/leap/eip/openvpnconnection.py @@ -23,7 +23,8 @@ class OpenVPNConnection(Connection): of the openvpn binary """ - def __init__(self, config_file=None, + def __init__(self, + #config_file=None, watcher_cb=None, debug=False, host=None, @@ -46,8 +47,9 @@ to be triggered for each one of them. logger.debug('init openvpn connection') self.debug = debug # XXX if not host: raise ImproperlyConfigured + self.ovpn_verbosity = kwargs.get('ovpn_verbosity', None) - self.config_file = config_file + #self.config_file = config_file self.watcher_cb = watcher_cb #self.signal_maps = signal_maps @@ -58,19 +60,6 @@ to be triggered for each one of them. self.port = None self.proto = None - ################################## - # This is handled by Exception attrs - # now (see #504) - #self.missing_pkexec = False - #self.missing_auth_agent = False - - #self.bad_keyfile_perms = False - #self.missing_vpn_keyfile = False - #self.missing_provider = False - #self.missing_definition = False - #self.bad_provider = False - ################################# - #XXX workaround for signaling #the ui that we don't know how to #manage a connection error @@ -106,7 +95,8 @@ to be triggered for each one of them. try: command, args = eip_config.build_ovpn_command( debug=self.debug, - socket_path=self.host) + socket_path=self.host, + ovpn_verbosity=self.ovpn_verbosity) except eip_exceptions.EIPNoPolkitAuthAgentAvailable: command = args = None # XXX deprecate |