]> git.immae.eu Git - github/wallabag/wallabag.git/blame - app/config/security.yml
Allow login by email
[github/wallabag/wallabag.git] / app / config / security.yml
CommitLineData
93fd4692 1security:
93fd4692 2 encoders:
fcb1fba5 3 FOS\UserBundle\Model\UserInterface: sha512
93fd4692 4
93fd4692 5 role_hierarchy:
2bc9cad7 6 ROLE_ADMIN: ROLE_USER
c3235553 7 ROLE_SUPER_ADMIN: [ ROLE_USER, ROLE_ADMIN, ROLE_ALLOWED_TO_SWITCH ]
93fd4692 8
93fd4692 9 providers:
c3235553 10 administrators:
2bc9cad7
JB
11 entity:
12 class: WallabagUserBundle:User
13 property: username
a1691859 14 fos_userbundle:
08d6bedc 15 id: fos_user.user_provider.username_email
93fd4692
NL
16
17 # the main part of the security, where you can set up firewalls
18 # for specific sections of your app
19 firewalls:
5c895a7f
JB
20 # disables authentication for assets and the profiler, adapt it according to your needs
21 dev:
22 pattern: ^/(_(profiler|wdt)|css|images|js)/
23 security: false
24
fcb1fba5
NL
25 oauth_token:
26 pattern: ^/oauth/v2/token
27 security: false
4c5e5441 28
fcb1fba5
NL
29 api:
30 pattern: /api/.*
31 fos_oauth: true
32 stateless: true
cd1298d6 33 anonymous: true
fcb1fba5 34
c3235553 35 login_firewall:
2bc9cad7 36 pattern: ^/login$
c3235553
NL
37 anonymous: ~
38
d9169157 39 secured_area:
a1691859 40 pattern: ^/
d9169157 41 form_login:
a1691859 42 provider: fos_userbundle
5c895a7f 43 csrf_token_generator: security.csrf.token_manager
d9169157 44
2bc9cad7 45 anonymous: true
5a584614 46 remember_me:
2bc9cad7 47 secret: "%secret%"
5a584614 48 lifetime: 31536000
2bc9cad7
JB
49 path: /
50 domain: ~
5a584614 51
d9169157
J
52 logout:
53 path: /logout
54 target: /
c3235553 55
93fd4692 56 access_control:
88924980 57 - { path: ^/api/doc, roles: IS_AUTHENTICATED_ANONYMOUSLY }
2b477030 58 - { path: ^/api/version, roles: IS_AUTHENTICATED_ANONYMOUSLY }
426bb453 59 - { path: ^/api/user, roles: IS_AUTHENTICATED_ANONYMOUSLY }
c3235553 60 - { path: ^/login, roles: IS_AUTHENTICATED_ANONYMOUSLY }
fcb1fba5 61 - { path: ^/register, role: IS_AUTHENTICATED_ANONYMOUSLY }
1210dae1 62 - { path: ^/resetting, role: IS_AUTHENTICATED_ANONYMOUSLY }
a40a8038 63 - { path: /(unread|starred|archive|all).xml$, roles: IS_AUTHENTICATED_ANONYMOUSLY }
18c38dff 64 - { path: /tags/(.*).xml$, roles: IS_AUTHENTICATED_ANONYMOUSLY }
f3d0cb91 65 - { path: ^/share, roles: IS_AUTHENTICATED_ANONYMOUSLY }
63e40f2d 66 - { path: ^/settings, roles: ROLE_SUPER_ADMIN }
f38e03dc 67 - { path: ^/annotations, roles: ROLE_USER }
152fcccd 68 - { path: ^/users, roles: ROLE_SUPER_ADMIN }
07c9b1c9 69 - { path: ^/, roles: ROLE_USER }