@@ -18,19 +18,24 @@ security:
1818 custom_authenticators :
1919 - App\Security\LoginFormAuthenticator
2020 provider : admin_user_provider
21+ login_throttling :
22+ max_attempts : 5
2123 logout :
2224 path : app_logout
2325 target : dashboard
2426 # Without this, any page the admin visits can log them out with a plain GET
2527 enable_csrf : true
2628
2729
30+ # Only the first matching rule applies, so the public endpoints are listed first and the
31+ # admin interface is whatever is left. A route added later is protected unless it is added
32+ # to this list on purpose.
2833 access_control :
2934 - { path: ^/$, roles: PUBLIC_ACCESS }
3035 - { path: ^/dav, roles: PUBLIC_ACCESS }
31- - { path: ^/dashboard, roles: ROLE_ADMIN, allow_if: "'%env(default:default_admin_auth_bypass:ADMIN_AUTH_BYPASS)%' === 'true'" }
32- - { path: ^/users, roles: ROLE_ADMIN, allow_if: "'%env(default:default_admin_auth_bypass:ADMIN_AUTH_BYPASS)%' === 'true'" }
33- - { path: ^/calendars, roles: ROLE_ADMIN, allow_if: "'%env(default:default_admin_auth_bypass:ADMIN_AUTH_BYPASS)%' === 'true'" }
34- - { path: ^/addressbooks, roles: ROLE_ADMIN, allow_if: "'%env(default:default_admin_auth_bypass:ADMIN_AUTH_BYPASS)%' === 'true'" }
36+ - { path: ^/\.well-known/, roles: PUBLIC_ACCESS }
37+ - { path: ^/login$, roles: PUBLIC_ACCESS }
38+ - { path: ^/logout$, roles: PUBLIC_ACCESS }
3539 - { path: ^/api/v1/health$, roles: PUBLIC_ACCESS }
3640 - { path: ^/api, roles: IS_AUTHENTICATED }
41+ - { path: ^/, roles: ROLE_ADMIN, allow_if: "'%env(default:default_admin_auth_bypass:ADMIN_AUTH_BYPASS)%' === 'true'" }
0 commit comments