SSO authentication for Confluence Server not working for version 5.3.* ? Edited

I am trying to do a plugin for SSO authentication for Confluence Server. We have used DefaultAuthenticator to logging the user in. This currently works on different versions of Confluence 5.x but does not work on version 5.3.x (like 5.3.0 and 5.3.4) . 

After investigating further, we found that Confluence authoriseAndEstablish function returns true but it does not return the expected headers back. This only happens for Confluence 5.3.x.
  1. Expected Parameters in response header
  4. X-Confluence-Request-Time:
  5. X-Content-Type-Options:
  6. X-Seraph-LoginReason:


  1. X-Confluence-Request-Time:
  2. X-Content-Type-Options:
  3. X-XSS-Protection:
    1; mode=block

From the different log file the observed difference was -

DEBUG [atlassian.seraph.auth.DefaultAuthenticator] getUserFromSession getUserFromSession : Session found; "<USERNAME>" is present
[] asConfluenceUserPrincipal Principal (name="<USERNAME>", class=class com.atlassian.confluence.user.ConfluenceUserImpl$$EnhancerByCGLIB$$d538ed74 is not an instance of ConfluenceUserPrincipal and cannot be used for authentication
[atlassian.seraph.auth.DefaultAuthenticator] getUser getUser : User not found in either Session, Cookie or Basic Auth.
DEBUG [atlassian.seraph.filter.SecurityFilter] doFilter doFilter : Storing the originally requested URL (atlassian.core.seraph.original.url=/login.action?os_destination=%2Findex.action)
DEBUG [atlassian.seraph.filter.SecurityFilter] doFilter doFilter : requiredRoles = []
DEBUG [atlassian.plugin.servlet.PluginHttpSessionWrapper] getAttribute getAttribute('seraph_defaultauthenticator_logged_out_user') Popping ClassLoader: null .New ContextClassLoader: WebappClassLoader
delegate: false

Currently my POM has the following details for Confluence version. 
<!-- This key is used to keep the consistency between the key in atlassian-plugin.xml
and the key to generate bundle. -->
We also tried changing it to Confluence 5.3.4 and running it. It gives the same error. Any help is highly appreciated.

1 answer


Me too facing same issue for Confluence 5.3.4 and 5.3.0.

Quick response will be very helpful.

Thanks in advance.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Feb 06, 2019 in Confluence

Try out the new editing experience

Hi team, I’m Avinoam, a product manager on Confluence Cloud, and today I’m really excited to let the Community know that all customers can now try out the new editing experience and see some of the ...

1,093 views 56 8
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you