I have two firewalls, one for my API calls (WSSE secured), one for my application. Both works well, but I need to authenticate user on the api firewall and in the same time on the application firewall and I can't do that.
My security.yml
firewalls:
# Firewall for the api
wsse_secured:
pattern: ^/api/.*
wsse:
nonce_dir: null
lifetime: 300
provider: fos_userbundle
context: user
# Firewall for the application
main:
pattern: /.*
form_login:
provider: fos_userbundle
login_path: fos_user_security_login
check_path: fos_user_security_check
default_target_path: espace_perso
always_use_default_target_path: false
failure_path: fos_user_security_login
logout:
path: fos_user_security_logout
target: fos_user_security_login
oauth:
resource_owners:
facebook: "/login/check-facebook"
linkedin: "/login/check-linkedin"
google: "/login/check-google"
login_path: fos_user_security_login
oauth_user_provider:
service: bg.oauth.user_provider
anonymous: true
context: user
I already read other post (this question, this one and this one) and as you can see, add the context don't work in my case.
I try to add manually the wsse header that I need, or create a new WsseToken for my user with events, without success.
I really need help for this problem which must be common...