Hi,
My aim is to a) modify IP Addresses of some SIP headers and SDP message headers ( as SIP traffic passes across my node) and b) also to capture values from some of them. [Basically I want to develop a SIP ALG].
After exploring further, I found that 'SIP connection tracking/NAT' netfilters might help me in achieving this.
I have enabled Kernal Loadable Modules "nf_conntrack_sip" and "nf_nat_sip" in my kernel.
What I want to know now is--
1. Is it already proven and tried fact that I can use above KLMs for achieving my purpose?
2. If I need to 'use' these netfilters how to use them? Should I need to run IPTABLES commands from userspace and refer someway to this netfilters ? Any sample commands??
Or 3. Should I need to create a KLM module in kernel space and directly call the APIs available in those netfilters modules [ e.g ..net/ipv4/netfilter/nf_nat_sip.c and ../net/netfilter/nf_conntrack_sip.c] ?
If that is the case, how can I pass those captured information towards userspace application?
or 4. Is there any alternative way to achieve above, that you are aware of in kernel or userspace ?
My kernel details:- Monta vista linux, Release 2.6.32.46 for mips64.
[ I am new to Linux kernel programming though I have background of SIP. The questions above might involve very basic concepts for Linux, apologies for that
]
Waiting for your suggestions.
Regards
Honsha