Skip to content
Permalink
Browse files
improve csrf token generation
  • Loading branch information
orthagh authored and trasher committed May 5, 2020
1 parent 6dc5cb6 commit 039c184cba0f1b564fde2d934f103910db779922
Showing 1 changed file with 1 addition and 1 deletion.
@@ -1138,7 +1138,7 @@ static public function getNewCSRFToken() {

if (empty($CURRENTCSRFTOKEN)) {
do {
$CURRENTCSRFTOKEN = md5(uniqid(rand(), true));
$CURRENTCSRFTOKEN = bin2hex(random_bytes(32));
} while ($CURRENTCSRFTOKEN == '');
}

0 comments on commit 039c184

Please sign in to comment.