Centos
無法從遠端位置訪問 Asterisk sip
我已經使用本教程來配置我的 iptables,因此我可以從我的伺服器外部訪問星號 sip。
我的
iptables -L
長相是這樣的Chain INPUT (policy ACCEPT) target prot opt source destination ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED ACCEPT icmp -- anywhere anywhere ACCEPT all -- anywhere anywhere ACCEPT tcp -- anywhere anywhere state NEW tcp dpt:ssh REJECT all -- anywhere anywhere reject-with icmp-host-prohibited ACCEPT udp -- anywhere anywhere udp dpt:sip ACCEPT udp -- anywhere anywhere udp dpt:iax ACCEPT udp -- anywhere anywhere udp dpt:5036 ACCEPT udp -- anywhere anywhere udp dpts:ndmp:dnp ACCEPT udp -- anywhere anywhere udp dpt:mgcp-callagent Chain FORWARD (policy ACCEPT) target prot opt source destination REJECT all -- anywhere anywhere reject-with icmp-host-prohibited Chain OUTPUT (policy ACCEPT) target prot opt source destination
現在,當 iptables 關閉時,我可以毫無問題地在 sip 客戶端上註冊,但是當它打開時,防火牆會阻止它。這個 iptables 配置有什麼問題,我應該怎麼做才能修復它?
您在鏈中有一條拒絕所有規則:
REJECT all -- anywhere anywhere reject-with icmp-host-prohibited
把它移到最後,你就準備好了。