[SR-Users] question about rtpproxy "r" flag

Alex Hermann alex at speakup.nl
Fri Jul 12 10:21:13 CEST 2013


On Friday 12 July 2013 06:59:38 Juha Heinanen wrote:
> rtpproxy_offer and answer functions have "r" flag described as follows:
> 
>   r - flags that IP address in SDP should be trusted. Without this flag,
>   rtpproxy ignores address in the SDP and uses source address of the SIP
>   message as media address which is passed to the RTP proxy.
> 
> how does rtpproxy "use" this ip address?

It directly starts forwarding packets to it. If you don't use this flag, 
rtpproxsy will wait until it has received poackets from both parties in the 
call.


> if sip message comes from behind nat, ip address in sdp is local
> address, not the address where rtp packets come from.  and if this
> request has passed another (e.g. outbound) proxy before hitting the
> current one, also source address of sip message is not the address where
> rtp packets come from.  either address thus seems to be useless for
> rtpproxy.

You can make the addres more "usefull" by rewriting the address with 
fix_natted_sdp() on the first proxy the UAC reaches (load-balancer). If you 
don't have that possibility, maybe you can call fix_natted_sdp() on the proxy 
itself and call msg_apply_changes() before invoking the rtpproxy.
-- 
Alex Hermann



More information about the sr-users mailing list