On Fri, 2009-08-07 at 17:18 +0200, harry R wrote:
> Anyone know how to use regcontext et regexten parameter from sip.conf
> and can give an example ?

Sure... let's say I have a phone with the following configuration in
sip.conf:

[myphone]
type=friend
context=inside
host=dynamic ; phone will register w/ Asterisk
secret=mysecret
regcontext=some-context
regexten=6123

When this phone registers, Asterisk will automatically create an
extension that looks like:

exten => 6123,1,NoOp()

in the [some-context] context.  I use this in combination with DUNDi by
setting the regcontext setting to point at my DUNDi advertising context,
so that when my phone registers to a particular Asterisk server in my
DUNDi cloud, calls get routed to the proper server.  I'm sure there are
other uses for it as well.  For example, you might have something like
this:

exten => _6XXX,1,Playback(this-phone-is-not-registered)

exten => 6123,2,Dial(SIP/myphone,20)
exten => 6123,3,Voicemail(6...@default,u)

Notice my priority numbering on extension 6123?  If the phone is
registered, then Asterisk creates priority number one for me.
Otherwise, the pattern match plays a message saying that the phone is
not registered.

-- 
Jared Smith
Training Manager
Digium, Inc.


_______________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

AstriCon 2009 - October 13 - 15 Phoenix, Arizona
Register Now: http://www.astricon.net

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Reply via email to