我有两个用户提供商,其中一个是in_memory。
providers:
chain_provider:
chain:
providers: [in_memory, iac_provider]
iac_provider:
entity:
class: IACOvirugBundle:User
property: username
in_memory:
memory:
users:
external_service: { password: AG4QIf4, roles: 'ROLE_EXTERNAL_API' }
和access_control
access_control:
- { path: ^/login, roles: IS_AUTHENTICATED_ANONYMOUSLY }
- { path: ^/api/external/login, roles: IS_AUTHENTICATED_ANONYMOUSLY }
- { path: ^/soap-service, roles: IS_AUTHENTICATED_ANONYMOUSLY }
- { path: ^/service/check, roles: IS_AUTHENTICATED_ANONYMOUSLY }
- { path: ^/api/external, roles: ROLE_EXTERNAL_API }
- { path: ^/api/doc, roles: ROLE_SUPER_ADMIN }
- { path: ^/, roles: ROLE_USER }
用户从内存授权后,我已拒绝访问。 我在profiler中看到了:
我看到日志
我的错误在哪里?