- Login fonctionnel

This commit is contained in:
2025-01-29 14:11:28 +01:00
parent ae09474b49
commit ced8d321bc
4 changed files with 31 additions and 24 deletions

View File

@ -10,23 +10,18 @@ security:
class: App\Entity\User
property: email
firewalls:
dev:
pattern: ^/(_(profiler|wdt)|css|images|js)/
security: false
main:
lazy: true
provider: app_user_provider
# activate different ways to authenticate
# https://symfony.com/doc/current/security.html#the-firewall
# https://symfony.com/doc/current/security/impersonating_user.html
# switch_user: true
# Ajout de la gestion de la déconnexion
form_login:
login_path: app_login
check_path: app_login
username_parameter: _username
password_parameter: _password
default_target_path: home # Assure-toi que cette route existe
logout:
path: /logout # Route pour déconnecter l'utilisateur
target: /login # Redirection vers la page de login après déconnexion
path: /logout
target: /login
# Easy way to control access for large sections of your site
# Note: Only the *first* access control that matches will be used