Expand my Community achievements bar.

Don’t miss the AEM Skill Exchange in SF on Nov 14—hear from industry leaders, learn best practices, and enhance your AEM strategy with practical tips.
SOLVED

How do I read (via Java?) the SAML response from my SSO provider?

Avatar

Level 9

We have protected some published pages via login through our SSO provider. I would like to read the SAML response so we can customize some of the things that's displayed on the page.

How can this be done?

I've searched the net and the results I've found involves the configuration to setup AEM to connect to a SSO provider.

Thanks

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hey Jay,

It really depends on the facts that are being passed to you through your SSO Provider and how your SSO Provier read SAML Spec.

There is OOTB config that you can add that will sync the parameters stored in the: Synchronized Attributes of the Adobe Granite SAML 2.0 Authentication Handler, config that is found in the OSGi Config.

Regards,

Peter

View solution in original post

2 Replies

Avatar

Correct answer by
Community Advisor

Hey Jay,

It really depends on the facts that are being passed to you through your SSO Provider and how your SSO Provier read SAML Spec.

There is OOTB config that you can add that will sync the parameters stored in the: Synchronized Attributes of the Adobe Granite SAML 2.0 Authentication Handler, config that is found in the OSGi Config.

Regards,

Peter

Avatar

Level 3

jayv25585659 AFAIK, this can be achieved using the Open SAML APIs https://build.shibboleth.net/nexus/content/sites/site/java-support/7.4.2/apidocs/  .

Below is a sample piece of code which I used in the past to read a SAML response, however not within AEM:

Please note all the required APIs sufficient enough to read the SAML response are available under Open SAML only https://wiki.shibboleth.net/confluence/display/OS30/APIDocumentation