Accepting calls from other servers

I am trying to figure out how to set up a SIP channel that will answer calls directed to asterisk as sip:1234@my.domain.com from any other service or server. Have looked everywhere but can’t seem to find instructions on how to do this.

In other words, I want to allow incoming calls from other servers.

Any help appreciated.

This is pretty easy. You just have to create an authentication account similar to those for phones that register to your * server in sip.conf. It should look like:

[inboound-server]
type=friend [size=75]<–or peer[/size]
username=inboound-server
secret=xxxxxx
host=dynamic
defaultip=XXX.XXX.XXX [size=75]<–enter remote server static IP or domain name here[/size]
context=yourcontext
nat=yes
canreinvite=no

And the remote server will have to use a register=username:password@your*serverdomainorIP.com string to register into your * server via SIP .
And if you want to be able to call to/through those remote servers you just have to do vice versa.

I think he wants to set it up so totally random people can connect and make calls…

try this-
in sip.conf define in [general] section: (not in their own section)
context=(some incoming context)
realm=yourdomain.com

then set up your SRV records in DNS to point to your * box.

Make sure the context you specified has the extensions you want to use. you can create mappings, ie

exten => dave,1,Goto(users,1234,1) so when someone dials dave@yourdomain.com it goes to exten 1234 in [users]

Hope that helps!

I think IronHelix is on to the right track. I want to accept calls from anyone without having to register them by IP. I will try what you suggest and let you know. Thanks.

Making some progress. Calls are arriving at *, but being refused with the following message:

chan_sip.c:10469 handle_request_invite: Failed to
authenticate user "Bill"sip:101@66.224.20.7:5060;tag=40201801516741

How di I tell * to accept these calls from remote servers?

I believe you need to add an “insecure=invite” line to your sip.conf file. This parameter is suppose to remove the requiriment of the initial INVITE to be authenticated. Since “random” users will not be registered with your system, you do not want the system to require them to authenticate.

Here’s what I think,

In the Sip.conf under General, add allowguest=yes

then define a user like this

[guest]
context=guestcontex (to be more secure)
allow=ulaw ( or any codec)
type=user

By default, if allowguest=yes then Asterisk is moving any request not registred throught the guest user.

Not sure, this is what I think in theories, never tested.

Here sone very insuffisant info about allowguest : voip-info.org/wiki/view/Aste … g+sip.conf

OK, thanks to all of you for your help.

Here is what works:

Turn on the following under [general] in sip.conf

allowguest=yes
bindport=5060
srvlookup=yes

add something to your inbound context in extensions.conf such as:

exten=>bill,1,Dial(SIP/111)

Now any sip phone that dials bill@xantek.cc will ring my extension 111.

Feel free to test it by giving me a call.

Many thanks to blyon.com/sip_uri/ fro putting me on the right track