Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

InvalidNameIDPolicy working with ADFS

I have many clients that uses SSO, for that we use SAML 2. Many of my clients uses providers like Okta, PingIdentity and a bunch of them ADFS. Doing the integration with ADFS always at the beginning raises this error when they came back with the SAMLResponse.

<samlp:Status><samlp:StatusCode Value="urn:oasis:names:tc:SAML:2.0:status:Requester"><samlp:StatusCode Value="urn:oasis:names:tc:SAML:2.0:status:InvalidNameIDPolicy"/></samlp:StatusCode></samlp:Status>

Im asking to use as name Identifier this:

"urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress"

Im pretty new to SAML and I just want to know what is happening on ADFS, since this is just happening with clients that uses that.

Thanks a lot.

like image 753
wcpaez Avatar asked Nov 11 '16 02:11

wcpaez


People also ask

How does Saml work with ADFS?

ADFS uses a claim based access control authorization. This method involves authenticating users via cookies and Security Assertion Markup Language, also known as SAML. It means ADFS is a type of Security Token Service or STS. You can configure STS to have trust relationships that also accept OpenID accounts.

Does ADFS support SP initiated SSO?

AD FS supports the identity provider–initiated single sign-on (SSO) profile of the SAML 2.0 specification.

What is NameID policy?

The identifier string is called a NameID and its specification, including format, is the NameIDPolicy. For example, a Service Provider (SP) initiates federation by sending an AuthnRequest to the Identity Provider (IDP) containing <samlp:NameIDPolicy Format="urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress" />


1 Answers

By default, ADFS sends the NameId format as "urn:oasis:names:tc:SAML:1.1:nameid-format:unspecified". You can adjust it. See: https://social.technet.microsoft.com/wiki/contents/articles/4038.ad-fs-2-0-how-to-request-a-specific-name-id-format-from-a-claims-provider-cp-during-saml-2-0-single-sign-on-sso.aspx

like image 69
Sam Avatar answered Sep 30 '22 03:09

Sam