diff options
author | Nicolas LÅ“uillet <nicolas@loeuillet.org> | 2015-01-22 08:30:07 +0100 |
---|---|---|
committer | Nicolas LÅ“uillet <nicolas@loeuillet.org> | 2015-01-22 08:30:07 +0100 |
commit | 93fd4692f6eb753cae16358131c8049d84cfbb41 (patch) | |
tree | 1ef2f66eb378cf419d1aa033a2c772539e60537d /app/config/security.yml | |
parent | 0440249631164a378981d014bf71b617c082bf5a (diff) | |
download | wallabag-93fd4692f6eb753cae16358131c8049d84cfbb41.tar.gz wallabag-93fd4692f6eb753cae16358131c8049d84cfbb41.tar.zst wallabag-93fd4692f6eb753cae16358131c8049d84cfbb41.zip |
symfony is there
Diffstat (limited to 'app/config/security.yml')
-rw-r--r-- | app/config/security.yml | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/app/config/security.yml b/app/config/security.yml new file mode 100644 index 00000000..a28b1db9 --- /dev/null +++ b/app/config/security.yml | |||
@@ -0,0 +1,52 @@ | |||
1 | # you can read more about security in the related section of the documentation | ||
2 | # http://symfony.com/doc/current/book/security.html | ||
3 | security: | ||
4 | # http://symfony.com/doc/current/book/security.html#encoding-the-user-s-password | ||
5 | encoders: | ||
6 | Symfony\Component\Security\Core\User\User: plaintext | ||
7 | |||
8 | # http://symfony.com/doc/current/book/security.html#hierarchical-roles | ||
9 | role_hierarchy: | ||
10 | ROLE_ADMIN: ROLE_USER | ||
11 | ROLE_SUPER_ADMIN: [ROLE_USER, ROLE_ADMIN, ROLE_ALLOWED_TO_SWITCH] | ||
12 | |||
13 | # http://symfony.com/doc/current/book/security.html#where-do-users-come-from-user-providers | ||
14 | providers: | ||
15 | in_memory: | ||
16 | memory: | ||
17 | users: | ||
18 | user: { password: userpass, roles: [ 'ROLE_USER' ] } | ||
19 | admin: { password: adminpass, roles: [ 'ROLE_ADMIN' ] } | ||
20 | |||
21 | # the main part of the security, where you can set up firewalls | ||
22 | # for specific sections of your app | ||
23 | firewalls: | ||
24 | # disables authentication for assets and the profiler, adapt it according to your needs | ||
25 | dev: | ||
26 | pattern: ^/(_(profiler|wdt)|css|images|js)/ | ||
27 | security: false | ||
28 | # the login page has to be accessible for everybody | ||
29 | demo_login: | ||
30 | pattern: ^/demo/secured/login$ | ||
31 | security: false | ||
32 | |||
33 | # secures part of the application | ||
34 | demo_secured_area: | ||
35 | pattern: ^/demo/secured/ | ||
36 | # it's important to notice that in this case _demo_security_check and _demo_login | ||
37 | # are route names and that they are specified in the AcmeDemoBundle | ||
38 | form_login: | ||
39 | check_path: _demo_security_check | ||
40 | login_path: _demo_login | ||
41 | logout: | ||
42 | path: _demo_logout | ||
43 | target: _demo | ||
44 | #anonymous: ~ | ||
45 | #http_basic: | ||
46 | # realm: "Secured Demo Area" | ||
47 | |||
48 | # with these settings you can restrict or allow access for different parts | ||
49 | # of your application based on roles, ip, host or methods | ||
50 | # http://symfony.com/doc/current/cookbook/security/access_control.html | ||
51 | access_control: | ||
52 | #- { path: ^/login, roles: IS_AUTHENTICATED_ANONYMOUSLY, requires_channel: https } \ No newline at end of file | ||