tomfmason Posted August 7, 2006 Share Posted August 7, 2006 I am not sure if this is the proper forum to post this in or not. I would have posted it in the faq/ code snippet forum but I cannot.Anyways, I recently changed the layout of my database and soon ran into a serious problem. All of my users were getting the error message (when logining in) invaild password or username. Since I knew that I had not changed the login function. It had to be a problem with the md5 or the database. Well what I did was change the length of the password to 12 and almost everything that is md5'ed is longer then 12 characters. Here is an example with the password [b]test[/b]test with a length of 12 [b]098f6bcd4621[/b]test md5'ed normaly [b]098f6bcd4621d373cade4e832627b4f6[/b]as you can see it normaly has a length of 32. This means that when trying to login with md5'ed password that your password will not be correct.If any mods feel the need to move this post. Please do so.Hope this helps someone some day.Good Luck,Tom Quote Link to comment https://forums.phpfreaks.com/topic/16761-invalid-password/ Share on other sites More sharing options...
akitchin Posted August 7, 2006 Share Posted August 7, 2006 all MD5 hashes are 32 characters long as far as i know; this is a property of the algorithm. anyone know differently? Quote Link to comment https://forums.phpfreaks.com/topic/16761-invalid-password/#findComment-70489 Share on other sites More sharing options...
tomfmason Posted August 7, 2006 Author Share Posted August 7, 2006 You are right. I did not know this before..lol Well I guess that I learned something new today.Thanks,Tom Quote Link to comment https://forums.phpfreaks.com/topic/16761-invalid-password/#findComment-70492 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.