[OpenSIPS-Users] B2b custom_header not working!

Jorge Henrique Pinho jorge-h-pinho at ext.ptinovacao.pt
Fri Nov 23 20:07:49 CET 2012


Hi nick,
I think this bug is reported and fixed in version 1.8 (http://sourceforge.net/tracker/?func=detail&aid=3316230&group_id=232389&atid=1086410). But i am using version 1.7.2. and i really need to preserve headers using this version.
Is there a way of using custom_headers in b2b, without the headers defined to be preserved appearing repeated in the message generated by b2b module?

Thank you


Jorge Pinho
Analyst/Developer
Network Platforms and Multimedia Solutions
Multimedia Division
________________________________________
From: users-bounces at lists.opensips.org [users-bounces at lists.opensips.org] On Behalf Of Nick Altmann [nick.altmann at gmail.com]
Sent: 23 November 2012 11:10
To: OpenSIPS users mailling list
Subject: Re: [OpenSIPS-Users] B2b custom_header not working!

I use own custom patch to support insert_hf/remove_hf (and another NAT functions like fix_nated_contact) in all b2b_routes, but trick with $var works without patch. I've tested recently.

--
Nick


2012/11/23 Jorge Henrique Pinho <jorge-h-pinho at ext.ptinovacao.pt<mailto:jorge-h-pinho at ext.ptinovacao.pt>>
Hi Nick,

I tried this approach and leads to unexpected behaviour by opensips http://www.mail-archive.com/users@lists.opensips.org/msg22064.html.
Custom headers doesn't work either, any idea on how to address this problem?

Kind regards

Jorge Pinho
Analyst/Developer
Network Platforms and Multimedia Solutions
Multimedia Division
________________________________________
From: users-bounces at lists.opensips.org<mailto:users-bounces at lists.opensips.org> [users-bounces at lists.opensips.org<mailto:users-bounces at lists.opensips.org>] On Behalf Of Nick Altmann [nick.altmann at gmail.com<mailto:nick.altmann at gmail.com>]
Sent: 23 November 2012 10:11
To: OpenSIPS users mailling list
Subject: Re: [OpenSIPS-Users] B2b custom_header not working!

Main route:
$var(orig-to) = $hdr(To);
b2b_init_request("top hiding");

Local route:
remove_hf("To");
append_hf("To: $var(orig-to)\r\n", "From");

--
Nick

2012/11/23 Jorge Henrique Pinho <jorge-h-pinho at ext.ptinovacao.pt<mailto:jorge-h-pinho at ext.ptinovacao.pt><mailto:jorge-h-pinho at ext.ptinovacao.pt<mailto:jorge-h-pinho at ext.ptinovacao.pt>>>
Hi, i am trying to preserve the To header and the User-Agent header. It is possible to do that?

Kind regards

Jorge Pinho
Analyst/Developer
Network Platforms and Multimedia Solutions
Multimedia Division
________________________________________
From: users-bounces at lists.opensips.org<mailto:users-bounces at lists.opensips.org><mailto:users-bounces at lists.opensips.org<mailto:users-bounces at lists.opensips.org>> [users-bounces at lists.opensips.org<mailto:users-bounces at lists.opensips.org><mailto:users-bounces at lists.opensips.org<mailto:users-bounces at lists.opensips.org>>] On Behalf Of Muhammad Shahzad [shaheryarkh at gmail.com<mailto:shaheryarkh at gmail.com><mailto:shaheryarkh at gmail.com<mailto:shaheryarkh at gmail.com>>]
Sent: 22 November 2012 18:35
To: OpenSIPS users mailling list
Subject: Re: [OpenSIPS-Users] B2b custom_header not working!

What headers you are trying to preserve, its possible that the headers your are try to save are mandatory headers necessary for B2BUA function, which will get duplicated if you try to preserve then from leg 1 to leg 2. See custom_headers documentation for more info.

Thank you.


On Thu, Nov 22, 2012 at 5:25 PM, Jorge Henrique Pinho <jorge-h-pinho at ext.ptinovacao.pt<mailto:jorge-h-pinho at ext.ptinovacao.pt><mailto:jorge-h-pinho at ext.ptinovacao.pt<mailto:jorge-h-pinho at ext.ptinovacao.pt>><mailto:jorge-h-pinho at ext.ptinovacao.pt<mailto:jorge-h-pinho at ext.ptinovacao.pt><mailto:jorge-h-pinho at ext.ptinovacao.pt<mailto:jorge-h-pinho at ext.ptinovacao.pt>>>> wrote:
Hi all,
I have installed opensips-1.7.2-2.el5 and I am using b2b module.
I need to preserve some headers that b2b module changes. I was using avp and textops modules in local_route to accomplish that. But this lead to unexpected behaviours by opensips.
So i define the custom_headers variable in my configuration (http://www.opensips.org/html/docs/modules/1.7.x/b2b_logic.html#id250020), and the message that b2b passes to the other side of the dialog has the preserve headers repeated. One header with the original value and other with the new value generated by b2b module.
Is this the correct behaviour? How do i solve this?

Thanks in advance,

Jorge Pinho
_______________________________________________
Users mailing list
Users at lists.opensips.org<mailto:Users at lists.opensips.org><mailto:Users at lists.opensips.org<mailto:Users at lists.opensips.org>><mailto:Users at lists.opensips.org<mailto:Users at lists.opensips.org><mailto:Users at lists.opensips.org<mailto:Users at lists.opensips.org>>>
http://lists.opensips.org/cgi-bin/mailman/listinfo/users

_______________________________________________
Users mailing list
Users at lists.opensips.org<mailto:Users at lists.opensips.org><mailto:Users at lists.opensips.org<mailto:Users at lists.opensips.org>>
http://lists.opensips.org/cgi-bin/mailman/listinfo/users

_______________________________________________
Users mailing list
Users at lists.opensips.org<mailto:Users at lists.opensips.org>
http://lists.opensips.org/cgi-bin/mailman/listinfo/users



More information about the Users mailing list