Скрипт на баш для проверки sql инъекций

select '1'   ; insert into  `area`  (`name` ,country_id )  value ('test2' , 123126) ; select '2'

 

public static function ecran($str) {
$search = array("\\","\0","\x1a","'",'"');
$replace = array("\\\\","\\0","\Z","\'",'\"');
$str = str_replace($search, $replace, $str);
return $str;
}

 Leave a Reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

(required)

(required)

   
© 2012 Программирование в удовольствие Яндекс.Метрика Suffusion theme by Sayontan Sinha