Jump to content

Recommended Posts

  • Replies 127
  • Created
  • Last Reply

Top Posters In This Topic

<?php

$pwd=trim(strip_tags(mysql_real_escape_string(htmlspecialchars($_POST['pwd'])));
$pwd.=md5($pwd);
$email=trim(strip_tags(mysql_real_escape_string(htmlspecialchars($_POST['email'])));
if(!empty($pwd)||isset($pwd)||isset($email)||!empty($email)){ //submit
} else{

//error
}
?>

if you did your validation right you wouldnt have those failures :P

Well if a number of ppl r using automated scans, thats thousands of requests.

hosting accounts gives limited bandwidth to users and each request uses a very minor amount of bandwidth.

 

A few scans shouldn't damage your bandwidth usage but try and resort to manual testing.

 

your fix:

<?php

$pass1= trim(mysql_real_escape_string(strip_tags(htmlspecialchars($_POST['pass1']))));
$pass1.= md5($pass1);
$pass2= trim(mysql_real_escape_string(strip_tags(htmlspecialchars($_POST['pass2']))));
$pass2.= md5($pass2);
$user_code= trim(mysql_real_escape_string(strip_tags(htmlspecialchars($_POST['user_code']))));

if(!empty($pass1)||!empty($pass2)||!empty($user_code)||isset($pass1)||isset($pass2)||isset($user_code)){
//submit
}else{ //error
}

?>


×
×
  • 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.