php - Handling login failure in a Symfony application -
i working on app using fosuserbundle , maintains local database of users. use case follows:
user tries login , upon login credentials authenticated
in case of success user proceeds navigate site
in case of failure above:
the credentials authenticated against single sign on service , if credentials correct, user created locally, logged in, , proceeds navigate site.
in case single sign on unsuccessful, user shown default incorrect password screen
my question in symfony add logic?
this have tried far:
i have tried @ overrriding loginaction on further research read may not work dislays login form.
i looked @ following stackoverflow question: overriding authentication failure handler - symfony2
also read in symfony docs: http://symfony.com/doc/current/cookbook/security/custom_authentication_provider.html
i not clear whether should use approach in 2 or 3 in use case. tips or code samples highly appreciated.
i ended using hybrid approach of 2 & 3 solve problem.
Comments
Post a Comment