Skip to content

Select preferred binding on the configuration #120

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 2 additions & 5 deletions src/satosa/backends/saml2.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@
from base64 import urlsafe_b64encode, urlsafe_b64decode
from urllib.parse import urlparse

from saml2 import BINDING_HTTP_POST
from saml2 import BINDING_HTTP_REDIRECT
from saml2.client_base import Base
from saml2.config import SPConfig
from saml2.extension.ui import NAMESPACE as UI_NAMESPACE
Expand Down Expand Up @@ -57,7 +55,6 @@ def __init__(self, outgoing, internal_attributes, config, base_url, name):

self.config = config
self.attribute_profile = config.get("attribute_profile", "saml")
self.bindings = [BINDING_HTTP_REDIRECT, BINDING_HTTP_POST]
self.discosrv = config.get("disco_srv")
self.encryption_keys = []
self.outstanding_queries = {}
Expand Down Expand Up @@ -126,8 +123,8 @@ def authn_request(self, context, entity_id):
:return: response to the user agent
"""
try:
binding, destination = self.sp.pick_binding("single_sign_on_service", self.bindings, "idpsso",
entity_id=entity_id)
binding, destination = self.sp.pick_binding(
"single_sign_on_service", None, "idpsso", entity_id=entity_id)
satosa_logging(logger, logging.DEBUG, "binding: %s, destination: %s" % (binding, destination),
context.state)
acs_endp, response_binding = self.sp.config.getattr("endpoints", "sp")["assertion_consumer_service"][0]
Expand Down