[Serusers] Adding +1 to From:/To: for E.164 compliance

Pietro Ravasio pietro.ravasio at abbeynet.it
Tue Aug 30 15:52:48 CEST 2005


on Tuesday, August 30, 2005 3:27 PM serusers-bounces at lists.iptel.org wrote:

> Greetings...
> 
> We are starting to work with a carrier which requires From:
> and To: to be in E.164 format (e.g. +17005551212).  prefix()
> only seems to change the INVITE, which doesn't appear to cut
> the mustard with these guys.  Is there any way to make this happen
> within SER? 

I suggest you to use textops module and subst functions, for example:

loadmodule "/your/path/to/textops.so"
...
subst_uri('/^sip:([0-9]*@.*)/sip:+1\1/i');

You can change anything within the body of a message, using subst instead of
subst_uri

Regards,
Pietro




More information about the sr-users mailing list