Login page user name and password for Oracle Database
Hi,
I created a login.jsp page with username,password and a submit button. How can I validate this username and password from my Oracle database username and password?
I am using NetBeans5.5 with Tomcat5.5.17. Right now I have hardcoded username and password in my persistence.xml.
Anyhelp?
# 2
Thnx BalusC for ur reply. Let me explain my issue.
I have created a login page. and user is able to enter user name and passowrd on this page. User is supposed to press a 'submit' button when user enters username and password to connect to database. What should I write in 'submit' button's action to let user allow to proceed if username and password are correct i.e. username and password of my oracle database. (usename=scott and passowrd=tiger).
plz help.
# 3
Pseudocode:
1) User user = SELECT * FROM users WHERE username.
2) if (user == null) set error "You are not registered." and exit.
3) if (!user.getPassword().equals(enteredPassword)) set error "Invalid password." and exit.
4) No errors and anything OK? Proceed.
This article might contain interesting material: http://balusc.xs4all.nl/srv/dev-jep-usf.html