[OpenSIPS-Users] contact after fix_nated_contact()
Bogdan-Andrei Iancu
bogdan at opensips.org
Mon May 30 15:44:53 CEST 2016
Hi Rahul,
the fix_nated_contact() replaces the IP and port from the Contact URI
with the source IP and port from network level - so, the outcome is
really predictable ; you can print the incoming contact $ct and the
source network coordinates $si and $sp - this will give all the info you
need to see.
Regards,
Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
http://www.opensips-solutions.com
On 23.05.2016 19:17, Gupta, Rahul wrote:
> Hi Alex, thanks for the quick reply. I don't see if msg_apply_changes() is available in opensips. When I use it, I get the bad config file error. I did add loadmodule textops.so
>
>
> Thanks
> Rahul Gupta
>
>
> ---------------------------------------------------------------------------
>
> Vote for IPC in the 2016 Waters Technology Awards. Winners are decided by people who are most important to us - our customers! Please vote for us (#27, #29) by "https://www.surveymonkey.com/r/R6Y27GJ".
>
>
>
> -----Original Message-----
> From: users-bounces at lists.opensips.org [mailto:users-bounces at lists.opensips.org] On Behalf Of Alex Balashov
> Sent: Monday, May 23, 2016 12:00 PM
> To: users at lists.opensips.org
> Subject: Re: [OpenSIPS-Users] contact after fix_nated_contact()
>
> On 05/23/2016 11:55 AM, Gupta, Rahul wrote:
>> How do I get the updated contact after fix_nated_contact(), for
>> example in the log statement $ct prints the old Contact.
>>
>> xlog("Contact before fix_nated_contact: $ct");
>>
>> fix_nated_contact();
>>
>> xlog("Contact after fix_nated_contact: $ct");
> You can run msg_apply_changes() after calling fix_nated_contact(), assuming it doesn't have any effects harmful to your cause:
>
> http://kamailio.org/docs/modules/4.4.x/modules/textopsx.html#textopsx.f.msg_apply_changes
>
> -- Alex
>
> --
> Alex Balashov | Principal | Evariste Systems LLC
> 1447 Peachtree Street NE, Suite 700
> Atlanta, GA 30309
> United States
>
> Tel: +1-800-250-5920 (toll-free) / +1-678-954-0671 (direct)
> Web: http://www.evaristesys.com/, http://www.csrpswitch.com/
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
More information about the Users
mailing list