[OpenSIPS-Users] UAC module causing malformed CANCEL

Ben Newlin Ben.Newlin at genesys.com
Fri Dec 7 13:10:49 EST 2018


Certainly. I was going to ask next if that would be a better place to report the issue.

I have opened an issue here: https://github.com/OpenSIPS/opensips/issues/1555

Ben Newlin

From: Bogdan-Andrei Iancu <bogdan at opensips.org>
Date: Friday, December 7, 2018 at 12:16 PM
To: OpenSIPS users mailling list <users at lists.opensips.org>, Ben Newlin <Ben.Newlin at genesys.com>
Subject: Re: [OpenSIPS-Users] UAC module causing malformed CANCEL

Hi Ben,

Thanks for the report - could you please open a bug report on GITHUB with the relevant information ? It will be easier for us to track it.

Best regards,

Bogdan-Andrei Iancu

OpenSIPS Founder and Developer


OpenSIPS Summit 2019

On 12/05/2018 05:17 PM, Ben Newlin wrote:

I have found an issue with using the UAC module to replace the From/To headers. When one of these headers is the last header in a SIP INVITE, the UAC module is injecting an extra line break in subsequent CANCEL requests causing an invalid request. This happens when either of these headers are the last header in the originally received INVITE, but also if they become the last header due to modifications made to the original INVITE, e.g. if the last 2 headers were To followed by P-Asserted-Identity and the script processing calls remove_hf(“P-Asserted-Identity”) thus making the To header last.

I have only seen this happen on a CANCEL request. Other sequential requests like BYE or re-INVITE are not malformed.

A tcpdump capture of the message sequence can be found here: https://pastebin.com/myDVU5Jz<https://pastebin.com/myDVU5Jz>. Note the extra whitespace line in the second CANCEL message forwarded from OpenSIPS (

Ben Newlin


Users mailing list

Users at lists.opensips.org<mailto:Users at lists.opensips.org>


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20181207/d2c72e74/attachment.html>

More information about the Users mailing list