Our VoIP Provider can send calls from 10 different IP addresses. Is there a way to configure this in the multiple hosts in the peer details, so that we don’t have to configure settings such as Allow Anonymous Inbound Calls?
If your voip provider is registering on your Asterisk server you can set something like this:
[MyVoipProvider]
type = peer
host = dynamic
...
But the problem is to register on your voip provider. If he changes the IP often, is better to ask if they have a domain, this way you can register to a domain instead of an IP. Something like this in your [general] context:
I don’t know if something like this should work for the same provider, I think so, but you must test it first:
register => USERNAME:PASSWORD@MYVOIPPROVIDER_IP1
register => USERNAME:PASSWORD@MYVOIPPROVIDER_IP2
...
Please try and reply to us.
Toni
Our VoIP provider has a domain which we use in the registration string. For the host field we use the FQDN. However, this only resolves to one of the 10 or so IP addresses. So when a call is passed to our PBX from one of the other IP addresses, in the logs it says it is from an unknown peer.
If the registration string has the domain , would setting the host to ‘dynamic’ address the problem of calls coming from the range of IP addresses owned by the Voip provider?
Thanks
David.
Only if they meet the conditions for using type=friend or user, i.e. they send a fixed value (rather than caller ID) in the From header. However, in that case, you could just use type=friend, with the primary static address.
What if you define multiple SIP peers? A SIP peers for each provider VoIP server.
That’s the normal way when the number of possible source addresses is not too large. Note that you don’t need to specify passwords, as they will only be used for INVITEs and you would normally have disable password checks for those by using insecure=invite (or remotesecret).