tuxbuddy Posted May 7, 2008 Share Posted May 7, 2008 I have written a login script during the user inputs it shows the password being written in plain text.I want to write it in dot-dot or encryted way as usual website has. How can I do that?? Link to comment https://forums.phpfreaks.com/topic/104523-login-password-in-md5/ Share on other sites More sharing options...
Coreye Posted May 7, 2008 Share Posted May 7, 2008 I have written a login script during the user inputs it shows the password being written in plain text.I want to write it in dot-dot or encryted way as usual website has. How can I do that?? <input type='password' name='password' size='25' /> Link to comment https://forums.phpfreaks.com/topic/104523-login-password-in-md5/#findComment-535045 Share on other sites More sharing options...
Psycho Posted May 7, 2008 Share Posted May 7, 2008 Note that making the field a "password" field only masks the password on screen when enetered. It is still sent in plain text when submitted. You would need to hash/encrypt the password when recived before creating the DB record. Link to comment https://forums.phpfreaks.com/topic/104523-login-password-in-md5/#findComment-535142 Share on other sites More sharing options...
947740 Posted May 7, 2008 Share Posted May 7, 2008 If you want to use md5() before you enter the password in the database, use: <?php $password = md5($_POST['password']); ?> Link to comment https://forums.phpfreaks.com/topic/104523-login-password-in-md5/#findComment-535221 Share on other sites More sharing options...
redarrow Posted May 7, 2008 Share Posted May 7, 2008 <?php $password_decripted="redarrow"; $password=$password_decripted; $password_encripted=md5($_POST['password']); echo"password was encripted with md5 $password_encripted <br><br> password not encripted: $password"; ?> Link to comment https://forums.phpfreaks.com/topic/104523-login-password-in-md5/#findComment-535233 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.