anyx / LoginGateBundle

59 stars 23 forks source link

Incrementing and clearing counters should not use authentication handlers #3

Closed stof closed 2 years ago

stof commented 8 years ago

When using handlers, you are responsible for deciding what the Response should be after the success and the failure. and your bundle provide a very naive implementation, which is not the implementation shipped in Symfony by default. This means that enabling the bundle break things.

Given that incrementing and clearing counters is totally independent from the action taken after the authentication, you should use the authentication events instead.

anyx commented 8 years ago

Hi @stof Today i made refactoring of this bundle. Not sure that current implementation can be useful for someone, but if issue was opened, I tried to make bundle better (or installable at least).

If you have some advises for making implementation less naive, i will be glad to hear them.

Thanks

cordoval commented 6 years ago

This bundle is a bit confusing but after all it is using the events as @stof said. Just don't follow the readme 😄 . Use the listener and register without extending anything special class from symfony and deal with those events. This should probably become a warning.