--- misc/scripts/cgi/taillog.cgi 2001/03/09 00:22:30 1.1 +++ misc/scripts/cgi/taillog.cgi 2004/08/01 10:39:51 1.6 @@ -12,7 +12,12 @@ if (defined $grep) { $grepStr = ""; } else { - $grepStr = " | grep $grep"; + if ($grep =~ /^[a-zA-Z_\-0-9\.\/]+$/) { + $grepStr = " | grep $grep"; + } + else { + $grepStr = ""; + } } } else { @@ -23,7 +28,7 @@ if (!defined $n) { $n = 50; } -unless ($n =~ /^[0-9]{1,4}$/) { +unless ($n =~ /^[0-9]{1,6}$/) { $n = 50; } @@ -48,11 +53,11 @@ system, unix, linux, nt, server, alert">
- +