%docentities; ] >
Tomas Mandys Iptel.org
tomas dot mandys at iptel dot org
2007 Tomas Mandys
Iptrtpproxy module
Overview It provides similar functionality as nathelper but communicates with netfilter kernel xt_RTPPROXY module using libipt_RTPPROXY userspace library. See http://www.2p.cz/en/netfilter_rtp_proxy All RTP streams are manipulated directly in kernel space, no data is copied from kernel to userspace and back, it reduces load and delay. See http://www.2p.cz/en/netfilter_rtp_proxy for more details. The ser module is written as light-weighted, there is not implemented any dialog managment as in nathelper, the reason is that such an API should be provided by core or specialized dialog manager module. Because such module is not in CVS, session information may be stored in extra attributes of avp_db module and session id itself in record route as cookie, see rr module. It should be able to support all cases as re-invites when SIP client offers media change in SDP and when number of medias in offer/answer are different. Nathelper may be still used for testing if client is behind the NAT. There is also support for media authorization. Number of codec sets may be defined. When a message containing SDP offer/answer is being processed then current codecs and streams may be inspected, removed or signallized according a codec set. Limitations: only IPv4 addresses are supported. more media streams per session supported
Dependencies The following libraries or applications must be installed before running SER with this module loaded: netfilter xt_RTPPROXY & libipt_RTPPROXY, see http://www.2p.cz/en/netfilter_rtp_proxy The module Makefile must be edited and iptdir setup to the directory with the iptable sources (if different from ~/iptables). Alternatively compile the module using: make -C modules/iptrtpproxy iptdir=path_to_iptables_src
Selects
<function>@iptrtpproxy.session_ids</function> Returns sessions allocated/updated in iptrtpproxy_alloc/update. The format is: switchboard_name [ ":" [ session_id "/" created ] * ( "," session_id "/" created ) ] ] session_id = * ( [0-9] ) ; empty when no session allocated created = timestamp
<function>@iptrtpproxy.sdp_ip</function> Return first rewritten IP provided at SDP c= line.
<function>@iptrtpproxy.o_name</function> Return username from original o= line.
<function>@iptrtpproxy.o_addr</function> Return address from original o= line.
<function>@iptrtpproxy.auth_rights</function> Result of iptrtpproxy_authorize_media.
<function>@iptrtpproxy.active_media_num</function> Returns number of active media streams in SDP. iptrtpproxy_authorize_media may disable some streams, i.e. returned value may change after authorization.