<?php
namespace App\Controller;
use App\Form\Security\SecurityLoginType;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Security\Csrf\CsrfTokenManagerInterface;
use Symfony\Component\Security\Http\Authentication\AuthenticationUtils;
class SecurityController extends AbstractController
{
/**
* @Route("/login", name="security_login")
*/
public function login(Request $request, CsrfTokenManagerInterface $tokenManager, AuthenticationUtils $authenticationUtils)
{
return $this->render(
'security/login.html.twig',
[
'csrf_token' => $tokenManager->getToken('authenticate')->getValue(),
'error' => $authenticationUtils->getLastAuthenticationError(),
]
);
}
/**
* @Route("/logout", name="security_logout")
*/
public function logout()
{
}
}