HEX
Server: Apache
System: Linux viper.innovativeinternet.net 4.18.0-553.80.1.lve.el8.x86_64 #1 SMP Wed Oct 22 19:29:36 UTC 2025 x86_64
User: thetradingroom (1095)
PHP: 8.3.25
Disabled: exec,passthru,shell_exec,system
Upload Files
File: //ibin/bw2.pl
#!/usr/bin/perl

open(IN,"</var/log/httpd/apache_log") || die "can't open /var/log/httpd/access_log $!";

%data = ();
while(<IN>) {
	$line = $_;
	@ara = split(/\s+/,$line);
	$domain = $ara[0];
	$bytes  = $ara[10];
	$data{$domain} += $bytes;
}
close IN;


while (($key, $value) = each(%data)){
     if ($value > 0) {
         $value = sprintf("%0.2f",$value/1024.0/1024.0);
	 $value = "$value MB";
     }
     print $key.": ".$value."\n";
}