If SYN packet contains MP_CAPABLE option, keep it enabled. Syncokie validation and cookie-based socket creation is changed to instantiate an mptcp request sockets if the ACK contains an MPTCP connection request. Rather than extend both cookie_v4/6_check, add a common helper to create the (mp)tcp request socket.
Showing the changes to include (1 of 4 files). Show all
Unified · Split
| @@ -469,6 +469,8 @@ struct sock *tcp_get_cookie_sock(struct sock *sk, struct sk_buff *skb, · 468 unmodified lines | ||
| 469 | 469 | int __cookie_v4_check(const struct iphdr *iph, const struct tcphdr *th, |
| 470 | 470 | u32 cookie); |
| 471 | 471 | struct sock *cookie_v4_check(struct sock *sk, struct sk_buff *skb); |
| 472 | +struct request_sock *cookie_tcp_reqsk_alloc(const struct request_sock_ops *ops, | |
| 473 | + struct sock *sk, struct sk_buff *skb); | |
| 472 | 474 | #ifdef CONFIG_SYN_COOKIES |
| 473 | 475 | |
| 474 | 476 | /* Syncookies use a monotonic timer which increments every 60 seconds. |