Difference between revisions of "SIP configuration for voip phone"
From MyWiki
(Created page with "<source lang="text> [250] username=250 type=friend host=dynamic secret=cabbage123 context=twig </source>") |
|||
(2 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
− | <source lang="text> | + | <source lang="text"> |
[250] | [250] | ||
username=250 | username=250 | ||
type=friend | type=friend | ||
host=dynamic | host=dynamic | ||
− | secret= | + | secret=<secret password> |
context=twig | context=twig | ||
+ | </source> | ||
+ | iptables rules for asterisk - https://www.voip-info.org/asterisk-firewall-rules/ | ||
+ | <source lang="bash"> | ||
+ | # SIP on UDP port 5060. Other SIP servers may need TCP port 5060 as well | ||
+ | iptables -A INPUT -p udp -m udp --dport 5060 -j ACCEPT | ||
+ | |||
+ | # IAX2- the IAX protocol | ||
+ | iptables -A INPUT -p udp -m udp --dport 4569 -j ACCEPT | ||
+ | |||
+ | # IAX - most have switched to IAX v2, or ought to | ||
+ | iptables -A INPUT -p udp -m udp --dport 5036 -j ACCEPT | ||
+ | |||
+ | # RTP - the media stream | ||
+ | # (related to the port range in /etc/asterisk/rtp.conf) | ||
+ | iptables -A INPUT -p udp -m udp --dport 10000:20000 -j ACCEPT | ||
+ | |||
+ | |||
+ | # MGCP - if you use media gateway control protocol in your configuration | ||
+ | iptables -A INPUT -p udp -m udp --dport 2727 -j ACCEPT | ||
</source> | </source> |
Latest revision as of 20:16, 10 February 2020
[250] username=250 type=friend host=dynamic secret=<secret password> context=twig
iptables rules for asterisk - https://www.voip-info.org/asterisk-firewall-rules/
# SIP on UDP port 5060. Other SIP servers may need TCP port 5060 as well iptables -A INPUT -p udp -m udp --dport 5060 -j ACCEPT # IAX2- the IAX protocol iptables -A INPUT -p udp -m udp --dport 4569 -j ACCEPT # IAX - most have switched to IAX v2, or ought to iptables -A INPUT -p udp -m udp --dport 5036 -j ACCEPT # RTP - the media stream # (related to the port range in /etc/asterisk/rtp.conf) iptables -A INPUT -p udp -m udp --dport 10000:20000 -j ACCEPT # MGCP - if you use media gateway control protocol in your configuration iptables -A INPUT -p udp -m udp --dport 2727 -j ACCEPT