-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Quanxin,
zhu quanxin wrote: > I am looking for tomcat API for doing programmatic login. I read the > source code of org.apache.catalina.authenticator.SingleSignOn, and > find that it contains a method called reauthenticate maybe helpful. [snip] > but when I use those code in my application(for example a servlet), it > could not work. I think I could not get the instance of realm in > tomcat server. That's because the Request object isn't an HttpServletRequest object, which is what you have in your servlet. Without trouble, you can't get access to this internal object from your servlet. > do you have a better idea about programmic login, and how to write it? Check out securityfilter... it keeps the user's principal in the session instead of somewhere else, so it's easy to get. Not sure if it plays well with SSO, though. - -chris -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFG4Gq69CaO5/Lv0PARAgHjAKC9I7NFT3j48+CXdFm4DiIzyUEL5gCgiV40 wR5JB0V+ELPuTGJ2rucBLus= =HkxJ -----END PGP SIGNATURE----- --------------------------------------------------------------------- To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]