Hello! I have been doing my reading on log-in/username system security and I want to post what I have done! I still feel like my system is lacking in security, so I'd love any and all input!
I've completely obscured the MySQL table values to my liking (A LOT of fun!!!). My username password encryption is as follows:
//encrypt password
$enc_mypassword=md5($mypassword);
// To protect MySQL injection
$myusername = stripslashes($myusername);
$enc_mypassword = stripslashes($mypassword);
$enc_myusername = mysql_real_escape_string($myusername);
$enc2_mypassword = mysql_real_escape_string($enc_mypassword);
$enc3_mypassword = md5($enc2_mypassword);
And is then followed (after determining that the user is valid) by:
session_register("myusername");
$_SESSION["loginusername"] = $myusername;
Here's where I feel that I'm lacking...on each page following it performs this check:
session_start();
if(!session_is_registered(myusername)){
header("location:registerform.php");
}
And that's it. What else can I do? THANKS SO MUCH!!!
I really appreciate it :D!
-Jeff