Using AssertionConsumerServiceIndex instead of assertionConsumerServiceUrl with itfoxtec

Viewed 183

Is it possible to set a AssertionConsumerServiceIndex in a AuthnRequest like this SAML example below with ITfoxtec SAML 2.0

I want to have somethings like this:

<?xml version="1.0" encoding="UTF-8"?>
<samlp:AuthnRequest
    xmlns:samlp="urn:oasis:names:tc:SAML:2.0:protocol"
    xmlns:saml="urn:oasis:names:tc:SAML:2.0:assertion"
    ID="_1330416073" Version="2.0" IssueInstant="2012-02-28T09:01:13Z"
    AssertionConsumerServiceIndex="0" ProviderName="provider name">
     <saml:Issuer>http://sp.example.com</saml:Issuer>
     <samlp:RequestedAuthnContext Comparison="minimum">
         <saml:AuthnContextClassRef>urn:oasis:names:tc:SAML:2.0:ac:classes:PasswordProtectedTransport</saml:AuthnContextClassRef>
     </samlp:RequestedAuthnContext>
</samlp:AuthnRequest>

Code:

var binding = new Saml2RedirectBinding();
return binding.Bind(new Saml2AuthnRequest(config)
{
      RequestedAuthnContext = new RequestedAuthnContext
      {
          Comparison = AuthnContextComparisonTypes.Minimum, 
          AuthnContextClassRef = new string[] { AuthnContextClassTypes.PasswordProtectedTransport.OriginalString },
      },
}).ToActionResult();
1 Answers

I'm afraid the ITfoxtec Identity SAML 2.0 component does not support the AssertionConsumerServiceIndex attribute.

Related