summaryrefslogtreecommitdiff
path: root/src/leap/eip
diff options
context:
space:
mode:
authorkali <kali@leap.se>2012-10-20 07:13:22 +0900
committerkali <kali@leap.se>2012-10-20 07:13:22 +0900
commita85e488ed323ba35b9d12c5cc344bf06337a9a00 (patch)
tree548caec9f0e8c66e88bf5a67cf36ba2254e3e0f1 /src/leap/eip
parentf791a83ce57cef7010da819d61e7f5132fa4611e (diff)
add bypass for already trusted fingerprints
Diffstat (limited to 'src/leap/eip')
-rw-r--r--src/leap/eip/checks.py1
-rw-r--r--src/leap/eip/config.py11
2 files changed, 9 insertions, 3 deletions
diff --git a/src/leap/eip/checks.py b/src/leap/eip/checks.py
index 635308bb..b335b857 100644
--- a/src/leap/eip/checks.py
+++ b/src/leap/eip/checks.py
@@ -319,7 +319,6 @@ class ProviderCertChecker(object):
return "https://%s/1/cert" % self.domain
def _get_client_cert_path(self):
- # MVS+ : get provider path
return eipspecs.client_cert_path(domain=self.domain)
def _get_ca_cert_path(self, domain):
diff --git a/src/leap/eip/config.py b/src/leap/eip/config.py
index ef0f52b4..1ce4a54e 100644
--- a/src/leap/eip/config.py
+++ b/src/leap/eip/config.py
@@ -78,8 +78,15 @@ def get_eip_gateway():
return placeholder
if len(gateways) > 0:
for gw in gateways:
- if gw['name'] == primary_gateway:
- hosts = gw['hosts']
+ name = gw.get('name', None)
+ if not name:
+ return
+
+ if name == primary_gateway:
+ hosts = gw.get('hosts', None)
+ if not hosts:
+ logger.error('no hosts')
+ return
if len(hosts) > 0:
return hosts[0]
else: