0byt3m1n1
Path:
/
data
/
16
/
.snapshot
/
daily.2025-03-10_0010
/
inventory
/
ARCHIVE
/
[
Home
]
File: vuxfind_plcgiht.pl
#!/usr/local/bin/perl $file = $ARGV[0]; chomp($file); $filesection = $file; open LIST, "<${file}"; #$file =~ s/\.txt//; @FILEPARTS = (split /\// ,$file); $file = pop(@FILEPARTS); open STATUS, ">/data/16/inventory/done/VUX_Scan/${file}-Status.txt"; open HTLIST, ">/data/16/inventory/HTLISTS/${file}-HTLIST.txt"; open PLCGI, ">/data/16/inventory/PLCGILISTS/${file}-PLCGI.txt"; while (<LIST>) { #1 $line = $_; chomp($line); ($dom, $sites, $dompath) = split /\;/ ,$line,3; $userpath = ((split /\/htdocs/, $dompath)[0]); @HT_ARRAY = `find $userpath "\(" -name ".htaccess" -o -name "*.pl" -o -name "*.cgi" "\)" -print`; foreach(@HT_ARRAY) { #2 $htfile = $_; chomp($htfile); print HTLIST "$htfile\n" if ($htfile =~ /htaccess/); print PLCGI "$htfile\n" if (($htfile =~ /pl/) || ($htfile =~ /cgi/)); } #2 print STATUS "Finished $dom\n"; } print STATUS "All done...\n"; close STATUS; close HTLIST; close PLCGI;