]>
Commit | Line | Data |
---|---|---|
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: | |
12 | class: WallabagUserBundle:User | |
13 | property: username | |
14 | fos_userbundle: | |
15 | id: fos_user.user_provider.username | |
16 | ||
17 | # the main part of the security, where you can set up firewalls | |
18 | # for specific sections of your app | |
19 | firewalls: | |
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 | ||
25 | oauth_token: | |
26 | pattern: ^/oauth/v2/token | |
27 | security: false | |
28 | ||
29 | api: | |
30 | pattern: /api/.* | |
31 | fos_oauth: true | |
32 | stateless: true | |
33 | anonymous: true | |
34 | ||
35 | login_firewall: | |
36 | pattern: ^/login$ | |
37 | anonymous: ~ | |
38 | ||
39 | secured_area: | |
40 | pattern: ^/ | |
41 | form_login: | |
42 | provider: fos_userbundle | |
43 | csrf_token_generator: security.csrf.token_manager | |
44 | ||
45 | anonymous: true | |
46 | remember_me: | |
47 | secret: "%secret%" | |
48 | lifetime: 31536000 | |
49 | path: / | |
50 | domain: ~ | |
51 | ||
52 | logout: | |
53 | path: /logout | |
54 | target: / | |
55 | ||
56 | access_control: | |
57 | - { path: ^/api/doc, roles: IS_AUTHENTICATED_ANONYMOUSLY } | |
58 | - { path: ^/api/version, roles: IS_AUTHENTICATED_ANONYMOUSLY } | |
59 | - { path: ^/login, roles: IS_AUTHENTICATED_ANONYMOUSLY } | |
60 | - { path: ^/register, role: IS_AUTHENTICATED_ANONYMOUSLY } | |
61 | - { path: ^/resetting, role: IS_AUTHENTICATED_ANONYMOUSLY } | |
62 | - { path: /(unread|starred|archive).xml$, roles: IS_AUTHENTICATED_ANONYMOUSLY } | |
63 | - { path: ^/share, roles: IS_AUTHENTICATED_ANONYMOUSLY } | |
64 | - { path: ^/settings, roles: ROLE_SUPER_ADMIN } | |
65 | - { path: ^/annotations, roles: ROLE_USER } | |
66 | - { path: ^/, roles: ROLE_USER } |