Add csrf token

This commit is contained in:
gamonoid
2018-06-14 04:05:22 +02:00
parent 025a8283ab
commit fde94aa7fa

View File

@@ -159,6 +159,9 @@ if (empty($user) || empty($user->email)) {
$tuser = \Utils\SessionUtils::getSessionObject('user'); $tuser = \Utils\SessionUtils::getSessionObject('user');
$logoFileUrl = \Classes\UIManager::getInstance()->getCompanyLogoUrl(); $logoFileUrl = \Classes\UIManager::getInstance()->getCompanyLogoUrl();
$csrfToken = sha1(rand(4500, 100000) . time(). CLIENT_BASE_URL);
\Utils\SessionUtils::saveSessionObject('csrf-login', $csrfToken);
?><!DOCTYPE html> ?><!DOCTYPE html>
<html lang="en"> <html lang="en">
<head> <head>