Asterisk and multiple SIP registrations to the same host

Registering multiple SIP accounts with one SIP provider has been a nightmare in Asterisk. Or, rather, still is. The match-on-IP scheme for peers is a hack to handle registrations, but not a very good hack. If you register for multiple accounts, the incoming calls will all match the same peer. A poor solution.

With the help of Luigo Rizzo, I have started a rewrite of the SIP outbound registration process in Asterisk. You can find the current development code in a subversion branch named sipregister.

In this code, you will soon find the following features:

  • Registrations are matched exactly. If you register multiple accounts on the same server, but with different extensions in the register= line, we will match the registrations and send incoming calls to the proper extensions.
  • Registrations within a peer declaration. You can now add register=yes to the peer section in sip.conf. This will make Asterisk register that account with an outbound provider. Incoming calls will be matched to the incoming context of the peer.

Asterisk will still try to match inbound calls on IP of the peer, but I doubt if it will be needed in the future. Please help me try this code and find the bugs before we include it in Asterisk trunk.

Share and Enjoy: These icons link to social bookmarking sites where readers can share and discover new web pages.
  • Digg
  • del.icio.us
  • Netvouz
  • DZone
  • ThisNext
  • MisterWong
  • Wists
  • StumbleUpon
  • YahooMyWeb

Leave a Reply

You must be logged in to post a comment.