VOIP NAT

 

 

Voip-info.org: NAT and VOIP

Voip-info.org: Asterisk, SIP and NAT

SIP协议,采用5060端口来传递指令,10000-20000传递语音流,所有如果SIP客户端在防火墙或者内网就需要开放相应的端口,来通讯。

From Voip-info.org

On your router NAT/firewall, forward SIP ports 5060 - 5082 and RTP ports 8000 - 20000 to your * server IP address. Then edit the "rtpstart" value in rtp.conf - from rtpstart=10000 to rtpstart=8000 since 8000 is the default RTP port on x-lite phones. Also enter the same externip=xxx.xxx.xxx.xxx and localnet=xxx.xxx.xxx.xxx/xxx.xxx.xxx.xxx info from your sip.conf general settings into sip_nat.conf. Then in sip.conf under the remote extension account authentication settings add nat=yes, canreinvite=no . This should get it working flawlessly, it did it for me after much research and troubleshooting. This should mark the end of NAT/firewall issues with asterisk.


NOTE: Your WAN or externip address from your ISP is usually not permanent so in the case where it changes you will have to edit the "externip=" value in sip.conf general settings and sip_nat.conf to the new value or you can register with dynamic DNS (dyndns) to automaticaly update the value.

 

IAX2协议指令和媒体流都通过4569端口来传递,穿透能力比较强。

Voip-info.org: Asterisk NAT=yes documentation (sip.conf)

Voip-info.org: STUN

 
  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值