Hi,

 

Yes I’m interested in your patch; I’d like to be able to send multiple headers (Diversion in my case). For receiving there’s already a solution with the param parse-all-invite-headers=true.

 

Best regards,

Sjoerd.

Van: Vallimamod Abdullah - SIP Solutions [mailto:vma@sip.solutions]
Verzonden: woensdag 22 augustus 2018 19:02
Aan: Sjoerd Boomstra
Onderwerp: Re: [Freeswitch-users] Multiple Diversion headers

 

Hi,

 

I have faced the same issue when passing certification tests with Orange-FR. There is a bug in freeswitch that makes it impossible to manage multiple headers with same name, either receiving or sending; the last value overwrites all the previous ones.

 

I wrote a patch to correct it. I didn't get the chance to publish it yet, but if you are interested I can share it with you. 

 

Btw, I provide freeswitch consulting services for carriers. If you have any need, feel free to ping me.

 

 

Best Regards,
-- 
Vallimamod Abdullah

SIP Solutions

vma@sip.solutions
+33 6 62 60 68 97

 



On 22 Aug 2018, at 16:10, Sjoerd Boomstra <S.Boomstra@telecats.nl> wrote:

 

Hi All,

 

I’m struggling with multiple Diversion headers. In our case we have an incoming call with multiple diversion headers, we do some processing and want to add a diversion header ourselves to the outgoing call.

 

What I’ve found so far is that for inbound calls one needs to set the profile param parse-all-invite-headers=true, this results in a sip_i_Diversion variable that uses the ARRAY:: syntax and has all the values I want. So far so good.

 

Example: 

ARRAY::<sip:Carol@uas2.isp.com>;privacy=off;reason=unconditional;counter=2;screen=no|:<sip:Bert@uas2.isp.com>;privacy="full";reason=user-busy;counter=3;screen=no|:<sip:Bob@uas1.isp.com>;reason=do-not-disturb;counter=1

 

For the outbound call it’s more difficult, I cannot get FreeSwitch to produce multiple Diversion headers. The only syntax I’ve found is using comma’s in the value, like this:

<action application="export" data="sip_h_Diversion=<sip:Carol@uas2.isp.com>;privacy=off;reason=unconditional;counter=2;screen=no,<sip:Bert@uas2.isp.com>;privacy="full";reason=user-busy;counter=3;screen=no,<sip:Bob@uas1.isp.com>;reason=do-not-disturb;counter=1,<sip:Bert@uas2.isp.com>;reason=user-busy"/>

 

This results in a single diversion header with the contents I put in. From the RFC’s I understand that this is technically equivalent to 4 (in my case) Diversion headers, is this true?

 

Is there a way I can convince FS to generate multiple separate diversion headers?

 

Best regards,

Sjoerd.

 

BTW I’ve tested with FS 1.6.20 and 1.4.26