aboutsummaryrefslogtreecommitdiffstats
path: root/include/net
diff options
context:
space:
mode:
authorPatrick McHardy <kaber@trash.net>2009-06-29 08:07:56 -0400
committerPatrick McHardy <kaber@trash.net>2009-06-29 08:07:56 -0400
commita3a9f79e361e864f0e9d75ebe2a0cb43d17c4272 (patch)
treee38bb7cc051cf197a813d553713e3071d375a1b9 /include/net
parent308ff823ebd749a94d3b6ac26b95bc0eb114c39e (diff)
netfilter: tcp conntrack: fix unacknowledged data detection with NAT
When NAT helpers change the TCP packet size, the highest seen sequence number needs to be corrected. This is currently only done upwards, when the packet size is reduced the sequence number is unchanged. This causes TCP conntrack to falsely detect unacknowledged data and decrease the timeout. Fix by updating the highest seen sequence number in both directions after packet mangling. Tested-by: Krzysztof Piotr Oledzki <ole@ans.pl> Signed-off-by: Patrick McHardy <kaber@trash.net>
Diffstat (limited to 'include/net')
-rw-r--r--include/net/netfilter/nf_conntrack.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/net/netfilter/nf_conntrack.h b/include/net/netfilter/nf_conntrack.h
index a632689b61b4..cbdd6284996d 100644
--- a/include/net/netfilter/nf_conntrack.h
+++ b/include/net/netfilter/nf_conntrack.h
@@ -258,8 +258,8 @@ static inline bool nf_ct_kill(struct nf_conn *ct)
258/* Update TCP window tracking data when NAT mangles the packet */ 258/* Update TCP window tracking data when NAT mangles the packet */
259extern void nf_conntrack_tcp_update(const struct sk_buff *skb, 259extern void nf_conntrack_tcp_update(const struct sk_buff *skb,
260 unsigned int dataoff, 260 unsigned int dataoff,
261 struct nf_conn *ct, 261 struct nf_conn *ct, int dir,
262 int dir); 262 s16 offset);
263 263
264/* Fake conntrack entry for untracked connections */ 264/* Fake conntrack entry for untracked connections */
265extern struct nf_conn nf_conntrack_untracked; 265extern struct nf_conn nf_conntrack_untracked;