FIX SQL injection on user/index.php parameter search_statut.

This commit is contained in:
Laurent Destailleur
2017-05-29 09:57:05 +02:00
parent d03d179fa3
commit 70636cc59f
2 changed files with 11 additions and 8 deletions

View File

@@ -286,6 +286,9 @@ function GETPOST($paramname,$check='',$method=0,$filter=NULL,$options=NULL)
case 'int':
if (! is_numeric($out)) { $out=''; }
break;
case 'intcomma':
if (preg_match('/[^0-9,]+/i',$out)) $out='';
break;
case 'alpha':
$out=trim($out);
// '"' is dangerous because param in url can close the href= or src= and add javascript functions.