>From: "Arun Kumar" <arunvoip@gmail.com>
>Date: Fri, 20 Apr 2007 17:58:10 +0400
>
>Hi,
>
>in my dial plan I've configured two trunks to make outbound calls (one
for
>national calls and other international). I want to allow only 2-3 extension
>to make use of my international trunk to make outbound calls so I want some
>kind of auth. based on their callerid . Please guide.
Just detect that a call is international, then branch out. e.g., if 011 is
the prefix required for international,
[outbound]
exten => _011.,1,Dial(Local/${EXTEN}/international)
exten => _X.,1,Dial(ZAP/g1/${EXTEN})
[international]
exten => _X.,1,GotoIf(${DBEXISTS(international/${CALLERID(NUMBER)})}?:deny)
exten => _X.,n,Dial(ZAP/g1/${EXTEN})
exten => _X.,n,Hangup; just in case
exten => _X.,n(deny),Playback(not-a-valid-number&try-again)
exten => _X.,n,DISA(nopassword,outbound)
This is assuming AstDB contains a family international that includes
extensions/ID's allowed. Hope this helps.
Yuan Liu
>thanks
>
>arun