Localnet in Asterisk configuration

hello guys.

i wanna ask about element “localnet” in sip.conf file that some tutorials use that element for asterisk’s configuration. is it important to be specific with the IP of my computer? if i set “localnet” with it’s default 0.0.0.0, is there some problem will come in certain case ?

thanks

It is never necessary to specify the IP of your computer. You should not even specify IP’s, only network ranges.

If you need localnet at all, it is to specify which sub-networks, other than the directly connected one, are on your side of a NAT device.

The default is not 0.0.0.0 but <your IP address>/<your subnet mask>. (More correctly, I think it is nothing and the local network is always added, but it does no harm to add it explicitly.)