Jump to content

Recommended Posts

I am working on a "product catalog", I need to make sure the login gate is secure. I also need to make sure there is no security holes. All I am going to tell you, is there is an admin with the username of james.

 

Link to Test Site: http://www.hssz.net/sz/admin

Product Site      : http://www.hssz.net/sz/

 

Proof of Ownership: http://www.hssz.net/sz/phpfreaks.txt

 

Post any problems! Thanks!

Link to comment
https://forums.phpfreaks.com/topic/199310-test-please-hack-it-really/
Share on other sites

  • 6 months later...

you could start by making sure

 

you have something like

 

 

function clean($str) {
if(!get_magic_quotes_gpc()) {
$str = addslashes($str);
}
$str = strip_tags(htmlspecialchars($str));
return $str;
}

 

and call it like this

clean($variable);

you could start by making sure

 

you have something like

 

 

function clean($str) {
if(!get_magic_quotes_gpc()) {
$str = addslashes($str);
}
$str = strip_tags(htmlspecialchars($str));
return $str;
}

 

and call it like this

clean($variable);

 

That function is floored. You only need to escape special characters (addslashes or preferably mysql_real_escape_string) on the way into a database. htmlspecialchars should be used when using data for display, and strip_tags would only be used dependent on the situation and the data involved.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.