Welcome Guest, Not a member yet? Register   Sign In
block hacker

I'm sure there is a better way to do the following. My aim was to stop a hack attempt at the very start, so in routes, at the very top, I have
$sUrl = strtolower(uri_string());
if(str_starts_with($sUrl,'wp-')  || str_starts_with($sRUrl,'admin')  || str_starts_with($sUrl,'view-')   || str_starts_with($sUrl,'misc/')){
    // definite hacker - set default controller to Controllers/Home which shows simply "Site Under Construction"
    $routes->get('(:any)',$sHackerController );
    $routes->post('(:any)', $sHackerController);
    $routes->put('(:any)', $sHackerController);
    $routes->delete('(:any)', $sHackerController);
// and then come the proper routes
what is the right way to do this?
thanks, Bill

On what level do you define a 'hacker', looks to me like you want to stop the 'auto bots' with directory/credentials sniffing.

Well I knew it was a bot but I class them all as hacking attempts. Anyway, I've just learned something new from you. So how do i stop the auto bots please?
Thanks, Bill

This may help you figure it out.

Control bots, spiders, and crawlers
What did you Try? What did you Get? What did you Expect?

Joined CodeIgniter Community 2009.  ( Skype: insitfx )

Many thanks

Theme © iAndrew 2016 - Forum software by © MyBB