summaryrefslogtreecommitdiff
path: root/src/leap/common/ca_bundle.py
diff options
context:
space:
mode:
authorKali Kaneko <kali@leap.se>2014-11-07 18:49:26 +0100
committerKali Kaneko <kali@leap.se>2014-11-07 18:49:26 +0100
commit3de1eeba83d50793283d65ba4566dd1611ee9d4b (patch)
tree4686b117c61979069f91ef86ea240398a826c005 /src/leap/common/ca_bundle.py
parenta33bff3701c553c7ddaa1521ae1a077e1d3dadca (diff)
parent2498d0c1712b06efe6ac29d883d3a80b541fe765 (diff)
Merge tag '0.3.9' into deb-0.3.9
Tag leap.common version 0.3.9
Diffstat (limited to 'src/leap/common/ca_bundle.py')
-rw-r--r--src/leap/common/ca_bundle.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/leap/common/ca_bundle.py b/src/leap/common/ca_bundle.py
index 1e00f25..d8c72a6 100644
--- a/src/leap/common/ca_bundle.py
+++ b/src/leap/common/ca_bundle.py
@@ -21,8 +21,12 @@ If you are packaging Requests, e.g., for a Linux distribution or a managed
environment, you can change the definition of where() to return a separately
packaged CA bundle.
"""
+import platform
import os.path
+_system = platform.system()
+
+IS_MAC = _system == "Darwin"
def where():
"""
@@ -30,6 +34,10 @@ def where():
:rtype: str
"""
# vendored bundle inside Requests, plus some additions of ours
+ if IS_MAC:
+ return os.path.join("/Applications", "Bitmask.app",
+ "Contents", "Resources",
+ "cacert.pem")
return os.path.join(os.path.dirname(__file__), 'cacert.pem')
if __name__ == '__main__':