Hi, I just guess your problem. If you have used struts 2.x, you can easily get credential information via Action POJO. In your case, creating a new Action named LoginAction with 2 properties username, password, then create a new User class. In the LoginAction, get username and password passed in User object, put it into session if authenticated.
Here is a piece of code for demo: public class User implements Serializable { private String username; private String password; public User(String username, String password) { this.username = username; this.password = password; } } Public class LoginAction { private String username; private String password; public execute() { User user = new User(getUserame(), getPassword()); } } On 10/16/07, Zhang, Larry (L.) <[EMAIL PROTECTED]> wrote: > > In my Struts based J2EE application, I need to get user's login > information (user principal), and based on the login id, I will create > the user object and then put it into the session. I am wondering where > is the best place to put this code in. > > I read some info and it sounds like I should put this code in > CustomRequestProcessor (which extends TilesRequestProcessor)'s > processValidate method, please let me know if this is something correct. > Thanks. > > Larry > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >