]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
[NETFILTER]: ip_nat_proto_gre: do not modify/corrupt GREv0 packets through NAT
authorJorge Boncompte <jorge@dti2.net>
Thu, 3 May 2007 23:00:32 +0000 (01:00 +0200)
committerAdrian Bunk <bunk@stusta.de>
Thu, 3 May 2007 23:00:32 +0000 (01:00 +0200)
commitc5807ace66d5085ed94608a7e9a084085ea57ede
treef5129ba423df42b1d0f9decec62bc340103e1abd
parent4879e0dfe9c9199e55566a6025a729854bb2a00e
[NETFILTER]: ip_nat_proto_gre: do not modify/corrupt GREv0 packets through NAT

While porting some changes of the 2.6.21-rc7 pptp/proto_gre conntrack
and nat modules to a 2.4.32 kernel I noticed that the gre_key function
returns a wrong pointer to the GRE key of a version 0 packet thus
corrupting the packet payload.

The intended behaviour for GREv0 packets is to act like
ip_conntrack_proto_generic/ip_nat_proto_unknown so I have ripped the
offending functions (not used anymore) and modified the
ip_nat_proto_gre modules to not touch version 0 (non PPTP) packets.

Signed-off-by: Jorge Boncompte <jorge@dti2.net>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: Adrian Bunk <bunk@stusta.de>
include/linux/netfilter_ipv4/ip_conntrack_proto_gre.h
net/ipv4/netfilter/ip_nat_proto_gre.c