Answer the question
In order to leave comments, you need to log in
How to block and check banned ip? PHP?
i need it to be banned when ip makes too many requests per second. How to check ip in Codeigniter so as not to write a check in each controller? also tell me how to check how many ip makes requests per second?
Answer the question
In order to leave comments, you need to log in
Agree with other commentators. Protection must be implemented not in php, but by means of the server. However, if you are completely impatient, then you can do something a la vitalykim.ru/zashhita-ot-ddos-atak-na-php.html
And implement a call to check for ddos in the MY_Controller constructor and inherit all controllers from it, or implement hook pre_controller .
nginx limit_req
at the php level is useless, because the php script is already running, but you just need to protect yourself from its frequent launch.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question