.htaccess - htaccess rewrite url contains -


i'm trying block urls in site, example want "ban" urls , give them 403 when contains words options, k2 or component. problem htaccess not work properly

<ifmodule mod_rewrite.c> rewriteengine on rewritecond %{request_method} ^(option|k2|component) [nc] rewriterule .* - [f] </ifmodule> 

is blocking when bot attack www.example.com/option=?asdasdad not blocking when bot attacking www.example.com/index.php/option=?asdad

anyone?

remove above , put following code :

 rewriteengine on  rewriterule (option|k2|component) - [f] 

Comments

Popular posts from this blog

javascript - Laravel datatable invalid JSON response -

java - Exception in thread "main" org.springframework.context.ApplicationContextException: Unable to start embedded container; -

sql server 2008 - My Sql Code Get An Error Of Msg 245, Level 16, State 1, Line 1 Conversion failed when converting the varchar value '8:45 AM' to data type int -