[asterisk-bugs] [Asterisk 0011129]: Set CHANNELFORWARD variable to allow more control over setting CALLERID(num) on calls forwarded by 302 "Moved Temporarily"

noreply at bugs.digium.com noreply at bugs.digium.com
Wed Oct 31 12:31:05 CDT 2007


The following issue has been UPDATED. 
====================================================================== 
http://bugs.digium.com/view.php?id=11129 
====================================================================== 
Reported By:                eurodrew555
Assigned To:                
====================================================================== 
Project:                    Asterisk
Issue ID:                   11129
Category:                   Applications/app_dial
Reproducibility:            always
Severity:                   feature
Priority:                   normal
Status:                     new
Asterisk Version:            SVN 
SVN Branch (only for SVN checkouts, not tarball releases):  1.4  
SVN Revision (number only!): 87775 
Disclaimer on File?:        N/A 
Request Review:              
====================================================================== 
Date Submitted:             10-31-2007 12:16 CDT
Last Modified:              10-31-2007 12:31 CDT
====================================================================== 
Summary:                    Set CHANNELFORWARD variable to allow more control
over setting CALLERID(num) on calls forwarded by 302 "Moved Temporarily"
Description: 
Example scenario

Default callerid on ISDN30s (set by carrier) is 0208 123 4567.
This is also our helpdesk number.

User SIP/david has an extension of 4488 with an outgoing callerid number
of 0208 123 4488.

A user calls in from mobile 0777 123 4567 to 0208 123 4488.
David's dial plan routes his call to his UA at SIP/david

The SIP/david UA is a Linksys SPA-942, with call forwarding set to call
forward to his mobile on 0777 400 9292.

Asterisk CLI shows up as:

-- Called user
    -- Got SIP response 302 "Moved Temporarily" back from 10.0.0.2
    -- Now forwarding Zap/116-1 to 'Local/07774009292 at internal' (thanks to
SIP/david-01505f80)

What we would like to do:

We would like to be able to set CALLERID(num)=02081239999 so that our user
can see the call has been forwarded from his extension (as he recognises
his own callerid number)

Why we can't do it:

Once the call is forwarded by Asterisk we are unable to find the original
user that forwarded the call (SIP/david), so we are unable to correctly set
the CALLERID(num). We can't use the incoming caller's callerid of
07771234567 as our carrier only allows us to set callerid of our own DIDs.


If we cannot set the callerid correctly, then the default callerid of the
ISDN30 is used (by default by the carrier) and then our user (David) then
incorrectly believes he is receiving a call from our helpdesk, when in fact
the call is being forwarded from his extension.

If the CHANNELFORWARD variable (which in this case would be
SIP/david-01505f80) is set, then we are able to do a simply MySQL lookup to
retrieve his callerid number from his username, and then correctly set the
callerid of the forwarding call to the extension that is forwarding the
call.

Our user (David) then sees that he is receiving a call from his own
extension, and therefore knows that it is a forwarded call.

====================================================================== 

---------------------------------------------------------------------- 
 qwell - 10-31-07 12:31  
---------------------------------------------------------------------- 
Please only upload patches as attachments. 

Issue History 
Date Modified   Username       Field                    Change               
====================================================================== 
10-31-07 12:31  qwell          Note Added: 0072827                          
10-31-07 12:31  qwell          Description Updated                          
10-31-07 12:31  qwell          Additional Information Updated                   

======================================================================




More information about the asterisk-bugs mailing list