JamesA has asked for the wisdom of the Perl Monks concerning the following question:
I am writing a perl CGI to trap hack attempts on my web server. Right now I am implementing this with "ScriptAliasMatch" commands in httpd.conf but this method is getting unwieldy as the number of patterns are increasing.
I would like an error document CGI to run a loop reading regexes from a file and compare them to the requested URL until a match is found or all the regexes have been tested.
I have not found any samples yet that point me in the right direction to perform this 'reverse grep' type of function.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Reverse grep?
by chromatic (Archbishop) on Mar 01, 2002 at 19:18 UTC | |
Re: Reverse grep?
by rbc (Curate) on Mar 01, 2002 at 19:09 UTC | |
Re: Reverse grep?
by Juerd (Abbot) on Mar 01, 2002 at 19:39 UTC | |
Re: Reverse grep?
by chipmunk (Parson) on Mar 02, 2002 at 17:23 UTC | |
Re: Reverse grep?
by JamesA (Acolyte) on Mar 02, 2002 at 00:45 UTC | |
by dws (Chancellor) on Mar 02, 2002 at 00:47 UTC | |
by coolmichael (Deacon) on Mar 02, 2002 at 05:23 UTC | |
by jeffa (Bishop) on Mar 02, 2002 at 18:35 UTC |
Back to
Seekers of Perl Wisdom