Fix for PHP 7.2 compatibility

This commit is contained in:
nemunaire 2020-11-15 17:20:47 +01:00
commit 2be9fcd5c3
12 changed files with 21 additions and 15 deletions

View file

@ -50,7 +50,7 @@ if (!empty($sess->values["connected"]))
unset($header);
//Evite les attaques CSRF
if (!empty($_SERVER["HTTP_REFERER"]) && !(preg_match('#^http://'.$_SERVER['HTTP_HOST'].'#', $_SERVER["HTTP_REFERER"]) && defined("xCSRF")))
if (!empty($_SERVER["HTTP_REFERER"]) && !(preg_match('#^https://'.$_SERVER['HTTP_HOST'].'#', $_SERVER["HTTP_REFERER"]) && defined("xCSRF")))
{
elog("Possibilité d'attaque CSRF\n".var_export($_REQUEST, TRUE), 2);
unset($_POST, $_GET);