security:

    enable_authenticator_manager: true

    # https://symfony.com/doc/current/security.html#c-hashing-passwords
    password_hashers:
        Symfony\Component\Security\Core\User\PasswordAuthenticatedUserInterface: 'auto'
        App\Entity\Model\User:
            algorithm: argon2i # This should be the same value as in config/packages/security.yaml
            #cost: 4 # Lowest possible value for bcrypt
            #time_cost: 3 # Lowest possible value for argon
            #memory_cost: 10 # Lowest possible value for argon

    # https://symfony.com/doc/current/security.html#where-do-users-come-from-user-providers
    providers:
        users_in_memory: { memory: null }
        # used to reload user from session & other features (e.g. switch_user)
        app_user_provider:
            entity:
                class: App\Entity\Model\User
                property: username
    firewalls:
        dev:
            pattern: ^/(_(profiler|wdt)|css|images|js)/
            security: false
        main:
            login_throttling:
                max_attempts: 3
                interval: '15 minutes'

            lazy: true
            logout:
                path: app_logout
                # where to redirect after logout
                # target: app_any_route

            provider: app_user_provider
            custom_authenticator: App\Security\LoginFormAuthenticator

    # 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: PUBLIC_ACCESS }
        - { path: ^/svycar/*, roles: PUBLIC_ACCESS }
        - { path: ^/api/*, roles: PUBLIC_ACCESS }
        - { path: ^/*, roles: ROLE_USER }
