Since it sounds like time may be lacking for you, a premade solution may best serve your needs. | [reply] |
Frankly, I would be rather wary of using those. It's an unfortunate fact that 99% of cgi programs on the web roll their own parameter parsers, don't use strict, and so on. If one were to suggest a premade solution, make it from someone a with better coding habits. Heck, one might even learn some Perl in the process..
Update: Toned down the negativity about the above-mentioned URL, on the basis that there is a non-zero chance that at least one of them might be written correctly.
perl -pe '"I lo*`+$^X$\"$]!$/"=~m%(.*)%s;$_=$1;y^+*`^ ve^#$&V"+@( NO CARRIER'
| [reply] |
The quality of scripts there is about the same as those listed in CGI Resource Index. Of course, they're not all bad (You'll find NMS listed there for example), but you should exercise caution wherever you download your copy-paste scripts from (including perlmonks).
I don't mean that in a bad way, but it's prudent.
Simon Flack ($code or die)
$,=reverse'"ro_';s,$,\$,;s,$,lc ref sub{},e;$,
=~y'_"' ';eval"die";print $_,lc substr$@,0,3;
| [reply] |
If you are running Apache it would probably be much simpler to use HTACCESS on the area of your site that you want to protect. | [reply] |