[OpenSIPS-Users] uac_replace_from() problem in INVITE

sammy sanms at 126.com
Mon Jul 25 18:00:16 CEST 2011


Hello, ValdIt works! Great! Thanks a lot, Vald! :)I remove the subst('/^From:(.+)sip:(.+)@([0-9.:]+)(.+)$/From:\1sip:\2@$Ri:$Rp\4/i') and re-captured the SIP message, uac_replace_from() works as it should be. I do NOT know the From header can be modified by subst() again. Now I knew the uac_replace_to(), uac_replace_from() and subst() can only modify the same part of the message once in one dialog.Thank you andBest RegardsSammy>------------------------------
>
>Date: Mon, 25 Jul 2011 11:26:56 +0300
>From: Vlad Paiu <vladpaiu at opensips.org>
>Subject: Re: [OpenSIPS-Users] uac_replace_from() problem in INVITE
>To: users at lists.opensips.org
>Message-ID: <4E2D28D0.9010303 at opensips.org>
>Content-Type: text/plain; charset="x-gbk"; Format="flowed"
>
>Hello sammy,
>
>Just took a quick look through your config and I saw that you are using 
>both uac_replace_from() and 
>(subst('/^From:(.+)sip:(.+)@([0-9.:]+)(.+)$/From:\1sip:\2@$Ri:$Rp\4/i')), thus 
>having two simultaneous modifications on the From header when the 
>message goes through your script, which might lead to the bogus From 
>header you are experiencing.
>
>Please try to rework your script and only modify the From header once, 
>and let me know if the problem persists.
>
>
>Regards,
>
>-- 
>Vlad Paiu
>OpenSIPS Developer
>
>
>
>On 07/25/2011 04:39 AM, sammy wrote:
>> Hi, Vald
>>
>> Thanks for your reply. :)
>> I re-check my opensips script, but only use uac_replace_from() one 
>> time, i post it here :
>> http://pastebin.com/gTKS3kGF
>>
>> Thanks in advance.
>>
>> Best regards
>> Sammy
>>
>> _______________________________________________
>> Users mailing list
>> Users at lists.opensips.org
>> http://lists.opensips.org/cgi-bin/mailman/listinfo/users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20110726/a59593fb/attachment.htm>


More information about the Users mailing list