AEM6.1 SAML Authentication, getCookies() is null after successfull authentication | Community
Skip to main content
sandeepm744005
Level 5
November 10, 2016
Solved

AEM6.1 SAML Authentication, getCookies() is null after successfull authentication

  • November 10, 2016
  • 5 replies
  • 3343 views

Hi, we are using AEM6.1+ SP2, facing issue like request.getRequestURI() and httpServletRequest.getCookies() null in the custom authentication handler which is implementing AuthenticationInfoPostProcessor interface.

Same code is working fine in AEM6.0+sp2 from where we have migrated into AEM6.1, please let me know if any configuration or setting needs to be done to make it working? any help would be highly appreciated.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by sandeepm744005

This issue has been fixed, root cause of the issue was - "Adding request header: Cookie" missing in the requests which were coming from the dispatcher, a configuration is added in the apache to send the required header in the request.

5 replies

Sham_HC
Level 10
November 11, 2016

AFAIK there is no change.  Are you by any chance changing the protocal between http & https?

sandeepm744005
Level 5
November 11, 2016

Hi Sham, thanks for replying, no there is no protocol change, it seems only problem with inplace upgrade, when we tried to setup the same configuration in fresh AEM6.1 instance, it is working fine but not working with inplace upgrade, please help provide some help. 

Sham_HC
Level 10
November 11, 2016

Use  http://www.aemstuff.com/tools/coi.html and see if any mismatch.  Otherwise engage with official support.

sandeepm744005
Level 5
November 14, 2016

we have isolated the getCookies issues with dispatcher only, it started working with individual publish servers. We already have set-cookies in the header in the dispatcher configuration, please let me know if any other configuration we need to enable to make it working. We are using dispatcher 4.1.12 and AEM6.1 + SP2

 

/auth_checker
              {
            
              # any header line returned from the auth_checker's HEAD request matching
              # the section below will be returned as well
              /headers
                {
                /0000
                  {
                  /glob "*"
                  /type "deny"
                  }
                /0001
                  {
                  /glob "Set-Cookie:*"
                  /type "allow"
                  }
                }
              }

sandeepm744005
sandeepm744005AuthorAccepted solution
Level 5
November 16, 2016

This issue has been fixed, root cause of the issue was - "Adding request header: Cookie" missing in the requests which were coming from the dispatcher, a configuration is added in the apache to send the required header in the request.