summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/saml2/config.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/saml2/config.py b/src/saml2/config.py
index 8b865dcb..6687a60f 100644
--- a/src/saml2/config.py
+++ b/src/saml2/config.py
@@ -404,7 +404,12 @@ class Config(object):
if endps and service in endps:
for endpspec in endps[service]:
try:
- endp, bind = endpspec
+ # endspec sometime is str, sometime is a tuple
+ if type(endpspec) in (tuple, list):
+ # slice prevents 3-tuple, eg: sp's assertion_consumer_service
+ endp, bind = endpspec[0:2]
+ else:
+ endp, bind = endpspec
if binding is None or bind == binding:
spec.append(endp)
except ValueError: