Rigs of Rods超长车辆名称远程缓冲区溢出漏洞
发布日期:2007-11-19
更新日期:2007-11-21
受影响系统:Rigs of Rods Rigs of Rods <= 0.33d
不受影响系统:Rigs of Rods Rigs of Rods 0.33d SP1
描述:
BUGTRAQ ID:
26502
Rigs of Rods(也被称为RoR)是一款卡车、汽车、飞机等驾驶游戏模拟器。
RoR在处理超长车辆名字字段时存在缓冲区溢出漏洞,远程攻击者可能利用此漏洞导致拒绝服务。
当玩家加入到服务器时,如果在发送的MSG2_USE_VEHICLE消息中包含有超长车辆名称的话,就可能在全局dbuffer缓冲区中触发溢出。 在queueMessage中的,当接收到MSG2_USE_VEHICLE消息时,首先在车辆名称中拷贝dbuffer,然后将昵称连接到dbuffer,这就允许攻击者用最多255个字节覆盖这个缓冲区。但由于这个溢出的性质,只可能导致拒绝服务。
以下代码源自sequencer.cpp:
void Sequencer::queueMessage(int pos, int type, char* data, unsigned int len)
{
pthread_mutex_lock(&clients_mutex);
if (type==MSG2_USE_VEHICLE)
{
data[len]=0;
strncpy(clients[pos].vehicle_name, data, 255);
//printStats();
//we alter the message to add user info
strcpy(data+len+1, clients[pos].nickname);
len+=(int)strlen(clients[pos].nickname)+2;
...
<*来源:Luigi Auriemma (
aluigi@pivx.com)
链接:
http://secunia.com/advisories/27729/
http://aluigi.altervista.org/adv/rorbof-adv.txt
*>
测试方法:
警 告
以下程序(方法)可能带有攻击性,仅供安全研究与教学之用。使用者风险自负!
http://aluigi.org/poc/rorbof.zip建议:
厂商补丁:
Rigs of Rods
------------
目前厂商已经发布了升级补丁以修复这个安全问题,请到厂商的主页下载:
http://repository.rigsofrods.com/files/RoRserver-0.33d-SP1.zip浏览次数:2581
严重程度:0(网友投票)