avillanu Posted August 7, 2007 Share Posted August 7, 2007 I'm building a registration/login script: $result = "insert into users (username, password, email) values ('$username', sha1('$password'), '$email')"; I've tested this out by submitting (username1, password1) and (username2, password2) Both "password1" and "password2" are encrypted to the same string: da39a3ee5e6b4b0d3255bfef95601890afd80709 or d41d8cd98f00b204e9800998ecf8427e to be exact....it doesn't matter what I use for the password Link to comment https://forums.phpfreaks.com/topic/63763-problems-with-md5-and-sha1/ Share on other sites More sharing options...
avillanu Posted August 7, 2007 Author Share Posted August 7, 2007 Very interesting - I took out md5/sha1 from the MySQL insert and it is blank when I check it in PHPMyAdmin. Not sure why though - does PHP have some sort of precaution? Link to comment https://forums.phpfreaks.com/topic/63763-problems-with-md5-and-sha1/#findComment-317778 Share on other sites More sharing options...
avillanu Posted August 7, 2007 Author Share Posted August 7, 2007 Got this working. There was a typo, forgot the _ in the $POST part... Link to comment https://forums.phpfreaks.com/topic/63763-problems-with-md5-and-sha1/#findComment-317783 Share on other sites More sharing options...
Fadion Posted August 8, 2007 Share Posted August 8, 2007 Then u should make this topic solved. Link to comment https://forums.phpfreaks.com/topic/63763-problems-with-md5-and-sha1/#findComment-318042 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.