Martin Warnaar

Results 3 comments of Martin Warnaar

@zerlpaMMT did you find a solution to this? It seems that (in Symfony 4) the result of `container[...]->get('security.token_storage')->getToken()->getUser()` returns 'anon.' instead of the currently logged in user. Therefore, using `symfony.authorization_checker->isGranted()`...

It turned out that it was a missing Apollo client setting. In front-end javascript, passing `credentials: 'same-origin'` with `createHttpLink` did the trick for session-based authentication (https://www.apollographql.com/docs/react/recipes/authentication.html). Might not be related...

I had the same problem on a localhost instance. Solved it by updating `Host name and path` under general settings from `localhost:3000` to just `localhost` and resetting 2FA from /my/account.