Skip to content

Commit 7ed8932

Browse files
author
Alexander Schrijver
committed
Add the ability to set AttributeConsumingServiceIndex in the authn request.
1 parent 2f78c44 commit 7ed8932

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/onelogin/saml2/authn_request.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ def __init__(self, settings, force_authn=False, is_passive=False, set_nameid_pol
108108

109109
attr_consuming_service_str = ''
110110
if 'attributeConsumingService' in sp_data and sp_data['attributeConsumingService']:
111-
attr_consuming_service_str = "\n AttributeConsumingServiceIndex=\"1\""
111+
attr_consuming_service_str = "\n AttributeConsumingServiceIndex=\"%s\"" % sp_data['attributeConsumingService'].get('index', '1')
112112

113113
request = OneLogin_Saml2_Templates.AUTHN_REQUEST % \
114114
{

0 commit comments

Comments
 (0)