code comment
This commit is contained in:
parent
a92f03d942
commit
d6081d7d87
@ -421,7 +421,7 @@ if (!defined('NOTOKENRENEWAL'))
|
|||||||
// Rolling token at each call ($_SESSION['token'] contains token of previous page)
|
// Rolling token at each call ($_SESSION['token'] contains token of previous page)
|
||||||
if (isset($_SESSION['newtoken'])) $_SESSION['token'] = $_SESSION['newtoken'];
|
if (isset($_SESSION['newtoken'])) $_SESSION['token'] = $_SESSION['newtoken'];
|
||||||
|
|
||||||
// Save in $_SESSION['newtoken'] what will be next token. Into forms, we will add param token = $_SESSION['newtoken']
|
// Save in $_SESSION['newtoken'] what will be next token. Into forms, we will add param token = newToken();
|
||||||
$token = dol_hash(uniqid(mt_rand(), true)); // Generates a hash of a random number
|
$token = dol_hash(uniqid(mt_rand(), true)); // Generates a hash of a random number
|
||||||
$_SESSION['newtoken'] = $token;
|
$_SESSION['newtoken'] = $token;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user