[netfilter-cvslog] r4089 - trunk/patch-o-matic-ng/patchlets/pptp-conntrack-nat/linux-2.6.11/net/ipv4/netfilter

laforge at netfilter.org laforge at netfilter.org
Sun Jul 3 18:04:33 CEST 2005


Author: laforge at netfilter.org
Date: 2005-07-03 18:04:32 +0200 (Sun, 03 Jul 2005)
New Revision: 4089

Modified:
   trunk/patch-o-matic-ng/patchlets/pptp-conntrack-nat/linux-2.6.11/net/ipv4/netfilter/ip_conntrack_proto_gre.c
Log:
some missing 32bit key -> 16bit key changes.  conntrack is now working


Modified: trunk/patch-o-matic-ng/patchlets/pptp-conntrack-nat/linux-2.6.11/net/ipv4/netfilter/ip_conntrack_proto_gre.c
===================================================================
--- trunk/patch-o-matic-ng/patchlets/pptp-conntrack-nat/linux-2.6.11/net/ipv4/netfilter/ip_conntrack_proto_gre.c	2005-07-03 12:54:15 UTC (rev 4088)
+++ trunk/patch-o-matic-ng/patchlets/pptp-conntrack-nat/linux-2.6.11/net/ipv4/netfilter/ip_conntrack_proto_gre.c	2005-07-03 16:04:32 UTC (rev 4089)
@@ -57,8 +57,8 @@
 #if 0
 #define DEBUGP(format, args...)	printk(KERN_DEBUG "%s:%s: " format, __FILE__, __FUNCTION__, ## args)
 #define DUMP_TUPLE_GRE(x) printk("%u.%u.%u.%u:0x%x -> %u.%u.%u.%u:0x%x\n", \
-			NIPQUAD((x)->src.ip), ntohl((x)->src.u.gre.key), \
-			NIPQUAD((x)->dst.ip), ntohl((x)->dst.u.gre.key))
+			NIPQUAD((x)->src.ip), ntohs((x)->src.u.gre.key), \
+			NIPQUAD((x)->dst.ip), ntohs((x)->dst.u.gre.key))
 #else
 #define DEBUGP(x, args...)
 #define DUMP_TUPLE_GRE(x)
@@ -202,7 +202,7 @@
 				DEBUGP("GRE_VERSION_PPTP but unknown proto\n");
 				return 0;
 			}
-			tuple->dst.u.gre.key = htonl(ntohs(pgrehdr->call_id));
+			tuple->dst.u.gre.key = pgrehdr->call_id;
 			break;
 
 		default:
@@ -215,7 +215,7 @@
 
 	tuple->src.u.gre.key = srckey;
 #if 0
-	DEBUGP("found src key %x for tuple ", ntohl(srckey));
+	DEBUGP("found src key %x for tuple ", ntohs(srckey));
 	DUMP_TUPLE_GRE(tuple);
 #endif
 
@@ -227,8 +227,8 @@
 			   const struct ip_conntrack_tuple *tuple)
 {
 	return seq_printf(s, "srckey=0x%x dstkey=0x%x ", 
-			  ntohl(tuple->src.u.gre.key),
-			  ntohl(tuple->dst.u.gre.key));
+			  ntohs(tuple->src.u.gre.key),
+			  ntohs(tuple->dst.u.gre.key));
 }
 
 /* print private data for conntrack */




More information about the netfilter-cvslog mailing list