[SR-Users] Caller ID using From header

Johan Wilfer lists at jttech.se
Sat Sep 21 14:16:37 CEST 2013


2013-09-19 21:25, Daniel W. Graham skrev:
> My issue is I have 1 carrier that doesn't support PAI or RPID for caller ID. Second carrier supports RPID but not PAI. Still waiting verification from the others.
>
> This definitely seems like a big mess, I'd prefer to use PAI since it follows active RFC but the lack of support is surprising.
>
> I'm assuming my two options I'm left with are using DID as usernames to avoid From header changes, or modifying From header.
>
> If I'm forced to modify From header, where would be the place to do so with least negative affects?
>
> All CDR is performed on Asterisk.
>
> UA >> Proxy >> Asterisk >> Proxy >> Carrier
>

You can use the uac-module to change the From-header:
http://kamailio.org/docs/modules/stable/modules/uac.html

More specific the function: uac_replace_from

I use this for normalizing the format from my carriers and to my 
carriers (to the format they expect) so all calls from my Asterisks use 
the same format, regardless of carrier used for the call.

Make sure you only call uac_replace_from ONCE. From the doc:
"Known limitations: The “uac_replace_*” functions can only be run once 
on the same SIP request. Try to save needed changes in a pseudovariable 
and apply them once."

/Johan



More information about the sr-users mailing list