E
Eduardo
Hello, I would like to know what do people use for
user authentication in Tomcat.
I am developing a small application with servlets and
JSP where I want:
- users log in before being able to do anything
- if the user is not logged in and tries to access
any other page, he gets the login page instead
- the usernames and passwords live in a database
As I see it, there are two main options for achieving
this:
1) Use JDBC realm to authenticate against the database
2) Add code at the top of all the pages to verify that
the user is logged in, etc.
Number 1) seems the easiest solution, but I wonder how
many people use it? It doesn't seem too portable to
other non-Tomcat platforms... Anybody using it for
your apps?
Finally, is there any Number 3) option that I am missing?
Thanks in advance for the help!
Eduardo
user authentication in Tomcat.
I am developing a small application with servlets and
JSP where I want:
- users log in before being able to do anything
- if the user is not logged in and tries to access
any other page, he gets the login page instead
- the usernames and passwords live in a database
As I see it, there are two main options for achieving
this:
1) Use JDBC realm to authenticate against the database
2) Add code at the top of all the pages to verify that
the user is logged in, etc.
Number 1) seems the easiest solution, but I wonder how
many people use it? It doesn't seem too portable to
other non-Tomcat platforms... Anybody using it for
your apps?
Finally, is there any Number 3) option that I am missing?
Thanks in advance for the help!
Eduardo