From 9956373a1474a6fa697148c510d6937add12e3d1 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Fri, 12 Mar 2021 12:42:26 +0100 Subject: [PATCH] Backport the log to detect module that claim a new token. --- htdocs/main.inc.php | 1 + 1 file changed, 1 insertion(+) diff --git a/htdocs/main.inc.php b/htdocs/main.inc.php index 78ed3d82bda..437e024a3ae 100644 --- a/htdocs/main.inc.php +++ b/htdocs/main.inc.php @@ -421,6 +421,7 @@ if (!defined('NOTOKENRENEWAL')) // Save in $_SESSION['newtoken'] what will be next token. Into forms, we will add param token = $_SESSION['newtoken'] $token = dol_hash(uniqid(mt_rand(), true)); // Generates a hash of a random number $_SESSION['newtoken'] = $token; + dol_syslog("NEW TOKEN reclaimed by : " . $_SERVER['PHP_SELF'], LOG_DEBUG); } //dol_syslog("aaaa - ".defined('NOCSRFCHECK')." - ".$dolibarr_nocsrfcheck." - ".$conf->global->MAIN_SECURITY_CSRF_WITH_TOKEN." - ".$_SERVER['REQUEST_METHOD']." - ".GETPOST('token', 'alpha').' '.$_SESSION['token']);