summaryrefslogtreecommitdiff
path: root/wrappers/python
diff options
context:
space:
mode:
Diffstat (limited to 'wrappers/python')
-rw-r--r--wrappers/python/src/__init__.py1
-rw-r--r--wrappers/python/src/main.py8
2 files changed, 9 insertions, 0 deletions
diff --git a/wrappers/python/src/__init__.py b/wrappers/python/src/__init__.py
index ed6fcc7..1e42bb5 100644
--- a/wrappers/python/src/__init__.py
+++ b/wrappers/python/src/__init__.py
@@ -77,6 +77,7 @@ lib.GetDiscoServers.argtypes, lib.GetDiscoServers.restype = [c_char_p], DataErro
lib.GoBack.argtypes, lib.GoBack.restype = [c_char_p], None
lib.CancelOAuth.argtypes, lib.CancelOAuth.restype = [c_char_p], c_void_p
lib.SetProfileID.argtypes, lib.SetProfileID.restype = [c_char_p, c_char_p], c_void_p
+lib.ChangeSecureLocation.argtypes, lib.ChangeSecureLocation.restype = [c_char_p], c_void_p
lib.SetSecureLocation.argtypes, lib.SetSecureLocation.restype = [
c_char_p,
c_char_p,
diff --git a/wrappers/python/src/main.py b/wrappers/python/src/main.py
index 87d2b53..784e622 100644
--- a/wrappers/python/src/main.py
+++ b/wrappers/python/src/main.py
@@ -187,6 +187,14 @@ class EduVPN(object):
if profile_err:
raise Exception(profile_err)
+ def change_secure_location(self) -> None:
+ # Set the location by country code
+ self.location_event = threading.Event()
+ location_err = self.go_function(lib.ChangeSecureLocation)
+
+ if location_err:
+ raise Exception(location_err)
+
def set_secure_location(self, country_code: str) -> None:
# Set the location by country code
location_err = self.go_function(lib.SetSecureLocation, country_code)