summaryrefslogtreecommitdiff
path: root/src/leap/bitmask/vpn/service.py
diff options
context:
space:
mode:
authorKali Kaneko (leap communications) <kali@leap.se>2017-04-19 17:57:33 +0200
committerKali Kaneko (leap communications) <kali@leap.se>2017-04-19 20:14:31 +0200
commit3ebaa03a307eab2a0a4d31efd143326d6ea592b2 (patch)
tree2d91a8947e9cc7c2ca003221e27c172c69cd713d /src/leap/bitmask/vpn/service.py
parent6227a8ed9c1184eb01eca4e23cc419473e5c5b51 (diff)
[bug] stop firewall if was failed close
Diffstat (limited to 'src/leap/bitmask/vpn/service.py')
-rw-r--r--src/leap/bitmask/vpn/service.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/leap/bitmask/vpn/service.py b/src/leap/bitmask/vpn/service.py
index 026f459a..ec9e065b 100644
--- a/src/leap/bitmask/vpn/service.py
+++ b/src/leap/bitmask/vpn/service.py
@@ -93,7 +93,10 @@ class VPNService(HookableService):
if self._started:
self._vpn.stop()
self._started = False
- return {'result': 'stopped'}
+ return {'result': 'vpn stopped'}
+ elif self._vpn.is_firewall_up():
+ self._vpn.stop_firewall()
+ return {'result': 'firewall stopped'}
else:
raise Exception('VPN was not running')