/
home
/
obinna
/
html
/
restaurants
/
config
/
packages
/
Upload File
HOME
security: encoders: App\Document\User: algorithm: bcrypt role_hierarchy: ROLE_ADMIN: [ROLE_USER, ROLE_ALLOWED_TO_SWITCH] providers: # used to reload user from session & other features (e.g. switch_user) app_user_provider: mongodb: class: App\Document\User property: email firewalls: dev: pattern: ^/(_(profiler|wdt)|css|images|js)/ security: false main: anonymous: true guard: authenticators: - App\Security\LoginFormAuthenticator logout: path: app_logout remember_me: secret: '%kernel.secret%' lifetime: 31536000 always_remember_me: true # activate different ways to authenticate # https://symfony.com/doc/current/security.html#firewalls-authentication # https://symfony.com/doc/current/security/impersonating_user.html switch_user: true # Easy way to control access for large sections of your site # Note: Only the *first* access control that matches will be used access_control: - { path: ^/login, roles: IS_AUTHENTICATED_ANONYMOUSLY } - { path: ^/register, roles: IS_AUTHENTICATED_ANONYMOUSLY } - { path: ^/email/*, roles: IS_AUTHENTICATED_ANONYMOUSLY } - { path: ^/admin/*, roles: ROLE_USER } - { path: ^/businesses, roles: ROLE_ADMIN }