fansa Posted December 24, 2008 Share Posted December 24, 2008 Hallo everybody... How to make our user name and password more secure by using php coding.It is because to prevent our system from hacker. have any suggestion?? Quote Link to comment https://forums.phpfreaks.com/topic/138270-solved-how-to-make-user-name-and-paswoord-more-secure/ Share on other sites More sharing options...
ngreenwood6 Posted December 24, 2008 Share Posted December 24, 2008 As long as you are using post and not get it should be secure as no one can see it in the url. the only other thing that you could do is md5() the password when it is inserted into the database so that nobody can "hack" it. Quote Link to comment https://forums.phpfreaks.com/topic/138270-solved-how-to-make-user-name-and-paswoord-more-secure/#findComment-722916 Share on other sites More sharing options...
fansa Posted December 24, 2008 Author Share Posted December 24, 2008 ok..i got what u mean..but, can u explain more about md5()??much appreciate for your advice Quote Link to comment https://forums.phpfreaks.com/topic/138270-solved-how-to-make-user-name-and-paswoord-more-secure/#findComment-722921 Share on other sites More sharing options...
trq Posted December 24, 2008 Share Posted December 24, 2008 Just store your passwords as an md5'd hash. eg; INSERT INTO users (uname, upass) VALUES ('thorpe', MD5('foo')); Quote Link to comment https://forums.phpfreaks.com/topic/138270-solved-how-to-make-user-name-and-paswoord-more-secure/#findComment-722924 Share on other sites More sharing options...
fansa Posted December 24, 2008 Author Share Posted December 24, 2008 oo like that, that mean the data will auto encrypt once the user key in the data rite?...got idea..thanks a lot.If any another idea,hope will be share together Quote Link to comment https://forums.phpfreaks.com/topic/138270-solved-how-to-make-user-name-and-paswoord-more-secure/#findComment-722926 Share on other sites More sharing options...
bdmovies Posted December 31, 2008 Share Posted December 31, 2008 I use sha1 as it is more secure than MD5. $password = sha1(msyql_escape_string($_POST['password'])); $user = mysql_escape_string($_POST['user']); <?php INSERT INTO users (uname, upass) VALUES ('$user', $password);?> Quote Link to comment https://forums.phpfreaks.com/topic/138270-solved-how-to-make-user-name-and-paswoord-more-secure/#findComment-727192 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.