Results 1 to 2 of 2
  1. #1
    adammyth is offline Member
    Join Date
    Dec 2009
    Rep Power

    Default user authorization problem

    I am trying to build a simple web-site which has a user authorization functionality.

    I receive the login information via jsp page (containing hmtl forms).
    Jsp page sends this information to the servlet.
    Servlet instantiates a java object specific for this user.
    so for each logged-in user there is a corresponding java object. Example
    Java Code:
    myObject usr1 = new myObject("user1");
    myObject usr2 = new myObject("user2");
    Until here things are ok.

    The problem arises when user wants to logout using the logout form in the jsp page.
    I am not able to determine which user wants to log out.
    Does the user who wants to logout belongs to usr1 object or usr2?
    1. How can i hold the information on jsp pages so that in servlet i will be able to understand who wants to logout?
    2. How can i pass this information from jsp to servlet?
    Is there a way to do this without servlet session management?
    I don't want to use HttpSession objects.

    Thanks in advance.

  2. #2
    serjant's Avatar
    serjant is offline Senior Member
    Join Date
    Jun 2008
    Rep Power


    What about request attributes, or better to store the auth information into cookies instead of using Session

Similar Threads

  1. how to get input from User
    By Alvaro in forum New To Java
    Replies: 7
    Last Post: 01-16-2010, 12:02 AM
  2. urgent help -java mail authorization failed exception
    By ravinder.kadiyan in forum Advanced Java
    Replies: 2
    Last Post: 04-30-2008, 12:27 PM
  3. How to get the User Name
    By Java Tip in forum java.lang
    Replies: 0
    Last Post: 04-04-2008, 03:43 PM
  4. New User
    By TKI5 in forum New To Java
    Replies: 0
    Last Post: 12-13-2007, 02:13 AM
  5. How to get the User Name
    By JavaBean in forum Java Tip
    Replies: 0
    Last Post: 10-04-2007, 10:35 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts