Question

I am developing saml sso using wso2is. I customized the authentication endpoint according the blog post below 1. Basically I just deployed a war on my server and configured application-authenticators.xml to use it:

<Authenticators>
<Authenticator name="BasicAuthenticator" disabled="false" factor="1">
    <!-- <Status value="10" loginPage="/authenticationendpoint/login.do" /> -->
    <Status value="10" loginPage="https://servlet.example.com/customlogin/login.do" /> 
</Authenticator>
</Authenticators>

login is working fine, my custom login-page sends a form to "https://servlet.example.com/idp/commonauth" which redirects me to my sp. but I also want to customize the redirect-page after the login. in the custom endpoint there is a file named 'samlsso_redirect.jsp' which looks like it should do the work but its contents are ignored.

strangely 'samlsso_redirect.jsp' the the bundled authentication endpoint is also ignored.

I have also downloaded the sources of wso2is and found org.wso2.carbon.identity.sso.saml.servlet.SAMLSSOProviderServlet hard codes the redirect message in the sendResponse() method.

Does somebody know how it is working and what I am missing here? How can I customize the redirect message?

http://dulanja.blogspot.sk/2014/01/wso2-is-samlsso-customizing-login-page.html

Was it helpful?

Solution

If you are using WSO2IS 5.0.0 version or higher version, You can simplify edit html file which can be found at IS_HOME\repository\resources\security\sso_redirect.html

Following applies to WSO2IS 4.6.0 and older versions

It seems to be that redirect page is can not be customized by using some extension. Please see this jira

However You can do as following if you want to customize it in 4.6.0...

  1. svn checkout https://svn.wso2.org/repos/wso2/carbon/platform/branches/turing/components/identity/org.wso2.carbon.identity.sso.saml/4.2.2

  2. In src/main/java/org/wso2/carbon/identity/sso/saml/servlet/SAMLSSOProviderServlet.java you have to modify the HTML getting printed in sendResponse() method.

  3. Build the component using maven and place as a patch in wso2is-4.6.0/repository/components/patches. Copy jar file into any patch directory

  4. Restart the server

note : The built jar name appears as: org.wso2.carbon.identity.sso.saml-4.2.2.jar. Make sure to rename it to org.wso2.carbon.identity.sso.saml_4.2.2.jar (notice that the dash is replaced by an underscore) before placing in the patch folder.

OTHER TIPS

If you are using IS 5.0 then you need to modify this page: IS_HOME\repository\resources\security\sso_redirect.html

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top