/Linux-v5.4/net/ipv4/netfilter/ |
D | nf_reject_ipv4.c | 15 const struct tcphdr *nf_reject_ip_tcphdr_get(struct sk_buff *oldskb, in nf_reject_ip_tcphdr_get() 16 struct tcphdr *_oth, int hook) in nf_reject_ip_tcphdr_get() 18 const struct tcphdr *oth; in nf_reject_ip_tcphdr_get() 28 sizeof(struct tcphdr), _oth); in nf_reject_ip_tcphdr_get() 70 const struct tcphdr *oth) in nf_reject_ip_tcphdr_put() 73 struct tcphdr *tcph; in nf_reject_ip_tcphdr_put() 76 tcph = skb_put_zero(nskb, sizeof(struct tcphdr)); in nf_reject_ip_tcphdr_put() 79 tcph->doff = sizeof(struct tcphdr) / 4; in nf_reject_ip_tcphdr_put() 91 tcph->check = ~tcp_v4_check(sizeof(struct tcphdr), niph->saddr, in nf_reject_ip_tcphdr_put() 95 nskb->csum_offset = offsetof(struct tcphdr, check); in nf_reject_ip_tcphdr_put() [all …]
|
D | nf_tproxy_ipv4.c | 23 struct tcphdr _hdr, *hp; in nf_tproxy_handle_time_wait4() 86 struct tcphdr _hdr, *hp; in nf_tproxy_get_sock_v4() 89 sizeof(struct tcphdr), &_hdr); in nf_tproxy_get_sock_v4()
|
/Linux-v5.4/net/ipv6/netfilter/ |
D | nf_reject_ipv6.c | 15 const struct tcphdr *nf_reject_ip6_tcphdr_get(struct sk_buff *oldskb, in nf_reject_ip6_tcphdr_get() 16 struct tcphdr *otcph, in nf_reject_ip6_tcphdr_get() 36 if (proto != IPPROTO_TCP || *otcplen < sizeof(struct tcphdr)) { in nf_reject_ip6_tcphdr_get() 42 otcph = skb_header_pointer(oldskb, tcphoff, sizeof(struct tcphdr), in nf_reject_ip6_tcphdr_get() 89 const struct tcphdr *oth, unsigned int otcplen) in nf_reject_ip6_tcphdr_put() 91 struct tcphdr *tcph; in nf_reject_ip6_tcphdr_put() 95 tcph = skb_put(nskb, sizeof(struct tcphdr)); in nf_reject_ip6_tcphdr_put() 97 tcph->doff = sizeof(struct tcphdr)/4; in nf_reject_ip6_tcphdr_put() 123 sizeof(struct tcphdr), IPPROTO_TCP, in nf_reject_ip6_tcphdr_put() 125 sizeof(struct tcphdr), 0)); in nf_reject_ip6_tcphdr_put() [all …]
|
D | nf_tproxy_ipv6.c | 46 struct tcphdr _hdr, *hp; in nf_tproxy_handle_time_wait6() 87 struct tcphdr _hdr, *hp; in nf_tproxy_get_sock_v6() 90 sizeof(struct tcphdr), &_hdr); in nf_tproxy_get_sock_v6()
|
/Linux-v5.4/include/net/netfilter/ |
D | nf_synproxy.h | 46 const struct tcphdr *th, 53 const struct tcphdr *th, 58 const struct tcphdr *th, 71 const struct tcphdr *th, 75 const struct tcphdr *th,
|
/Linux-v5.4/net/netfilter/ |
D | xt_TCPMSS.c | 78 struct tcphdr *tcph; in tcpmss_mangle_packet() 93 if (len < (int)sizeof(struct tcphdr)) in tcpmss_mangle_packet() 96 tcph = (struct tcphdr *)(skb_network_header(skb) + tcphoff); in tcpmss_mangle_packet() 99 if (len < tcp_hdrlen || tcp_hdrlen < sizeof(struct tcphdr)) in tcpmss_mangle_packet() 117 for (i = sizeof(struct tcphdr); i <= tcp_hdrlen - TCPOLEN_MSS; i += optlen(opt, i)) { in tcpmss_mangle_packet() 159 tcph = (struct tcphdr *)(skb_network_header(skb) + tcphoff); in tcpmss_mangle_packet() 176 opt = (u_int8_t *)tcph + sizeof(struct tcphdr); in tcpmss_mangle_packet() 177 memmove(opt + TCPOLEN_MSS, opt, len - sizeof(struct tcphdr)); in tcpmss_mangle_packet() 205 sizeof(*iph) + sizeof(struct tcphdr)); in tcpmss_tg4() 234 sizeof(*ipv6h) + sizeof(struct tcphdr)); in tcpmss_tg6()
|
D | nf_synproxy_core.c | 29 const struct tcphdr *th, struct synproxy_options *opts) in synproxy_parse_options() 110 synproxy_build_options(struct tcphdr *th, const struct synproxy_options *opts) in synproxy_build_options() 181 struct tcphdr *th, struct nf_conn *ct, in synproxy_tstamp_adjust() 191 optoff = protoff + sizeof(struct tcphdr); in synproxy_tstamp_adjust() 439 struct iphdr *niph, struct tcphdr *nth, in synproxy_send_tcp() 445 nskb->csum_offset = offsetof(struct tcphdr, check); in synproxy_send_tcp() 466 const struct sk_buff *skb, const struct tcphdr *th, in synproxy_send_client_synack() 471 struct tcphdr *nth; in synproxy_send_client_synack() 509 const struct sk_buff *skb, const struct tcphdr *th, in synproxy_send_server_syn() 515 struct tcphdr *nth; in synproxy_send_server_syn() [all …]
|
D | nf_log_common.c | 57 struct tcphdr _tcph; in nf_log_dump_tcp_header() 58 const struct tcphdr *th; in nf_log_dump_tcp_header() 107 if ((logflags & NF_LOG_TCPOPT) && th->doff*4 > sizeof(struct tcphdr)) { in nf_log_dump_tcp_header() 108 u_int8_t _opt[60 - sizeof(struct tcphdr)]; in nf_log_dump_tcp_header() 111 unsigned int optsize = th->doff*4 - sizeof(struct tcphdr); in nf_log_dump_tcp_header() 113 op = skb_header_pointer(skb, offset + sizeof(struct tcphdr), in nf_log_dump_tcp_header()
|
D | nfnetlink_osf.c | 165 static const struct tcphdr *nf_osf_hdr_ctx_init(struct nf_osf_hdr_ctx *ctx, in nf_osf_hdr_ctx_init() 170 const struct tcphdr *tcp; in nf_osf_hdr_ctx_init() 171 struct tcphdr _tcph; in nf_osf_hdr_ctx_init() 173 tcp = skb_header_pointer(skb, ip_hdrlen(skb), sizeof(struct tcphdr), &_tcph); in nf_osf_hdr_ctx_init() 184 if (tcp->doff * 4 > sizeof(struct tcphdr)) { in nf_osf_hdr_ctx_init() 185 ctx->optsize = tcp->doff * 4 - sizeof(struct tcphdr); in nf_osf_hdr_ctx_init() 188 sizeof(struct tcphdr), ctx->optsize, opts); in nf_osf_hdr_ctx_init() 207 const struct tcphdr *tcp; in nf_osf_match() 267 const struct tcphdr *tcp; in nf_osf_find()
|
D | xt_TCPOPTSTRIP.c | 34 struct tcphdr *tcph, _th; in tcpoptstrip_mangle_packet() 49 if (tcp_hdrlen < sizeof(struct tcphdr)) in tcpoptstrip_mangle_packet() 56 tcph = (struct tcphdr *)(skb_network_header(skb) + tcphoff); in tcpoptstrip_mangle_packet() 63 for (i = sizeof(struct tcphdr); i < tcp_hdrlen - 1; i += optl) { in tcpoptstrip_mangle_packet()
|
D | nf_conntrack_seqadj.c | 64 const struct tcphdr *th; in nf_ct_tcp_seqadj_set() 69 th = (struct tcphdr *)(skb_network_header(skb) + ip_hdrlen(skb)); in nf_ct_tcp_seqadj_set() 76 struct tcphdr *tcph, in nf_ct_sack_block_adjust() 122 struct tcphdr *tcph = (void *)skb->data + protoff; in nf_ct_sack_adjust() 126 optoff = protoff + sizeof(struct tcphdr); in nf_ct_sack_adjust() 169 struct tcphdr *tcph; in nf_ct_seq_adjust()
|
D | nft_synproxy.c | 24 const struct tcphdr *tcp, in nft_synproxy_tcp_options() 47 const struct tcphdr *tcp, in nft_synproxy_eval_v4() 48 struct tcphdr *_tcph, in nft_synproxy_eval_v4() 78 const struct tcphdr *tcp, in nft_synproxy_eval_v6() 79 struct tcphdr *_tcph, in nft_synproxy_eval_v6() 113 const struct tcphdr *tcp; in nft_synproxy_do_eval() 114 struct tcphdr _tcph; in nft_synproxy_do_eval() 127 sizeof(struct tcphdr), in nft_synproxy_do_eval()
|
D | xt_tcpudp.c | 41 u_int8_t _opt[60 - sizeof(struct tcphdr)]; in tcp_find_option() 50 op = skb_header_pointer(skb, protoff + sizeof(struct tcphdr), in tcp_find_option() 68 const struct tcphdr *th; in tcp_mt() 69 struct tcphdr _tcph; in tcp_mt()
|
D | nft_osf.c | 27 const struct tcphdr *tcp; in nft_osf_eval() 29 struct tcphdr _tcph; in nft_osf_eval() 32 sizeof(struct tcphdr), &_tcph); in nft_osf_eval()
|
/Linux-v5.4/include/net/netfilter/ipv4/ |
D | nf_reject.h | 13 const struct tcphdr *nf_reject_ip_tcphdr_get(struct sk_buff *oldskb, 14 struct tcphdr *_oth, int hook); 19 const struct tcphdr *oth);
|
/Linux-v5.4/include/net/netfilter/ipv6/ |
D | nf_reject.h | 13 const struct tcphdr *nf_reject_ip6_tcphdr_get(struct sk_buff *oldskb, 14 struct tcphdr *otcph, 21 const struct tcphdr *oth, unsigned int otcplen);
|
/Linux-v5.4/tools/testing/selftests/bpf/progs/ |
D | test_pkt_access.c | 26 struct tcphdr *tcp = NULL; in process() 40 tcp = (struct tcphdr *)((void *)(iph) + ihl_len); in process() 48 tcp = (struct tcphdr *)((void *)(ip6h) + ihl_len); in process()
|
D | test_tcpbpf_kern.c | 56 char header[sizeof(struct ipv6hdr) + sizeof(struct tcphdr)]; in bpf_testcb() 57 struct tcphdr *thdr; in bpf_testcb() 99 sizeof(struct tcphdr))); in bpf_testcb() 103 thdr = (struct tcphdr *)(header + offset); in bpf_testcb()
|
/Linux-v5.4/net/ipv4/ |
D | tcp_offload.c | 35 if (!pskb_may_pull(skb, sizeof(struct tcphdr))) in tcp4_gso_segment() 40 struct tcphdr *th = tcp_hdr(skb); in tcp4_gso_segment() 59 struct tcphdr *th; in tcp_gso_segment() 184 struct tcphdr *th; in tcp_gro_receive() 185 struct tcphdr *th2; in tcp_gro_receive() 290 struct tcphdr *th = tcp_hdr(skb); in tcp_gro_complete() 293 skb->csum_offset = offsetof(struct tcphdr, check); in tcp_gro_complete() 322 struct tcphdr *th = tcp_hdr(skb); in tcp4_gro_complete()
|
D | tcp_ipv4.c | 87 __be32 daddr, __be32 saddr, const struct tcphdr *th); 427 struct tcphdr *th = (struct tcphdr *)(icmp_skb->data + (iph->ihl << 2)); in tcp_v4_err() 622 struct tcphdr *th = tcp_hdr(skb); in __tcp_v4_send_check() 626 skb->csum_offset = offsetof(struct tcphdr, check); in __tcp_v4_send_check() 653 const struct tcphdr *th = tcp_hdr(skb); in tcp_v4_send_reset() 655 struct tcphdr th; in tcp_v4_send_reset() 686 rep.th.doff = sizeof(struct tcphdr) / 4; in tcp_v4_send_reset() 754 arg.csumoffset = offsetof(struct tcphdr, check) / 2; in tcp_v4_send_reset() 808 const struct tcphdr *th = tcp_hdr(skb); in tcp_v4_send_ack() 810 struct tcphdr th; in tcp_v4_send_ack() [all …]
|
/Linux-v5.4/net/ipv6/ |
D | tcpv6_offload.c | 32 struct tcphdr *th = tcp_hdr(skb); in tcp6_gro_complete() 44 struct tcphdr *th; in tcp6_gso_segment() 54 struct tcphdr *th = tcp_hdr(skb); in tcp6_gso_segment()
|
D | tcp_ipv6.c | 301 tp->rx_opt.mss_clamp = IPV6_MIN_MTU - sizeof(struct tcphdr) - sizeof(struct ipv6hdr); in tcp_v6_connect() 364 const struct tcphdr *th = (struct tcphdr *)(skb->data+offset); in tcp_v6_err() 596 const struct tcphdr *th, int nbytes) in tcp_v6_md5_hash_headers() 600 struct tcphdr *_th; in tcp_v6_md5_hash_headers() 609 _th = (struct tcphdr *)(bp + 1); in tcp_v6_md5_hash_headers() 621 const struct tcphdr *th) in tcp_v6_md5_hash_hdr() 659 const struct tcphdr *th = tcp_hdr(skb); in tcp_v6_md5_hash_skb() 707 const struct tcphdr *th = tcp_hdr(skb); in tcp_v6_inbound_md5_hash() 789 .mss_clamp = IPV6_MIN_MTU - sizeof(struct tcphdr) - 810 const struct tcphdr *th = tcp_hdr(skb); in tcp_v6_send_response() [all …]
|
/Linux-v5.4/include/linux/ |
D | netfilter_ipv6.h | 52 const struct tcphdr *th, u16 *mssp); 54 const struct tcphdr *th, __u32 cookie); 183 const struct tcphdr *th, in nf_ipv6_cookie_init_sequence() 200 const struct tcphdr *th, __u32 cookie) in nf_cookie_v6_check()
|
/Linux-v5.4/net/bridge/netfilter/ |
D | nft_reject_bridge.c | 70 const struct tcphdr *oth; in nft_reject_br_send_v4_tcp_reset() 71 struct tcphdr _oth; in nft_reject_br_send_v4_tcp_reset() 80 nskb = alloc_skb(sizeof(struct iphdr) + sizeof(struct tcphdr) + in nft_reject_br_send_v4_tcp_reset() 184 const struct tcphdr *oth; in nft_reject_br_send_v6_tcp_reset() 185 struct tcphdr _oth; in nft_reject_br_send_v6_tcp_reset() 196 nskb = alloc_skb(sizeof(struct ipv6hdr) + sizeof(struct tcphdr) + in nft_reject_br_send_v6_tcp_reset()
|
/Linux-v5.4/net/ipv6/ila/ |
D | ila_common.c | 83 if (likely(pskb_may_pull(skb, nhoff + sizeof(struct tcphdr)))) { in ila_csum_adjust_transport() 84 struct tcphdr *th = (struct tcphdr *) in ila_csum_adjust_transport()
|