We are moving our forum in GitHub Discussions. For questions about Phalcon v3/v4 you can visit here and for Phalcon v5 here.

isosec or other anti flood option?

Hello: I'm looking for advice from people who implemented any anti-flood functionally in a phalcon proyect.

In need to retrict certatin actions (ex: search) to maximun per second from same ip at least, we hope to have a far more advanced logic.

Were do you start in implementing something like that in phalcon?

I would implement this hooking the beforeExecuteRoute event which can be done in creating a public method called beforeExecuteRoute in your controllers.

If it return false, the action is not executed

Drupal implement a flood service. see code 'core/Drupal/Core/Flood' component