On 12/16/14 10:04, Mahmoud Ramadan Ali wrote:
Hi Dears, I'm working on integrating the rtpengine to work with Kamailio as RTP proxy and i have successfully configured the rtpengine in multi home mode to proxy the media and rewrite the SDP message whenever it passes trough the Kamailio internal interface to the external interface and vice versa using this command.
root@debian:/usr/local/etc/kamailio# rtpengine --interface=Kamailio-Internal/192.168.100.1 http://192.168.100.1 --interface=Kamailio-External/192.168.50.1 http://192.168.50.1 --listen-ng=127.0.0.1:22222 http://127.0.0.1:22222 --pidfile=/var/run/ngcp-rtpengine-daemon.pid
Also i have configured the "i" and "e" flags in the route[NATMANAGE] to take care of the SDP rewriting direction the same way it worked before with my rtpproxy module configuration.
But the issue now is that whenever i make a call from the external to the internal the rtpengine can NOT detect the right direction as colored in red below so my question now is : How to set the direction of the rtpengine to designate that the interface 192.168.50.1 is the external and 192.168.100.1 is the internal ?
Dec 16 09:28:09 debian rtpengine[4714]: Got valid command from 127.0.0.1:50639 http://127.0.0.1:50639: offer - { "sdp": "v=0#015#012o=- 13063213690566395 1 IN IP4 192.168.50.2#015#012s=X-Lite release 4.7.1 stamp 74247#015#012c=IN IP4 192.168.50.2#015#012t=0 0#015#012m=audio 56078 RTP/AVP 125 100 0 9 8 101#015#012a=rtpmap:125 opus/48000/2#015#012a=fmtp:125 useinbandfec=1#015#012a=rtpmap:100 speex/16000#015#012a=rtpmap:101 telephone-event/8000#015#012a=fmtp:101 0-15#015#012a=sendrecv#015#012", "direction": [ "internal", "external" ], "flags": [ "asymmetric", "trust-address", "symmetric" ], "replace": [ "session-connection", "orig ...
If you want to use the "i" and "e" flags, you must name your logical interfaces "internal" and "external" respectively, as in:
./rtpengine ... --interface=internal/192.168.100.1 --interface=external/192.168.50.1 ...
Alternatively if you wish to retain and use the more free-form interface names, you must use the "direction=..." option in your calls to rtpengine_*(), but you'd need a more recent version of the rtpengine module for this to work.
cheers