tag | line | file | source code |
th | 36 | net/inet/skbuff.h | struct tcphdr *th; |
th | 226 | net/inet/slhc.c | struct tcphdr *th, *oth; |
th | 244 | net/inet/slhc.c | th = (struct tcphdr *)(((unsigned char *)ip) + ip->ihl*4); |
th | 245 | net/inet/slhc.c | hlen = ip->ihl*4 + th->doff*4; |
th | 250 | net/inet/slhc.c | if(th->syn || th->fin || th->rst || |
th | 251 | net/inet/slhc.c | ! (th->ack)){ |
th | 252 | net/inet/slhc.c | DPRINT(("comp: noncomp 2 %x %x %d %d %d %d\n", ip, th, |
th | 253 | net/inet/slhc.c | th->syn, th->fin, th->rst, th->ack)); |
th | 275 | net/inet/slhc.c | && th->source == cs->cs_tcp.source |
th | 276 | net/inet/slhc.c | && th->dest == cs->cs_tcp.dest) |
th | 335 | net/inet/slhc.c | || th->doff != cs->cs_tcp.doff |
th | 337 | net/inet/slhc.c | || (th->doff > 5 && memcmp(th+1,cs->cs_tcpopt,((th->doff)-5)*4 != 0))){ |
th | 348 | net/inet/slhc.c | if(th->urg){ |
th | 349 | net/inet/slhc.c | deltaS = ntohs(th->urg_ptr); |
th | 352 | net/inet/slhc.c | } else if(th->urg_ptr != oth->urg_ptr){ |
th | 360 | net/inet/slhc.c | if((deltaS = ntohs(th->window) - ntohs(oth->window)) != 0){ |
th | 364 | net/inet/slhc.c | if((deltaA = ntohl(th->ack_seq) - ntohl(oth->ack_seq)) != 0L){ |
th | 370 | net/inet/slhc.c | if((deltaS = ntohl(th->seq) - ntohl(oth->seq)) != 0L){ |
th | 419 | net/inet/slhc.c | if(th->psh) |
th | 424 | net/inet/slhc.c | deltaA = ntohs(th->check); |
th | 426 | net/inet/slhc.c | memcpy(&cs->cs_tcp,th,20); |
th | 460 | net/inet/slhc.c | memcpy(&cs->cs_tcp,th,20); |
th | 463 | net/inet/slhc.c | if (th->doff > 5) |
th | 464 | net/inet/slhc.c | memcpy(cs->cs_tcpopt, th+1, ((th->doff) - 5) * 4); |
th | 66 | net/inet/slip.c | struct tcphdr *th; |
th | 72 | net/inet/slip.c | th = (struct tcphdr *) (ptr + ip->ihl * 4); |
th | 75 | net/inet/slip.c | ntohl(th->seq), ntohl(th->ack_seq), ntohs(ip->tot_len)); |
th | 57 | net/inet/tcp.c | print_th(struct tcphdr *th) |
th | 64 | net/inet/tcp.c | ptr =(unsigned char *)(th + 1); |
th | 66 | net/inet/tcp.c | ntohs(th->source), ntohs(th->dest), |
th | 67 | net/inet/tcp.c | ntohl(th->seq), ntohl(th->ack_seq)); |
th | 69 | net/inet/tcp.c | th->fin, th->syn, th->rst, th->psh, th->ack, |
th | 70 | net/inet/tcp.c | th->urg, th->res1, th->res2); |
th | 72 | net/inet/tcp.c | ntohs(th->window), ntohs(th->check), ntohs(th->urg_ptr)); |
th | 73 | net/inet/tcp.c | printk(" doff = %d\n", th->doff); |
th | 151 | net/inet/tcp.c | struct tcphdr *th; |
th | 157 | net/inet/tcp.c | th =(struct tcphdr *)header; |
th | 158 | net/inet/tcp.c | sk = get_sock(&tcp_prot, th->dest, saddr, th->source, daddr); |
th | 159 | net/inet/tcp.c | print_th(th); |
th | 215 | net/inet/tcp.c | if (before(counted, skb->h.th->seq)) break; |
th | 216 | net/inet/tcp.c | sum = skb->len -(counted - skb->h.th->seq); |
th | 217 | net/inet/tcp.c | if (skb->h.th->syn) sum++; |
th | 218 | net/inet/tcp.c | if (skb->h.th->urg) { |
th | 219 | net/inet/tcp.c | sum -= ntohs(skb->h.th->urg_ptr); |
th | 223 | net/inet/tcp.c | if (skb->h.th->syn) amount--; |
th | 226 | net/inet/tcp.c | if (amount && skb->h.th->psh) break; |
th | 347 | net/inet/tcp.c | if (sk->copied_seq+1 == skb->h.th->seq && |
th | 348 | net/inet/tcp.c | skb->h.th->urg) answ = 1; |
th | 375 | net/inet/tcp.c | tcp_check(struct tcphdr *th, int len, |
th | 381 | net/inet/tcp.c | print_th(th); |
th | 396 | net/inet/tcp.c | : "=b"(sum) , "=S"(th) |
th | 397 | net/inet/tcp.c | : "0"(sum), "c"(len/4) ,"1"(th) |
th | 415 | net/inet/tcp.c | : "=b"(sum), "=S"(th) |
th | 416 | net/inet/tcp.c | : "0"(sum) ,"1"(th) |
th | 427 | net/inet/tcp.c | : "0"(sum) ,"S"(th) |
th | 437 | net/inet/tcp.c | tcp_send_check(struct tcphdr *th, unsigned long saddr, |
th | 440 | net/inet/tcp.c | th->check = 0; |
th | 442 | net/inet/tcp.c | th->check = tcp_check(th, len, saddr, daddr); |
th | 457 | net/inet/tcp.c | tcp_send_check(skb->h.th, sk->saddr, sk->daddr, |
th | 458 | net/inet/tcp.c | skb->len-(unsigned long)skb->h.th + |
th | 487 | net/inet/tcp.c | struct tcphdr *th, unsigned long daddr) |
th | 528 | net/inet/tcp.c | memcpy(t1, th, sizeof(*t1)); /* this should probably be removed */ |
th | 531 | net/inet/tcp.c | t1->dest = th->source; |
th | 532 | net/inet/tcp.c | t1->source = th->dest; |
th | 563 | net/inet/tcp.c | tcp_build_header(struct tcphdr *th, struct sock *sk, int push) |
th | 567 | net/inet/tcp.c | memcpy(th,(void *) &(sk->dummy_th), sizeof(*th)); |
th | 568 | net/inet/tcp.c | th->seq = ntohl(sk->send_seq); |
th | 569 | net/inet/tcp.c | th->psh =(push == 0) ? 1 : 0; |
th | 570 | net/inet/tcp.c | th->doff = sizeof(*th)/4; |
th | 571 | net/inet/tcp.c | th->ack = 1; |
th | 572 | net/inet/tcp.c | th->fin = 0; |
th | 576 | net/inet/tcp.c | th->ack_seq = ntohl(sk->acked_seq); |
th | 578 | net/inet/tcp.c | th->window = ntohs(sk->window); |
th | 580 | net/inet/tcp.c | return(sizeof(*th)); |
th | 702 | net/inet/tcp.c | if (skb->len -(unsigned long)skb->h.th + |
th | 796 | net/inet/tcp.c | skb->h.th =(struct tcphdr *) buff; |
th | 1067 | net/inet/tcp.c | if (skb->h.th->urg && !skb->urg_used) { |
th | 1068 | net/inet/tcp.c | if (skb->h.th->urg_ptr == 0) { |
th | 1069 | net/inet/tcp.c | skb->h.th->urg_ptr = ntohs(skb->len); |
th | 1071 | net/inet/tcp.c | amt = min(ntohs(skb->h.th->urg_ptr),len); |
th | 1073 | net/inet/tcp.c | memcpy_tofs(to,(unsigned char *)(skb->h.th) + |
th | 1074 | net/inet/tcp.c | skb->h.th->doff*4, amt); |
th | 1125 | net/inet/tcp.c | before(sk->copied_seq+1, skb->h.th->seq) || skb->used) { |
th | 1195 | net/inet/tcp.c | before(sk->copied_seq+1, sk->rqueue->next->h.th->seq)) { |
th | 1221 | net/inet/tcp.c | offset = sk->copied_seq+1 - skb->h.th->seq; |
th | 1223 | net/inet/tcp.c | if (skb->h.th->syn) offset--; |
th | 1229 | net/inet/tcp.c | if (skb->h.th->urg) { |
th | 1231 | net/inet/tcp.c | sk->copied_seq += ntohs(skb->h.th->urg_ptr); |
th | 1232 | net/inet/tcp.c | offset += ntohs(skb->h.th->urg_ptr); |
th | 1247 | net/inet/tcp.c | memcpy_tofs(to,((unsigned char *)skb->h.th) + |
th | 1248 | net/inet/tcp.c | skb->h.th->doff*4 + offset, used); |
th | 1260 | net/inet/tcp.c | (!skb->h.th->urg || skb->urg_used) && |
th | 1267 | net/inet/tcp.c | if (skb->h.th->psh || skb->h.th->urg) { |
th | 1291 | net/inet/tcp.c | struct tcphdr *t1, *th; |
th | 1312 | net/inet/tcp.c | th =(struct tcphdr *)&sk->dummy_th; |
th | 1340 | net/inet/tcp.c | memcpy(t1, th, sizeof(*t1)); |
th | 1397 | net/inet/tcp.c | tcp_reset(unsigned long saddr, unsigned long daddr, struct tcphdr *th, |
th | 1430 | net/inet/tcp.c | memcpy(t1, th, sizeof(*t1)); |
th | 1433 | net/inet/tcp.c | t1->dest = th->source; |
th | 1434 | net/inet/tcp.c | t1->source = th->dest; |
th | 1435 | net/inet/tcp.c | t1->seq = th->ack_seq; /* add one so it will be in the right range */ |
th | 1436 | net/inet/tcp.c | t1->ack_seq = htonl(ntohl(th->seq)+1); |
th | 1438 | net/inet/tcp.c | t1->ack_seq = htonl(ntohl(th->seq)+1); /* send correct ack -FB */ |
th | 1467 | net/inet/tcp.c | struct tcphdr *th; |
th | 1474 | net/inet/tcp.c | th = skb->h.th; |
th | 1481 | net/inet/tcp.c | tcp_reset(daddr, saddr, th, sk->prot, opt, dev); |
th | 1534 | net/inet/tcp.c | newsk->acked_seq = skb->h.th->seq+1; |
th | 1535 | net/inet/tcp.c | newsk->fin_seq = skb->h.th->seq; |
th | 1536 | net/inet/tcp.c | newsk->copied_seq = skb->h.th->seq; |
th | 1546 | net/inet/tcp.c | newsk->dummy_th.source = skb->h.th->dest; |
th | 1547 | net/inet/tcp.c | newsk->dummy_th.dest = skb->h.th->source; |
th | 1563 | net/inet/tcp.c | newsk->acked_seq = skb->h.th->seq + 1; |
th | 1564 | net/inet/tcp.c | newsk->copied_seq = skb->h.th->seq; |
th | 1566 | net/inet/tcp.c | if (skb->h.th->doff == 5) { |
th | 1569 | net/inet/tcp.c | ptr =(unsigned char *)(skb->h.th + 1); |
th | 1613 | net/inet/tcp.c | memcpy(t1, skb->h.th, sizeof(*t1)); |
th | 1617 | net/inet/tcp.c | t1->dest = skb->h.th->source; |
th | 1629 | net/inet/tcp.c | t1->ack_seq = ntohl(skb->h.th->seq+1); |
th | 1668 | net/inet/tcp.c | struct tcphdr *t1, *th; |
th | 1694 | net/inet/tcp.c | after(skb->h.th->seq + skb->len + 1, sk->copied_seq)) |
th | 1734 | net/inet/tcp.c | th =(struct tcphdr *)&sk->dummy_th; |
th | 1764 | net/inet/tcp.c | memcpy(t1, th, sizeof(*t1)); |
th | 1877 | net/inet/tcp.c | tcp_ack(struct sock *sk, struct tcphdr *th, unsigned long saddr, int len) |
th | 1882 | net/inet/tcp.c | ack = ntohl(th->ack_seq); |
th | 1885 | net/inet/tcp.c | ack, ntohs(th->window), sk->rcv_ack_seq, sk->window_seq)); |
th | 1898 | net/inet/tcp.c | if (len != th->doff*4) flag |= 1; |
th | 1901 | net/inet/tcp.c | if (after(sk->window_seq, ack+ntohs(th->window))) { |
th | 1919 | net/inet/tcp.c | sk->window_seq = ack + ntohs(th->window); |
th | 1983 | net/inet/tcp.c | sk->window_seq = ack + ntohs(th->window); |
th | 2130 | net/inet/tcp.c | th, sk->daddr); |
th | 2159 | net/inet/tcp.c | struct tcphdr *th; |
th | 2161 | net/inet/tcp.c | th = skb->h.th; |
th | 2162 | net/inet/tcp.c | print_th(th); |
th | 2163 | net/inet/tcp.c | skb->len = len -(th->doff*4); |
th | 2168 | net/inet/tcp.c | if (skb->len == 0 && !th->fin && !th->urg && !th->psh) { |
th | 2170 | net/inet/tcp.c | if (!th->ack) tcp_send_ack(sk->send_seq, sk->acked_seq,sk, th, saddr); |
th | 2176 | net/inet/tcp.c | sk->acked_seq = th->seq + skb->len + th->syn + th->fin; |
th | 2177 | net/inet/tcp.c | tcp_reset(sk->saddr, sk->daddr, skb->h.th, |
th | 2209 | net/inet/tcp.c | DPRINTF((DBG_TCP, "skb1->h.th->seq = %d\n", skb1->h.th->seq)); |
th | 2210 | net/inet/tcp.c | if (after(th->seq+1, skb1->h.th->seq)) { |
th | 2231 | net/inet/tcp.c | th->ack_seq = th->seq + skb->len; |
th | 2232 | net/inet/tcp.c | if (th->syn) th->ack_seq++; |
th | 2233 | net/inet/tcp.c | if (th->fin) th->ack_seq++; |
th | 2241 | net/inet/tcp.c | if (skb1 == NULL || skb1->acked || before(th->seq, sk->acked_seq+1)) { |
th | 2242 | net/inet/tcp.c | if (before(th->seq, sk->acked_seq+1)) { |
th | 2243 | net/inet/tcp.c | if (after(th->ack_seq, sk->acked_seq)) |
th | 2244 | net/inet/tcp.c | sk->acked_seq = th->ack_seq; |
th | 2248 | net/inet/tcp.c | if (skb->h.th->fin) { |
th | 2256 | net/inet/tcp.c | if (before(skb2->h.th->seq, sk->acked_seq+1)) { |
th | 2257 | net/inet/tcp.c | if (after(skb2->h.th->ack_seq, sk->acked_seq)) |
th | 2258 | net/inet/tcp.c | sk->acked_seq = skb2->h.th->ack_seq; |
th | 2265 | net/inet/tcp.c | if (skb2->h.th->fin) { |
th | 2283 | net/inet/tcp.c | sk->bytes_rcv > sk->max_unacked || th->fin) { |
th | 2322 | net/inet/tcp.c | tcp_send_ack(sk->send_seq, sk->acked_seq, sk, th, saddr); |
th | 2327 | net/inet/tcp.c | tcp_send_ack(sk->send_seq, sk->acked_seq, sk, th, saddr); |
th | 2352 | net/inet/tcp.c | tcp_urg(struct sock *sk, struct tcphdr *th, unsigned long saddr) |
th | 2360 | net/inet/tcp.c | th->urg = 0; |
th | 2361 | net/inet/tcp.c | th->psh = 1; |
th | 2382 | net/inet/tcp.c | tcp_fin(struct sock *sk, struct tcphdr *th, |
th | 2386 | net/inet/tcp.c | sk, th, saddr, dev)); |
th | 2397 | net/inet/tcp.c | sk->fin_seq = th->seq+1; |
th | 2399 | net/inet/tcp.c | if (th->rst) sk->shutdown = SHUTDOWN_MASK; |
th | 2408 | net/inet/tcp.c | sk->fin_seq = th->seq+1; |
th | 2574 | net/inet/tcp.c | tcp_sequence(struct sock *sk, struct tcphdr *th, short len, |
th | 2584 | net/inet/tcp.c | sk, th, len, opt, saddr)); |
th | 2586 | net/inet/tcp.c | if (between(th->seq, sk->acked_seq, sk->acked_seq + sk->window)|| |
th | 2587 | net/inet/tcp.c | between(th->seq + len-(th->doff*4), sk->acked_seq + 1, |
th | 2589 | net/inet/tcp.c | (before(th->seq, sk->acked_seq) && |
th | 2590 | net/inet/tcp.c | after(th->seq + len -(th->doff*4), sk->acked_seq + sk->window))) { |
th | 2599 | net/inet/tcp.c | if (after(th->seq, sk->acked_seq + sk->window)) { |
th | 2600 | net/inet/tcp.c | tcp_send_ack(sk->send_seq, sk->acked_seq, sk, th, saddr); |
th | 2605 | net/inet/tcp.c | if (th->ack && len == (th->doff * 4) && |
th | 2606 | net/inet/tcp.c | after(th->seq, sk->acked_seq - 32767) && |
th | 2607 | net/inet/tcp.c | !th->fin && !th->syn) return(1); |
th | 2609 | net/inet/tcp.c | if (!th->rst) { |
th | 2611 | net/inet/tcp.c | tcp_send_ack(sk->send_seq, sk->acked_seq, sk, th, saddr); |
th | 2619 | net/inet/tcp.c | tcp_options(struct sock *sk, struct tcphdr *th) |
th | 2623 | net/inet/tcp.c | ptr = (unsigned char *)(th + 1); |
th | 2637 | net/inet/tcp.c | struct tcphdr *th; |
th | 2658 | net/inet/tcp.c | th = skb->h.th; |
th | 2661 | net/inet/tcp.c | sk = get_sock(&tcp_prot, th->dest, saddr, th->source, daddr); |
th | 2670 | net/inet/tcp.c | if (th->check && tcp_check(th, len, saddr, daddr )) { |
th | 2684 | net/inet/tcp.c | if (!th->rst) tcp_reset(daddr, saddr, th, &tcp_prot, opt,dev); |
th | 2699 | net/inet/tcp.c | th->seq = ntohl(th->seq); |
th | 2750 | net/inet/tcp.c | if (th->rst) { |
th | 2767 | net/inet/tcp.c | if (!tcp_sequence(sk, th, len, opt, saddr)) { |
th | 2770 | net/inet/tcp.c | sk, th, saddr); |
th | 2776 | net/inet/tcp.c | if (th->rst) { |
th | 2802 | net/inet/tcp.c | opt->compartment != 0 || th->syn)) { |
th | 2806 | net/inet/tcp.c | tcp_reset(daddr, saddr, th, sk->prot, opt,dev); |
th | 2815 | net/inet/tcp.c | if (th->ack) { |
th | 2816 | net/inet/tcp.c | if (!tcp_ack(sk, th, saddr, len)) { |
th | 2822 | net/inet/tcp.c | if (th->urg) { |
th | 2823 | net/inet/tcp.c | if (tcp_urg(sk, th, saddr)) { |
th | 2830 | net/inet/tcp.c | if (th->fin && tcp_fin(sk, th, saddr, dev)) { |
th | 2853 | net/inet/tcp.c | if (!th->rst) { |
th | 2854 | net/inet/tcp.c | if (!th->ack) |
th | 2855 | net/inet/tcp.c | th->ack_seq = 0; |
th | 2856 | net/inet/tcp.c | tcp_reset(daddr, saddr, th, sk->prot, opt,dev); |
th | 2863 | net/inet/tcp.c | if (th->rst) { |
th | 2868 | net/inet/tcp.c | if (th->ack) { |
th | 2869 | net/inet/tcp.c | tcp_reset(daddr, saddr, th, sk->prot, opt,dev); |
th | 2875 | net/inet/tcp.c | if (th->syn) { |
th | 2878 | net/inet/tcp.c | tcp_reset(daddr, saddr, th, prot, opt,dev); |
th | 2900 | net/inet/tcp.c | if (!tcp_sequence(sk, th, len, opt, saddr)) { |
th | 2907 | net/inet/tcp.c | if (th->rst) { |
th | 2923 | net/inet/tcp.c | tcp_reset(daddr, saddr, th, sk->prot, opt, dev); |
th | 2932 | net/inet/tcp.c | if (!th->ack) { |
th | 2933 | net/inet/tcp.c | if (th->syn) { |
th | 2944 | net/inet/tcp.c | if (!tcp_ack(sk, th, saddr, len)) { |
th | 2945 | net/inet/tcp.c | tcp_reset(daddr, saddr, th, |
th | 2956 | net/inet/tcp.c | if (!th->syn) { |
th | 2963 | net/inet/tcp.c | sk->acked_seq = th->seq+1; |
th | 2964 | net/inet/tcp.c | sk->fin_seq = th->seq; |
th | 2965 | net/inet/tcp.c | tcp_send_ack(sk->send_seq, th->seq+1, |
th | 2966 | net/inet/tcp.c | sk, th, sk->daddr); |
th | 2969 | net/inet/tcp.c | if (!tcp_ack(sk, th, saddr, len)) { |
th | 2970 | net/inet/tcp.c | tcp_reset(daddr, saddr, th, |
th | 2983 | net/inet/tcp.c | tcp_options(sk, th); |
th | 2984 | net/inet/tcp.c | sk->dummy_th.dest = th->source; |
th | 2994 | net/inet/tcp.c | if (th->urg) { |
th | 2995 | net/inet/tcp.c | if (tcp_urg(sk, th, saddr)) { |
th | 3004 | net/inet/tcp.c | if (th->fin) tcp_fin(sk, th, saddr, dev); |
th | 3009 | net/inet/tcp.c | if (th->urg) { |
th | 3010 | net/inet/tcp.c | if (tcp_urg(sk, th, saddr)) { |
th | 3023 | net/inet/tcp.c | if (!th->fin) { |
th | 3027 | net/inet/tcp.c | tcp_fin(sk, th, saddr, dev); |
th | 95 | net/inet/udp.c | struct udphdr *th; |
th | 102 | net/inet/udp.c | th = (struct udphdr *)header; |
th | 103 | net/inet/udp.c | sk = get_sock(&udp_prot, th->dest, saddr, th->source, daddr); |