[Asterisk-Users] IPTables

Joel Newkirk asterisk-user at newkirk.us
Tue Apr 19 07:19:20 MST 2005


Michael Sanders wrote:
> 
> 
> Hi,
>  
> Ive got a linux firewall with Private/Public ip address on two nics.I 
> need clients to connect via SIP from the private network to a public 
> Asterisk PBX.Ive tried the the configs from the wiki and have not come 
> right.
>  
> Has anyone managed to get this working and if so please share the 
> configs or point me in the right direction.
>  
> Thanks
>  
> MS

Can you get the simpler case working, with just a single client behind 
the firewall?  Is your problem in getting multiple clients working, or 
getting one working via NAT, or getting one working through the firewall 
filtering, or SIP works but no audio, or what?  Single or multiple 
public IPs?  More info would have helped.

If you're talking about multiple clients hidden behind a single public 
IP, you should be able to do that either by configuring each client on a 
different port (5060/5061/5062 etc) or with 'nat keepalive' (on some 
phones at least).

If you have multiple public IPs available, then putting each SIP client 
on a different public IP solves the complications - then you just have 
to deal with the simple NAT case.  (misidentification, without 
misrouting too)  In this case, if you can get one phone working then you 
can get them all working, each with a different public IP but the same 
essential configuration.

By 'public asterisk pbx' do you mean a public voip service, or an 
asterisk server you control which is on a public IP?  Because if you 
control both ends, you can setup a VPN.

If you specifically need help with the iptables setup, you're probably 
better off here:
https://lists.netfilter.org/mailman/listinfo/netfilter
netfilter-request at lists.netfilter.org?subject=subscribe

(although I can try to answer iptables questions - boss calls me 
'firewalldude' for a reason ;)

j



More information about the asterisk-users mailing list