Hoa Thai Duy
2006-Oct-16 21:36 UTC
[asterisk-users] Critical - No audio issue with re-invite (wrong media address)
Hi all I faced the issue with canreinvite=yes in Asterisk (both 1.2.9.1 and 1.2.1.12). My diagram UA1(RFC1918) ----- ADSL1 (NAT) -------------- Asterisk (Public IP) ------------ (NAT)ADSL2 --- UA2 (RFC1918) When canreinvite=no in sip.conf for both UAs, everything is fine, RTP from both UAs are sent to Asterisk (can see using "rtp debug") and both UAs can talk. When canreinvite=yes and nat=yes, I faced no audio issue. After debug, I found that, when Asterisk send re-invite to both UAs, both UAs reply their OK with c=their RFC1918 address, and Asterisk send that OK parameters to other UAs Asterisk send re-invite to UA1 with c=Public NATed IP of ADSL2 Asterisk send re-invite to UA2 with c=Public NATed IP of ADSL1 UA1 reply OK to Asterisk with c=RFC1918 of UA1 UA2 reply OK to Asterisk with c=RFC1918 of UA2 Asterisk send OK to UA2 with c= RFC1918 of UA1 (because it received the newer c= RFC1918 of UA1) Asterisk send OK to UA1 with c= RFC1918 of UA2 (because it received the newer c= RFC1918 of UA2) UA1 send RTP directly to c= RFC1918 of UA2 (it must be c=Public NATed IP of ADSL2 for correct audio flow) UA2 send RTP directly to c= RFC1918 of UA1 (it must be c=Public NATed IP of ADSL1 for correct audio flow) . no audio at all . Pls. help Brgds Hoa Sip.conf [general] context=default port=5060 bindaddr=0.0.0.0 realm srvlookup=no disallow=all allow=g729 canreinvite=yes nat=yes [2222] type=friend host=dynamic username=2222 secret=2222 canreinvite=yes nat=yes callerid="2222" <2222> allow=g729 [1111] type=friend host=dynamic username=1111 secret=1111 canreinvite=yes nat=yes callerid="1111" <1111> allow=g729 extensions.conf [general] static=yes writeprotect=no exten => 2222,1,Answer exten => 2222,2,Dial(SIP/2222) exten => 2222,2,Hangup exten => 1111,1,Answer exten => 1111,2,Dial(SIP/1111) exten => 1111,2,Hangup -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20061016/f9d9a49f/attachment-0001.htm