Created
May 30, 2016 18:50
-
-
Save wouterj/80f3264f7e92eed3c9b9e621b6142228 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
security: | |
encoders: | |
AppBundle\Entity\User: | |
algorithm: pbkdf2 | |
hash_algorithm: sha512 | |
encode_as_base64: true | |
iterations: 1000 | |
# http://symfony.com/doc/current/book/security.html#where-do-users-come-from-user-providers | |
providers: | |
our_db_provider: | |
entity: | |
class: AppBundle:User | |
property: username | |
firewalls: | |
# disables authentication for assets and the profiler, adapt it according to your needs. | |
dev: | |
pattern: ^/(_(profiler|wdt)|css|images|js)/ | |
security: false | |
main: | |
pattern: ^/ | |
provider: our_db_provider | |
anonymous: ~ | |
form_login: | |
login_path: /login | |
check_path: /login | |
access_control: | |
- { path: ^/(login|register), roles: ROLE_USER } # or whatever roles you use |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment