!C99Shell v. 2.0 [PHP 7 Update] [25.02.2019]!

Software: Apache/2.4.18 (Ubuntu). PHP/7.0.33-0ubuntu0.16.04.16 

uname -a: Linux digifus 3.13.0-57-generic #95-Ubuntu SMP Fri Jun 19 09:28:15 UTC 2015 x86_64 

uid=33(www-data) gid=33(www-data) groups=33(www-data) 

Safe-mode: OFF (not secure)

/usr/share/doc/uwsgi-core/tests/t/   drwxr-xr-x
Free 9.79 GB of 29.4 GB (33.31%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     static.pl (1.81 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
use IO::Socket::INET;
use Digest::MD5 qw(md5) ;

$NUM = 50;

my @commands;

push @commands, "./uwsgi --http-socket :9191 --disable-logging --static-offload-to-thread 64 --static-map /foobar=./t_foobar.txt --pidfile ./t_foobar.pid &";
push @commands, "./uwsgi --http-socket :9191 --disable-logging -M -p 4 --static-offload-to-thread 64 --static-map /foobar=./t_foobar.txt --pidfile ./t_foobar.pid &";
push @commands, "./uwsgi --http :9191 --disable-logging --static-map /foobar=./t_foobar.txt --static-offload-to-thread 64 --pidfile ./t_foobar.pid &";

print "generating random data for the test...\n";

my $content = generate_random_content(1024*1024);
my $first_digest = md5($content);

open FOOBAR,'>t_foobar.txt';
print FOOBAR $content;
close FOOBAR;

foreach my $cmd(@commands) {

    system $cmd;
    sleep(1);


    my @s;

    print "sending requests to uWSGI...\n";

    for(my $i=0;$i<$NUM;$i++) {
        $s[$i] = IO::Socket::INET->new(PeerAddr => '127.0.0.1', PeerPort => 9191);    
        $s[$i]->send("GET /foobar HTTP/1.0\r\nHost: 127.0.0.1:9191\r\n\r\n");
    }

    my @body;

    print "receiving responses from uWSGI...\n";

    while(1) {
        $end = 0;
        for(my $i=0;$i<$NUM;$i++) {
            $s[$i]->recv(my $buf, 32768);
            $end++ unless $buf;
            $body[$i].=$buf;
        }
        last if $end >= $NUM;
    }

    print "checking uWSGI responses...\n";

    foreach my $data (@body) {
        $data =~ s/^(.|\n|\r)*\r\n\r\n//m;
        if (md5($data) ne $first_digest) {
            end_test("md5 does not match");
        }
    }

    system('kill -INT `cat t_foobar.pid`');

    sleep(3);
}

print "TEST PASSED\n";

sub generate_random_content {
    my $size = shift;
    my @chars=('a'..'z','A'..'Z','0'..'9');
    my $random_string = '';
    foreach (1..$size) {
        $random_string.=$chars[rand @chars];
    }

    return $random_string;
}

sub end_test {
    my $msg = shift;
    print 'TEST FAILED: '.$msg."\n";
    system('kill -INT `cat t_foobar.pid`');
    exit;
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 2.0 [PHP 7 Update] [25.02.2019] maintained by KaizenLouie | C99Shell Github | Generation time: 0.0046 ]--