tags:

views:

149

answers:

1

1.I came across decumentation on this,but cannot find real example on how to use ? any tutorial on this?
2. is there any sample war that i can try out on this?

+1  A: 

Documentation is here, scroll down to "Single Sign On" section.

You can try it with any web applications that have authentication configured. All you need to do is to enable (or add)

<Valve className="org.apache.catalina.authenticator.SingleSignOn" debug="0"/>

in Tomcat's server.xml (it's commented out by default) AND have realm specified at the host level (e.g. within that same server.xml) as opposed to individual application context.

ChssPly76
i alr read the doc.1.does both web app need to have asme authentication configured? mean if webapp 1 using database authentication with email as username, 2nd webapp must use same method ?2. how to specify realm. can elaborate?
cometta
1. All applications for which you want Single Sign On to work must share the same realm, so yes - authentication mechanism will be exactly the same. 2. Realm should be specified within the same `<Host>` element as SingleSignOn valve. Details are here: http://tomcat.apache.org/tomcat-6.0-doc/realm-howto.html. For db-based authentication you're looking at JDBCRealm, there's an example in the above link.
ChssPly76