[Serusers] Re: How to change Caller ID in FROM field ?

lawrence k.y. lin lawlin888 at hotmail.com
Thu Dec 21 21:02:46 CET 2006


Steve,

    Thanks for your help regardin the Caller ID in FROM field in your 
previous email.
    It was working with the your suggestion for 'replace' to hard-code the 
FROM field.
    I would like to extend it to any users which has a Caller ID (normal 
phone number) mapping to SIP account and stored in Postgres database.
    When someone calls from SIP device, I use exec_msg to call the external 
C program which retrieves the Caller ID related to this SIP account. The 
problem is how to pass this data back to SER and put into FROM field ? 
Please advise,

   Thanks and Regards,

Larry

>From: Steve Blair <blairs at isc.upenn.edu>
>To: "lawrence k.y. lin" <lawlin888 at hotmail.com>
>CC: serusers at lists.iptel.org
>Subject: Re: [Serusers] Re: How to change Caller ID in FROM field ?
>Date: Tue, 24 Oct 2006 18:57:42 -0400
>
>
>You can do this several ways. I use to just completely replace the From 
>header but this screwed up call accounting (for callers with caller ID 
>blocking enabled) which we do in our Cisco gateways. Now I append an 
>Remote-Party-ID header leaving the Fromheader intact for accounting 
>purposes. Try one of the following:
>
>1)  replace("^From:(.*)>" , "From: \"Anonymous\" 
><sip:anonymous at invalid.nowhere>");
>
>   Where the second string contains whatever you want the caller ID info to 
>be. This example is for caller ID blocking.
>
>2)
>
>if (append_rpid_hf("Anonymous 
><sip:","@upenn.edu>;party=calling;id-type=subscriber;screen=yes")) {
>} else {
>     log(1, "RPID not found\n");
>};
>
>Of course this requires other configuration items. You may also want to add 
>the following:
>
>modparam("auth", "rpid_prefix", "<sip:")
>modparam("auth", "rpid_suffix",
>"@upenn.edu;user=phone>;party=calling;screen=no;id-type=subscriber;privacy=off")
>#
>
>-Steve
>
>lawrence k.y. lin wrote:
>
>>Hi all,
>>
>>    Appreciate if someone can give me a suggestion or even an answer.
>>    Since the call from SIP device to PSTN phone did not have Caller ID 
>>and our Telco carriers request for the Caller ID, we have to set a number 
>>before the calls are routed to PSTN gateway.
>>    I did it in Asterisk before with the function calls SetCallerID(CLID) 
>>or Set(CALLERID(number)=CLID) (depends on the Asterisk version) and these 
>>function calls worked. But because of the scalabliity issue, I changed to 
>>SER and would like to do the similar thing as in Asterisk.
>>    I read the SER document and awared SIP_HF_FROM has the data for the 
>>entired FROM field. Is there any other variables for Caller ID only ?
>>    I searched the mailing list for SER and did not find any related topic 
>>(only found one with title: caller-id with raius using sip-rpid, but it is 
>>irrelevant).
>>
>>   Thanks in advance.
>>
>>Larry
>>
>>_________________________________________________________________
>>Try the next generation of search with Windows Live Search today!  
>>http://imagine-windowslive.com/minisites/searchlaunch/?locale=en-us&source=hmtagline
>>
>>
>>_______________________________________________
>>Serusers mailing list
>>Serusers at lists.iptel.org
>>http://lists.iptel.org/mailman/listinfo/serusers
>>

_________________________________________________________________
Get FREE Web site and company branded e-mail from Microsoft Office Live 
http://clk.atdmt.com/MRT/go/mcrssaub0050001411mrt/direct/01/




More information about the sr-users mailing list