]> git.immae.eu Git - github/wallabag/wallabag.git/blob - app/config/security.yml
Update bundle & stock file
[github/wallabag/wallabag.git] / app / config / security.yml
1 security:
2 encoders:
3 FOS\UserBundle\Model\UserInterface: sha512
4
5 role_hierarchy:
6 ROLE_ADMIN: ROLE_USER
7 ROLE_SUPER_ADMIN: [ ROLE_USER, ROLE_ADMIN, ROLE_ALLOWED_TO_SWITCH ]
8
9 providers:
10 administrators:
11 entity: { class: WallabagUserBundle:User, property: username }
12 fos_userbundle:
13 id: fos_user.user_provider.username
14
15 # the main part of the security, where you can set up firewalls
16 # for specific sections of your app
17 firewalls:
18 # disables authentication for assets and the profiler, adapt it according to your needs
19 dev:
20 pattern: ^/(_(profiler|wdt)|css|images|js)/
21 security: false
22
23 oauth_token:
24 pattern: ^/oauth/v2/token
25 security: false
26
27 api:
28 pattern: /api/.*
29 fos_oauth: true
30 stateless: true
31 anonymous: true
32
33 login_firewall:
34 pattern: ^/login$
35 anonymous: ~
36
37 secured_area:
38 pattern: ^/
39 form_login:
40 provider: fos_userbundle
41 csrf_token_generator: security.csrf.token_manager
42
43 anonymous: true
44 remember_me:
45 secret: "%secret%"
46 lifetime: 31536000
47 path: /
48 domain: ~
49
50 logout:
51 path: /logout
52 target: /
53
54 access_control:
55 - { path: ^/api/doc, roles: IS_AUTHENTICATED_ANONYMOUSLY }
56 - { path: ^/login, roles: IS_AUTHENTICATED_ANONYMOUSLY }
57 - { path: ^/register, role: IS_AUTHENTICATED_ANONYMOUSLY }
58 - { path: ^/resetting, role: IS_AUTHENTICATED_ANONYMOUSLY }
59 - { path: /(unread|starred|archive).xml$, roles: IS_AUTHENTICATED_ANONYMOUSLY }
60 - { path: ^/, roles: ROLE_USER }