Hi,

normally, Asterisk handles RTP IP addresses in SDP correctly, if you have 
specified
 - that NAT traversal is enabled for all peers (e.g. nat=force_rport,comedia)
 - your local network with "localnet=yournetwork/networkmask" - e.g. 
"localnet=192.168.1.0/255.255.255.0"
 - directmedia, canreinvite, directrtpsetup is deacitivated

In this case, your Asterisk will always stay in the RTP stream and signalling 
only it's own IP address to other peers
which is configured for the interface which Asterisk uses to reach the peer.


But: If you have only one interface configured on your Asterisk server and an 
external firewall/router is managing your separated networks, this might not 
help.
In this case you can use "externip" on a per peer basis in your SIP 
configuration to specify the IP address Asterisk uses in the SDP.
Maybe, a global configuration of "externip" and "localnet" is all you need to 
help Asterisk setting the SDP address correctly.
Also, enabling ICE support can help you getting the correct IP address if the 
remote peer supports it.



Greetings
 Max


Am 07.12.2016 um 00:02 schrieb Harel:
> Hello List,
> I need your help with information going out on my SDP.
> Is it possible to update the Media Address on a per-call basis or a 
> per-channel basis?
> Reason:
> My Asterisk is in a private network and needs to connect to UA on its 
> internal network and also few external networks. One network is public and 
> the others are not public. Between each other the external networks are not 
> routable. Signaling is flowing with no issues because SIP Registers and NAT 
> boxes maintain sessions correctly. The problem is with RTP. After making 
> traces on all possible nodes of this network I clearly found out that the RTP 
> fails because the Asterisk doesn't manage to communicate the correct address 
> to the UAs in the SDP. It will report its internal IP address and the remote 
> UA will try to send its RTP to this address which, of course, will fail 
> miserably. 
> Obviously I can't use externaddr or media_address in sip.conf because it will 
> only be good for one network while the other external networks will fail just 
> the same. Same applies for STUN, it will only be good for the network the 
> STUN requests are being sent from. 
> On all networks I have fix IP addresses on my side and I fully control a 
> professional security box. 
> Asterisk is 13.6.0
> I can't, and don't want to, touch user-side equipment which is normally some 
> kind of voip phone behind a standard home VDSL router.
> 
> Any ideas how can I transmit the correct IP address in SDP to UAs on 
> different networks?
> 
> Many thanks,
> Harel
> 
> 

Attachment: signature.asc
Description: OpenPGP digital signature

-- 
_____________________________________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Check out the new Asterisk community forum at: https://community.asterisk.org/

New to Asterisk? Start here:
      https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Reply via email to