--- zzzz-none-000/linux-2.4.17/net/ipv4/netfilter/ipt_TCPMSS.c 2001-12-21 17:42:05.000000000 +0000 +++ sangam-fb-322/linux-2.4.17/net/ipv4/netfilter/ipt_TCPMSS.c 2004-11-24 13:22:08.000000000 +0000 @@ -45,7 +45,7 @@ const struct ipt_tcpmss_info *tcpmssinfo = targinfo; struct tcphdr *tcph; struct iphdr *iph; - u_int16_t tcplen, newtotlen, oldval, newmss; + u_int16_t tcplen, newtotlen, oldval, newmss, srcmss; unsigned int i; u_int8_t *opt; @@ -93,6 +93,9 @@ } newmss = (*pskb)->dst->pmtu - sizeof(struct iphdr) - sizeof(struct tcphdr); + srcmss = in->mtu - sizeof(struct iphdr) - sizeof(struct tcphdr); + if(srcmss < newmss) + newmss = srcmss; } else newmss = tcpmssinfo->mss;