11 #include <linux/module.h>
16 #include <linux/netfilter/x_tables.h>
18 #include <linux/netfilter_ipv4/ip_tables.h>
19 #include <linux/netfilter_ipv6/ip6_tables.h>
35 u8 _opt[15 * 4 -
sizeof(_tcph)];
36 unsigned int i, optlen;
39 th = skb_header_pointer(skb, par->
thoff,
sizeof(_tcph), &_tcph);
44 if (th->doff*4 <
sizeof(*th))
47 optlen = th->doff*4 -
sizeof(*th);
52 op = skb_header_pointer(skb, par->
thoff +
sizeof(*th), optlen, _opt);
56 for (i = 0; i < optlen; ) {
62 mssval = (op[i+2] << 8) | op[i+3];
64 return (mssval >= info->
mss_min &&
65 mssval <= info->mss_max) ^ info->
invert;
99 static int __init tcpmss_mt_init(
void)
104 static void __exit tcpmss_mt_exit(
void)