summaryrefslogtreecommitdiff
path: root/src/leap/bitmask/vpn/helpers
diff options
context:
space:
mode:
authorRuben Pollan <meskio@sindominio.net>2017-03-28 13:35:56 +0200
committerKali Kaneko (leap communications) <kali@leap.se>2017-04-03 15:41:19 +0200
commitef804c1fd5a8ae307aca70853c9224b63d14a731 (patch)
tree97e69bc1ca54b3dbb43e7215a15b2f5415f5dedd /src/leap/bitmask/vpn/helpers
parentb71f8be2993c887130a00390e46615c882de6655 (diff)
[feat] add a check for the installation of the helpers to the API
- Resolves: #8786
Diffstat (limited to 'src/leap/bitmask/vpn/helpers')
-rw-r--r--src/leap/bitmask/vpn/helpers/__init__.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/leap/bitmask/vpn/helpers/__init__.py b/src/leap/bitmask/vpn/helpers/__init__.py
index 8905adfd..69a9a5fb 100644
--- a/src/leap/bitmask/vpn/helpers/__init__.py
+++ b/src/leap/bitmask/vpn/helpers/__init__.py
@@ -1,5 +1,6 @@
from os import remove, chmod
from shutil import copyfile
+import os.path
import sys
from leap.bitmask.vpn.constants import IS_LINUX
@@ -21,6 +22,11 @@ if IS_LINUX:
remove(helper_to)
remove(polkit_to)
+ def check():
+ helper = os.path.exists(helper_to)
+ polkit = os.path.exists(polkit_to)
+ return helper and polkit
+
def main():
if sys.argv[-1] == 'install':