Click here to Skip to main content
15,896,154 members
Please Sign up or sign in to vote.
2.00/5 (2 votes)
See more:
Hello!!

I have saved Password into table using MD5. Please tell me how to update these password? I am creating a page to let users change their passwords.I googled but only found links about how to store password using md5 not how to update.



Thanks!!
Posted
Comments
Abdul Quader Mamun 17-Jul-12 7:52am    
I think may be MD5 cannot be possible to decrypt. If so, then you need to create new encryption and replace it to old encryption.

Hi,
Here you can find an article on Encrypt and Decrypt Data with C#[^].

--Amit
 
Share this answer
 
Comments
_Amy 17-Jul-12 8:43am    
What was the problem? Got devoted..
Tejas Vaishnav 17-Jul-12 8:44am    
nice answer, it might helpful to solve the problem
Update and store is same thing. You create a MD5 from the new password and save it to the database. You don't have to do anything with the old password..

SQL
UPDATE tblUsers SET Password = 'newMd5password' WHERE UserId = 123
 
Share this answer
 
Comments
Tejas Vaishnav 17-Jul-12 8:43am    
this idea is also working for updating existing password, we can replace the old one with new/updated password.

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