When I turn the Allow anonymous inbound SIP calls to “no”, I can no longer receive calls from my provider. If I set it to “yes” I have a hacker connecting to my machine and making calls. Does anyone know how to get the system to work by turning it off?
without seeing your config, no way to know, but you should not have to allow anonymous calls. the SIP trunk should have some sort of authentication.
first- the context= for [general] should NEVER go into a privelaged context- by that I mean a context that can dial out or do anything that you wouldn’t want a random incoming caller to be able to do.
Now if your provider incoming fails when allow guest is off, that means the provider is not matching up with the peer you have defined for it.
Try the following-
- make sure you have a section defined for your provider, ie
insecure=very ; this can help troubleshoot incoming
context=where it should go
Now for your register statement in general, change it to be
register => user:pass@provider. NOT user:email@example.com. This makes it use the host= statement from the [provider] thing below, which makes it match to that entry and use the correct context.
Other than that, post your sip.conf?