diff --git a/malwaresh.pl b/malwaresh.pl index 3c1305c..97c7d18 100644 --- a/malwaresh.pl +++ b/malwaresh.pl @@ -19,6 +19,8 @@ $| = 1; our $q = CGI->new; print "Content-type: text/html\n\n"; +my $user = $ARGV[0]; + my @regexen = ( qr/<\?php\s+\/\*\s+Plugin\s+Name\:\s+antisp.+?add\_filter\(\'all\_plugins\'\,\s+\'ANTISP\_hide\'\)\;/is, qr/<\?php.+?\;\$\{\"G.+?\;global\$mysqli\;global\$dbHost\;global\$dbUser\;\$.+?\;else\s+return\;break\;\}\}\s+\?>/is, @@ -723,7 +725,7 @@ my @base64_decodes = ( my @file_list; my %possible_list; -my $start_dir = '/home/$1/public_html'; +my $start_dir = "/home/$user/public_html/"; $start_dir =~ s/\/cgi-bin//; $start_dir =~ s/\/lp-msh-scanner//; $start_dir = substr($start_dir, 0, rindex($start_dir, '/'));