[asterisk-dev] RFC - "Improved" SIP MWI

Kristian Kielhofner kris at krisk.org
Wed Oct 4 12:41:38 MST 2006


Hello Everyone,

	Everyone working with Asterisk/SER in a distributed environment should 
feel my pain on getting MWI to work properly.  There are many kludgey 
hacks to get MWI functioning with various Asterisk/SER combos.  The most 
common Asterisk/SER combo is like so:

Phone -> SER -> (Asterisk VoiceMail)

some also look like this:

Phone -> Asterisk -> SER -> (Asterisk VoiceMail)

	This e-mail is mostly about the latter, but most of it also applies to 
the former.

	None of the usual solutions for this problem are acceptable to me.  I 
would like to make this work without having to call external scripts, 
use sipsak, etc.  With my limited knowledge of Asterisk internals, and 
my knowledge of SIP, it seems something like this should be possible:

1)  Expand on mailbox= from sip.conf for a peer and add something that
could catch all MWIs for all mailboxes from a given VM context, or
perhaps all contexts:

-----on Asterisk VM server----

[serproxy]
context=vm-in
type=peer
host=192.168.0.1
qualify=no
nat=no
fromdomain=krisk.org
insecure=very
mailbox=all

-or-

[serproxy]
context=vm-in
type=peer
host=192.168.0.1
qualify=no
nat=no
fromdomain=krisk.org
insecure=very
mailbox=[all at context from voicemail.conf]

	Anyways, hopefully you get the point...

2)  The outgoing mwi should also include the name of the context (from
voicemail.conf).  One could then parse this using SER to get it to the
correct remote Asterisk server (using some combination of avp_db_load 
and lookup(), probably.

3)  The remote Asterisk server should have an option like "bulkmwi=yes"
or similar in sip.conf [peer] entry that would enable bulk MWI
collection from that peer (SER proxy).  Asterisk would then (either 
internally or using the dialplan) parse these various incoming MWI 
notifications and send them to the correct peer (phone) locally.  It 
would know the correct peer using something like the [hint] context (or 
maybe just by using the existing hint context from extensions.conf).

	So after describing all of this, I have several questions:

1)  Any suggestions?  Does this make sense?  Is there a better way?

2)  How hard is this?  In terms of a bounty, are we talking hundreds or 
thousands of dollars?  I'm just trying to get a feel for the overall 
complexity of this request, not knowing what it would take to accomplish it.

	This will definitely end up being a bounty and would (hopefully) 
ultimately be included in Asterisk.  I am just looking for overall 
comments and suggestions before I begin with all of that.

Thanks!

--
Kristian Kielhofner



More information about the asterisk-dev mailing list