Set requestedAuthnContext to null

This topic contains 2 replies, has 2 voices, and was last updated by  annouar 10 months ago.

  • Author
  • #15855

    Hello everyone !

    I am trying to implement an IDP Proxy that let the user choose the IdP he wants to use. To do this, I have partly followed this Almost because I do not want to use LOA for now : I only want to display all IdPs linked to my IdP Proxy.

    My config is the following one :
    SP (
    IdP Proxy (
    IdP 1 (

    After setting all the configuration, I init SOO with the call :
    but it redirects me to my IdP Proxy login page. I followed Federation debug file and I’ve found

    libSAML2:02/17/2017 11:26:11:074 AM UTC: Thread[http-nio-8080-exec-1,5,main]: TransactionId[4d05dc6b-22b0-4759-9cfa-9415648f8ea3-243]
    SAML2IDPPRoxyFRImpl.selectIdPBasedOnLOA: No extensions found for IdP

    I’ve found also in the src/main/java/com/sun/identity/saml2/plugins/ (the implementation I am using) the function selectIDPBasedOnLOA and the code I want to go into :

               RequestedAuthnContext requestedAuthnContext = authnRequest.getRequestedAuthnContext();
               if (requestedAuthnContext == null) {
                   //Handle the special case when the original request did not contain any Requested AuthnContext:
                   //In this case we just simply return all the IdPs as each one should support a default AuthnContext.
                   return StringUtils.join(idpList, " ");

    So I need to set requestedAuthnContext to null to go in. Any idea ?

    Thank you !

     Peter Major 

    You may find it easier to use my demo impl instead:

    if you want to go with OOTB stuff, then go to the hosted SP setting and change “Default Authentication Context” setting to —– none —–

    that should do it.


    Hey Peter,

    thanks you for your answer, it was very helpful !

    However, I got some trouble with Actually, I’m trying to compile it (with a mvn package command), and an error has been returned. It seems that we need an account on to collect the project dependencies.


Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.

©2018 ForgeRock - we provide an identity and access platform to secure every online relationship for the enterprise market, educational sector and even entire countries. Click to view our privacy policy and terms of use.

Log in with your credentials

Forgot your details?