SunQuest
 
           Code Bank
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
 
User Name:
Password:
Remember me
Go Back   ASP Free ForumsProgrammingCode Bank

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread ASP Free Forums Sponsor:
SlickEdit: Code in over 40 languages across 7 platforms. SlickEdit’s unmatched power, speed, and flexibility allows even the most accomplished developers to write better code faster. Download a free trial today!
  #1  
Old April 30th, 2008, 11:17 AM
adam678 adam678 is offline
Contributing User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Mar 2007
Posts: 123 adam678 User rank is Sergeant (500 - 2000 Reputation Level)adam678 User rank is Sergeant (500 - 2000 Reputation Level)adam678 User rank is Sergeant (500 - 2000 Reputation Level)adam678 User rank is Sergeant (500 - 2000 Reputation Level)adam678 User rank is Sergeant (500 - 2000 Reputation Level) 
Time spent in forums: 2 Days 8 h 31 m 50 sec
Reputation Power: 11
Other - Tip for storing encrypted passwords

Some of you probably already do this, but I thought this was a great tip and well worth sharing.

If you are storing encrypted passwords, don't simply encrypt the password entered by the user, chances are they won't pick a very secure password and it will be easy to decrypt. Instead, take their username or email (whichever they login with) and join it onto their password, i.e.:

joe.bloggs@abc.commypassword

And encrypt the whole thing with MD5 or your preferred encryption method.

On the login screen, join the users username with the password they enter, encrypt, and check for a match in the database. If you accept either username or email for a login and the password they give is incorrect once you join it, get the users email or username (which ever they didn't enter) using their login name as an ID and try joining the password again.

If the user wants to update either their username or email (whichever you used to encrypt their password) simply ask them to confirm their password, and join the two together again, call it a security check!

For updating their password simply get their username from their login session, or just ask for it as another security check!
Comments on this post
Dr_Rock agrees: nice tip

Reply With Quote
Reply

Viewing: ASP Free ForumsProgrammingCode Bank > Other - Tip for storing encrypted passwords


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway