security:
    password_hashers:
        App\Entity\User:
            algorithm: auto
    
    role_hierarchy:
        ROLE_ADMIN:       [ROLE_USER, ROLE_FORUM_ADMIN]
        ROLE_SUPER_ADMIN: ROLE_ADMIN

    providers:
        base_user_provider:
            entity: 
                class: App\Entity\User
                property: email

    # https://symfony.com/doc/current/security.html#initial-security-yml-setup-authentication
    firewalls:
        main:
            user_checker: Tigris\BaseBundle\Security\UserChecker
            provider: base_user_provider
            remember_me:
                secret: '%kernel.secret%'
            lazy: true
            custom_authenticator: Tigris\BaseBundle\Security\LoginFormAuthenticator
            #stateless: true
            logout:
                path: tigris_base_security_logout


        dev:
            pattern: ^/(_(profiler|wdt)|css|images|js)/
            security: false

    access_control:
        # this is a catch-all for the admin area
        # additional security lives in the controllers
        - { path: ^/, roles: PUBLIC_ACCESS , requires_channel: '%env(SECURE_SCHEME)%' }
        - { path: ^/login$, roles: PUBLIC_ACCESS , requires_channel: '%env(SECURE_SCHEME)%' }
        - { path: ^/register, roles: PUBLIC_ACCESS , requires_channel: '%env(SECURE_SCHEME)%' }
        - { path: ^/resetting, roles: PUBLIC_ACCESS , requires_channel: '%env(SECURE_SCHEME)%' }
        - { path: ^/admin/, roles: ROLE_ADMIN, requires_channel: '%env(SECURE_SCHEME)%' }
