netfilter updates for net tree (3.5-rc2)
Subsystems (3)
[email protected]
maintainercover netfilter updates for net tree (3.5-rc2)
From: Pablo Neira Ayuso <[email protected]>
Hi David,
The following two patches are netfilter fixes for your net tree, they provide:
* endianess fixes to calm down warnings spotted by the sparse utility for xt_HMARK from Hans Schillstrom.
* One fix for h323 conntrack helper from Sanket Shah and Jagdish Motwani. The log says it's been me instead because they sent an incomplete patch without header, so I had to manually include all the information, but forgot to change the GIT_AUTHOR thing.
You can pull these two changes from:
git://1984.lsi.us.es/net master
Thanks!
Hans Schillstrom (1):
netfilter: xt_HMARK: fix endianness and provide consistent hashing
Pablo Neira Ayuso (1):
netfilter: nf_ct_h323: fix bug in rtcp natting
include/linux/netfilter/xt_HMARK.h | 5 +++ net/netfilter/nf_conntrack_h323_main.c | 5 +-- net/netfilter/xt_HMARK.c | 72 ++++++++++++++++++-------------- 3 files changed, 48 insertions(+), 34 deletions(-)
Signature · 1 line
1.7.10
[email protected]
maintainerPATCH 1/2 netfilter: xt_HMARK: fix endianness and provide consistent hashing
From: Hans Schillstrom <[email protected]>
This patch addresses two issues:
a) Fix usage of u32 and __be32 that causes endianess warnings via sparse.
b) Ensure consistent hashing in a cluster that is composed of big and little endian systems. Thus, we obtain the same hash mark in an heterogeneous cluster.
--- include/linux/netfilter/xt_HMARK.h | 5 +++ net/netfilter/xt_HMARK.c | 72 ++++++++++++++++++++---------------- 2 files changed, 46 insertions(+), 31 deletions(-)
include/linux/netfilter/xt_HMARK.h +5 -0
@@ -27,7 +27,12 @@ union hmark_ports {__u16 src;__u16 dst; } p16; +struct { +__be16 src; +__be16 dst; + } b16;__u32 v32; +__be32 b32; };struct xt_hmark_info {
net/netfilter/xt_HMARK.c +41 -31
135 lines not on this page · raw message
Signature · 1 line
1.7.10
[email protected]
maintainerPATCH 2/2 netfilter: nf_ct_h323: fix bug in rtcp natting
In reply to [email protected]From: Pablo Neira Ayuso <[email protected]>
The nat_rtp_rtcp hook takes two separate parameters port and rtp_port.
port is expected to be the real h245 address (found inside the packet). rtp_port is the even number closest to port (RTP ports are even and RTCP ports are odd).
However currently, both port and rtp_port are having same value (both are rounded to nearest even numbers).
This works well in case of openlogicalchannel with media (RTP/even) port.
But in case of openlogicalchannel for media control (RTCP/odd) port, h245 address in the packet is wrongly modified to have an even port.
I am attaching a pcap demonstrating the problem, for any further analysis.
This behavior was introduced around v2.6.19 while rewriting the helper.
--- net/netfilter/nf_conntrack_h323_main.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
net/netfilter/nf_conntrack_h323_main.c +2 -3
@@ -270,9 +270,8 @@ static int expect_rtp_rtcp(struct sk_buff *skb, struct nf_conn *ct,return 0 ;/* RTP port is even */ - port &=htons (~1 ); - rtp_port = port; - rtcp_port =htons (ntohs (port) +1 ); + rtp_port = port & ~htons (1 ); + rtcp_port = port |htons (1 );/* Create expect for RTP */ if ((rtp_exp =nf_ct_expect_alloc (ct)) ==NULL )
Signature · 1 line
1.7.10
David Miller
maintainerFrom: [email protected]
Date: Tue, 12 Jun 2012 19:36:01 +0200
Quoted 3 lines
You can pull these two changes from:
git://1984.lsi.us.es/netmaster
Pulled, thanks Pablo.