User provided password is stored MD5 encrypted format in the database. If user provides same password which is converted into MD5 string is not matching with the stored encrypted password.
Please guide me with a solution. Thanks
To submit answer, Please login!
Total Number of Answers Available: 1
- Srikant Kumar
Profession: Editor, Writer, Blogger, SEO Expert
seo digital marketing video editing screenwriting blogging
I am not sure what exactly causing this error.
I have also gone through this situation. I am explaining how I solved this.
While creating table, I have set maximum string length of password field in the database table to 12 as I was allowing only 12 character password to store in the database.
But when we encrypt a string with md5, the string length changes.
<?php $str="Banana"; echo md5($str);
See the md5 format of string value Banana has larger string length. By default, my maximum password field length was set to 12, so it trimmed rest of the string.
See if you have same issue. All you need to do is increase password field maximum length.
Liked My Answer! Hit Good Answer Button Below.