Click here to Skip to main content
15,886,362 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
dear sir,
I want to compare a password with one the user has already used stored in a SQL server database.

How can I achieve that?
Posted
Updated 8-Jan-13 7:23am
v2
Comments
Sergey Alexandrovich Kryukov 8-Jan-13 12:42pm    
What are you talking about? What password? What repeated password? What is "uswer"?
For your information, passwords are never stored anywhere and never compared with user input. Well, in properly designed systems. Surprised?
—SA
tusharkaushik 8-Jan-13 13:02pm    
Actually i mean that i want to validate password and confirmed password in Csharp windows application
[no name] 8-Jan-13 13:26pm    
there are so many validation control please use that ,and never try to post any incomplete question firstly kept your mind set and then ask
S@53K^S 8-Jan-13 13:31pm    
Do you want to compare 2 passwords like password and confirm password or do you want to authenticate a user

1 solution

If you want to compare passwords with one stored in a database, you better have that one in the database hashed or you have very, very serious security issues. The way to compare passwords, is to hash the password a user has entered and then compare that hash with the one stored in a database. If you haven't done it this way, FIX IT NOW!
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900