Home
last modified time | relevance | path

Searched refs:tcphdr (Results 1 – 25 of 189) sorted by relevance

12345678

/kernel/linux/linux-5.10/net/ipv4/netfilter/
Dnf_reject_ipv4.c15 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 …]
Dnf_tproxy_ipv4.c23 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()
/kernel/linux/linux-5.10/net/ipv6/netfilter/
Dnf_reject_ipv6.c15 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 …]
/kernel/linux/linux-5.10/include/net/netfilter/
Dnf_synproxy.h46 const struct tcphdr *th,
53 const struct tcphdr *th,
58 const struct tcphdr *th,
71 const struct tcphdr *th,
75 const struct tcphdr *th,
/kernel/linux/linux-5.10/net/netfilter/
Dxt_TCPMSS.c78 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()
Dnfnetlink_osf.c165 static const struct tcphdr *nf_osf_hdr_ctx_init(struct nf_osf_hdr_ctx *ctx, in nf_osf_hdr_ctx_init()
169 struct tcphdr *_tcph) in nf_osf_hdr_ctx_init()
171 const struct tcphdr *tcp; 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()
209 const struct tcphdr *tcp; in nf_osf_match()
210 struct tcphdr _tcph; in nf_osf_match()
270 const struct tcphdr *tcp; in nf_osf_find()
[all …]
Dnf_synproxy_core.c29 const struct tcphdr *th, struct synproxy_options *opts) in synproxy_parse_options()
115 synproxy_build_options(struct tcphdr *th, const struct synproxy_options *opts) in synproxy_build_options()
186 struct tcphdr *th, struct nf_conn *ct, in synproxy_tstamp_adjust()
196 optoff = protoff + sizeof(struct tcphdr); in synproxy_tstamp_adjust()
444 struct iphdr *niph, struct tcphdr *nth, in synproxy_send_tcp()
450 nskb->csum_offset = offsetof(struct tcphdr, check); in synproxy_send_tcp()
471 const struct sk_buff *skb, const struct tcphdr *th, in synproxy_send_client_synack()
476 struct tcphdr *nth; in synproxy_send_client_synack()
514 const struct sk_buff *skb, const struct tcphdr *th, in synproxy_send_server_syn()
520 struct tcphdr *nth; in synproxy_send_server_syn()
[all …]
Dnf_log_common.c57 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()
Dxt_TCPOPTSTRIP.c34 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()
Dnf_conntrack_seqadj.c64 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()
Dnft_synproxy.c24 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()
Dxt_tcpudp.c41 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()
/kernel/linux/linux-5.10/include/net/netfilter/ipv4/
Dnf_reject.h13 const struct tcphdr *nf_reject_ip_tcphdr_get(struct sk_buff *oldskb,
14 struct tcphdr *_oth, int hook);
19 const struct tcphdr *oth);
/kernel/linux/linux-5.10/include/net/netfilter/ipv6/
Dnf_reject.h13 const struct tcphdr *nf_reject_ip6_tcphdr_get(struct sk_buff *oldskb,
14 struct tcphdr *otcph,
21 const struct tcphdr *oth, unsigned int otcplen);
/kernel/linux/linux-5.10/tools/testing/selftests/bpf/progs/
Dtest_pkt_access.c87 struct tcphdr *tcp = NULL; in test_pkt_write_access_subprog()
106 struct tcphdr *tcp = NULL; in test_pkt_access()
120 tcp = (struct tcphdr *)((void *)(iph) + ihl_len); in test_pkt_access()
128 tcp = (struct tcphdr *)((void *)(ip6h) + ihl_len); in test_pkt_access()
Dtest_tcpbpf_kern.c56 char header[sizeof(struct ipv6hdr) + sizeof(struct tcphdr)]; in bpf_testcb()
58 struct tcphdr *thdr; in bpf_testcb()
140 sizeof(struct tcphdr))); in bpf_testcb()
144 thdr = (struct tcphdr *)(header + offset); in bpf_testcb()
Dcgroup_skb_sk_lookup_kern.c32 const struct tcphdr *tcph) in set_tuple()
42 const struct tcphdr *tcph) in is_allowed_peer_cg()
72 struct tcphdr tcph; in ingress_lookup()
Dtest_btf_skc_cls_ingress.c27 static void test_syncookie_helper(struct ipv6hdr *ip6h, struct tcphdr *th, in test_syncookie_helper()
74 struct tcphdr *th; in handle_ip6_tcp()
79 th = (struct tcphdr *)(ip6h + 1); in handle_ip6_tcp()
Dtest_misc_tcp_hdr_options.c35 struct tcphdr th; in __check_active_hdr_in()
42 struct tcphdr *pth; in __check_active_hdr_in()
110 pth = (struct tcphdr *)(&hdr.ip6 + 1); in __check_active_hdr_in()
131 struct tcphdr *th; in check_active_hdr_in()
171 struct tcphdr *th; in write_active_opt()
/kernel/linux/linux-5.10/net/ipv4/
Dtcp_offload.c35 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()
325 struct tcphdr *th = tcp_hdr(skb); in tcp4_gro_complete()
Dtcp_ipv4.c88 __be32 daddr, __be32 saddr, const struct tcphdr *th);
468 struct tcphdr *th = (struct tcphdr *)(skb->data + (iph->ihl << 2)); in tcp_v4_err()
631 struct tcphdr *th = tcp_hdr(skb); in __tcp_v4_send_check()
635 skb->csum_offset = offsetof(struct tcphdr, check); in __tcp_v4_send_check()
662 const struct tcphdr *th = tcp_hdr(skb); in tcp_v4_send_reset()
664 struct tcphdr th; in tcp_v4_send_reset()
695 rep.th.doff = sizeof(struct tcphdr) / 4; in tcp_v4_send_reset()
778 arg.csumoffset = offsetof(struct tcphdr, check) / 2; in tcp_v4_send_reset()
832 const struct tcphdr *th = tcp_hdr(skb); in tcp_v4_send_ack()
834 struct tcphdr th; in tcp_v4_send_ack()
[all …]
/kernel/linux/linux-5.10/net/ipv6/
Dtcpv6_offload.c32 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()
/kernel/linux/linux-5.10/include/net/
Dip6_checksum.h66 struct tcphdr *th = tcp_hdr(skb); in __tcp_v6_send_check()
71 skb->csum_offset = offsetof(struct tcphdr, check); in __tcp_v6_send_check()
82 struct tcphdr *th = tcp_hdr(skb); in tcp_v6_gso_csum_prep()
/kernel/linux/linux-5.10/tools/testing/selftests/bpf/
Dnetwork_helpers.h24 struct tcphdr tcp;
32 struct tcphdr tcp;
/kernel/linux/linux-5.10/include/linux/
Dnetfilter_ipv6.h52 const struct tcphdr *th, u16 *mssp);
54 const struct tcphdr *th, __u32 cookie);
165 const struct tcphdr *th, in nf_ipv6_cookie_init_sequence()
182 const struct tcphdr *th, __u32 cookie) in nf_cookie_v6_check()

12345678