port ip_conntrack_h323 to the linux 2.6.11-rc3 API
PATCH 1/1 port ip_conntrack_h323 to the linux 2.6.11-rc3 API
Hi,
this patch ports the H.323 conntrack module to the new linux 2.6.11-rc3 API. I havn't tested that thoroughly; my nfsim tests succeed (these will be published later), and it compiles with the real kernel.
This is work in progress. I have already begun writing a "real" parser for H.225 which will replace the "brute force" algorithm in the current module. Expect more patches soon.
Max
Fri Feb 11 22:51:14 CET 2005 [email protected]
* port to linux 2.6.11
h323-conntrack-nat/linux-2.6/include/linux/netfilter_ipv4/ip_conntrack_h323.h +23 -17
@@ -3,29 +3,35 @@/* H.323 connection tracking. */ #ifdef __KERNEL__ -/* Protects H.323 related data */ -#include <linux/netfilter_ipv4/lockhelp.h> -DECLARE_LOCK_EXTERN (ip_h323_lock); -#endif /* Default H.225 port */ #define H225_PORT 1720 -/* This structure is per expected connection */ -struct ip_ct_h225_expect { -u_int16_t port;/* Port of the H.225 helper/RTCP/RTP channel */ -enum ip_conntrack_dir dir;/* Direction of the original connection */ -unsigned int offset;/* offset of the address in the payload */ -}; -/* This structure exists only once per master */ struct ip_ct_h225_master { -int is_h225;/* H.225 or H.245 connection */ -#ifdef CONFIG_IP_NF_NAT_NEEDED -enum ip_conntrack_dir dir;/* Direction of the original connection */ -u_int32_t seq[IP_CT_DIR_MAX ];/* Exceptional packet mangling for signal addressess... */ -unsigned int offset[IP_CT_DIR_MAX ];/* ...and the offset of the addresses in the payload */ -#endif +int dummy; }; +struct ip_conntrack_expect ; +struct ip_conntrack ; + +extern int (*ip_nat_h245_hook)(struct sk_buff **pskb, +enum ip_conntrack_info ctinfo, +unsigned int offset, +struct ip_conntrack_expect *exp); + +extern int (*ip_nat_h225_hook)(struct sk_buff **pskb, +enum ip_conntrack_info ctinfo, +unsigned int offset, +struct ip_conntrack_expect *exp); + +extern void (*ip_nat_h225_signal_hook)(struct sk_buff **pskb, +struct ip_conntrack *ct, +enum ip_conntrack_info ctinfo, +unsigned int offset, +int dir, +int orig_dir); + +#endif /* __KERNEL__ */ +#endif /* _IP_CONNTRACK_H323_H */
h323-conntrack-nat/linux-2.6/include/linux/netfilter_ipv4/ip_conntrack.h.ladd_3 +0 -2
@@ -1,2 +0,0 @@ - /* insert conntrack helper private data (expect) here */ - struct ip_ct_h225_expect exp_h225_info;
h323-conntrack-nat/linux-2.6/net/ipv4/netfilter/ip_conntrack_h323.c +92 -98
360 lines not on this page · raw message
h323-conntrack-nat/linux-2.6/net/ipv4/netfilter/ip_nat_h323.c +53 -321
428 lines not on this page · raw message
Quoted 6 lines · Max Kellermann
Hi,
this patch ports the H.323 conntrack module to the new linux 2.6.11-rc3 API. I havn't tested that thoroughly; my nfsim tests succeed (these will be published later), and it compiles with the real kernel.
Thanks, I've merged the patch into the
http://svn.netfilter.org/cgi-bin/viewcvs.cgi/branches/patch-o-matic-ng/linux-2.6.11
branch. Please submit any updates to that branch rather than pom-ng trunk.
Signature · 5 lines
- Harald Welte <[email protected]> http://www.netfilter.org/ ============================================================================ "Fragmentation is like classful addressing -- an interesting early architectural error that shows how much experimentation was going on while IP was being designed." -- Paul Vixie