tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Possible to Authenticate from Servlet/Webapp Code?
Date Tue, 07 Dec 2004 15:45:09 GMT
Is there a way to authenticate a user to the container (including SSO) from
within a servlet? Something like: 

protected void service(HttpServletRequest req, HttpServletResponse resp) {
    Realm tomcatRealm = //how to get the realm???
    tomcatRealm.authenticate("dauser", "dauserspassword");

Other Info:
I know how to configure the custom login pages, etc., but I need a way to
authenticate in two places at once, due to a legacy application.

It seems like this should be easy to do, so I expect I'm missing something
obvious, but I simply can't figure out how to do it. I've been searching for
a while...

While standards-based would be better, a Tomcat-specific way would be fine
as well. 

Tim Sawlor

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message