authentication done

This commit is contained in:
Olivier PARPAILLON
2024-11-19 13:07:07 +01:00
parent 51fcbba8b2
commit 8ddbf9c5d6
7 changed files with 134 additions and 34 deletions

View File

@@ -7,7 +7,7 @@ security:
# used to reload user from session & other features (e.g. switch_user)
app_user_provider:
entity:
class: App\Entity\User
class: App\Entity\Participant
property: email
# used to reload user from session & other features (e.g. switch_user)
# used to reload user from session & other features (e.g. switch_user)
@@ -18,6 +18,16 @@ security:
main:
lazy: true
provider: app_user_provider
form_login:
login_path: app_login
check_path: app_login
enable_csrf: true
default_target_path: home
always_use_default_target_path: true
logout:
path: app_logout
# where to redirect after logout
# target: app_any_route
# activate different ways to authenticate
# https://symfony.com/doc/current/security.html#the-firewall