summaryrefslogtreecommitdiff
path: root/net/ipv4/netfilter/ip_conntrack_helper_pptp.c
diff options
context:
space:
mode:
authorPatrick McHardy <kaber@trash.net>2006-09-20 19:11:30 (GMT)
committerDavid S. Miller <davem@sunset.davemloft.net>2006-09-22 22:20:20 (GMT)
commit4c5de695cf7f71c85ad8cfff509f6475b8bd4d27 (patch)
tree5175e20ab9244b4a0961ae98d85c8823956aad77 /net/ipv4/netfilter/ip_conntrack_helper_pptp.c
parentfd5e3befa405ea64d4db6b393b821644bf963c57 (diff)
downloadlinux-4c5de695cf7f71c85ad8cfff509f6475b8bd4d27.tar.xz
[NETFILTER]: PPTP conntrack: fix another GRE keymap leak
When the master PPTP connection times out while still having unfullfilled expectations (and a GRE keymap entry) associated with it, the keymap entry is not destroyed. Add a destroy callback to struct ip_conntrack_helper and use it to destroy PPTP siblings when the master is destroyed. Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/netfilter/ip_conntrack_helper_pptp.c')
-rw-r--r--net/ipv4/netfilter/ip_conntrack_helper_pptp.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/net/ipv4/netfilter/ip_conntrack_helper_pptp.c b/net/ipv4/netfilter/ip_conntrack_helper_pptp.c
index 98267b0..fb0aee6 100644
--- a/net/ipv4/netfilter/ip_conntrack_helper_pptp.c
+++ b/net/ipv4/netfilter/ip_conntrack_helper_pptp.c
@@ -553,15 +553,6 @@ conntrack_pptp_help(struct sk_buff **pskb,
nexthdr_off += tcph->doff * 4;
datalen = tcplen - tcph->doff * 4;
- if (tcph->fin || tcph->rst) {
- DEBUGP("RST/FIN received, timeouting GRE\n");
- /* can't do this after real newnat */
- info->cstate = PPTP_CALL_NONE;
-
- /* untrack this call id, unexpect GRE packets */
- pptp_destroy_siblings(ct);
- }
-
pptph = skb_header_pointer(*pskb, nexthdr_off, sizeof(_pptph), &_pptph);
if (!pptph) {
DEBUGP("no full PPTP header, can't track\n");
@@ -640,7 +631,8 @@ static struct ip_conntrack_helper pptp = {
.protonum = 0xff
}
},
- .help = conntrack_pptp_help
+ .help = conntrack_pptp_help,
+ .destroy = pptp_destroy_siblings,
};
extern void ip_ct_proto_gre_fini(void);