I have the following security.yml:
security: encoders: Test\BackEndBundle\Entity\User: algorithm: sha512 encode-as-base64: true iterations: 10 providers: main: entity: { class: TestBackEndBundle:User, property: username } firewalls: main: pattern: /.* form_login: check_path: _security_check login_path: _security_login default_target_path: homepage logout: true security: true anonymous: true access_control: - { path: ^/service, role: IS_AUTHENTICATED_ANONYMOUSLY } - { path: ^/login, role: IS_AUTHENTICATED_ANONYMOUSLY } - { path: /.*, roles: {ROLE_PARTNER, ROLE_ADMIN} }
And the following routing:
homepage: pattern: / defaults: { _controller: TestBackEndBundle:Default:index } _security_login: pattern: /login defaults: { _controller: TestBackEndBundle:Security:login } _security_check: pattern: /login_check _security_logout: pattern: /logout
Authentication works well, instead of redirecting after logging in. The application redirects to / _ wdt / 5044c6f2a329c . How can I redirect to the home page? Thanks.
pltvs source share