[asterisk-users] Call forwarding, callerID, and e911

John A. Sullivan III jsullivan at opensourcedevel.com
Tue Sep 15 12:35:56 CDT 2009


We were able to solve the below problem.  I'll post it in case someone
encounters the same issue.  No need to respond or even read unless you
see a better way.  Thanks - John

We have manually set callerID on our outbound lines to reflect the
appropriate DID both for e911 and to be polite to folks we call, e.g.:

exten => _1NXXNXXXXXX,1,Set(CALLERID(num)=5197546340)
exten => _1NXXNXXXXXX,n,Goto(outbound-US,${EXTEN},1)

This is working perfectly fine (numbers changed to protect the
innocent!) until someone forwards their phone.  When someone calls in
for them, the forwarded call becomes an outbound call and we are
overwriting the callerID rather than showing the original callerID.

Is there some way that I'm missing to distinguish between an outbound
call and a forwarded outbound call? Is there a better way to do what we
are doing? Thanks - John

We solved this with the following logic assuming outside callerIDs were
at least 7 digits long and internal extensions were less than 7 digits
(numbers changed to protect the real numbers):

exten => _1NXXNXXXXXX,1,ExecIf($[${CALLERID(num)} - 1000000 < 0]?Set(CALLERID(num)=6715728792))


-- 
John A. Sullivan III
Open Source Development Corporation
+1 207-985-7880
jsullivan at opensourcedevel.com

http://www.spiritualoutreach.com
Making Christianity intelligible to secular society




More information about the asterisk-users mailing list