<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class="">Hi,</span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class=""> </span><span lang="EN-US" class=""><o:p class=""></o:p></span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class="">We have the following setup, with a queue server, running our own queue software, a main switch and a SBC.<o:p class=""></o:p></span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class=""> </span><span lang="EN-US" class=""><o:p class=""></o:p></span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class="">Queue <span class="SpellE">FreeSWITCH</span> -> Master <span class="SpellE">FreeSWITCH</span> -> <span class="SpellE">OpenSIPS</span> -> UA</span><span lang="EN-US" class=""><o:p class=""></o:p></span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class=""> </span><span lang="EN-US" class=""><o:p class=""></o:p></span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class="">When a queue dials multiple UA’s, an one of them answers, the rest is correctly sent a CANCEL with the LOOSE_RACE as X-Reason header.</span><span lang="EN-US" class=""><o:p class=""></o:p></span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class="">This is sent from the Queue <span class="SpellE">FreeSWITCH</span> to the Master <span class="SpellE">FreeSWITCH</span>, but when the Master <span class="SpellE">FreeSWITCH</span> sends this on to the <span class="SpellE">OpenSIPS</span>, the X-Reason header gets changed to ORIGINATOR_CANCEL.</span><span lang="EN-US" class=""><o:p class=""></o:p></span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class=""> <o:p class=""></o:p></span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class="">I found the code that does this, and <span class="SpellE">it seems to be this</span> block in <span class="SpellE">switch_ivr_originate</span>:<o:p class=""></o:p></span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class=""> </span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif; background-color: white;" class=""><span lang="EN-US" style="font-size: 9pt; font-family: Consolas; color: rgb(36, 41, 46);" class=""><a href="https://github.com/signalwire/freeswitch/blob/f9990221e6094886066ec2bf9685648135bd405a/src/switch_ivr_originate.c#L3664" style="color: rgb(149, 79, 114);" class="">https://github.com/signalwire/freeswitch/blob/f9990221e6094886066ec2bf9685648135bd405a/src/switch_ivr_originate.c#L3664</a><o:p class=""></o:p></span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class=""> </span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class="">This always sets the reason to be ORIGINATOR_CANCEL, no matter what was set by the upstream server.<o:p class=""></o:p></span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class=""> </span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class="">I know <span class="SpellE">FreeSWITCH</span> is not supposed behave like a proxy, and even <span class="SpellE">OpenSIPS</span> overwrites CANCEL reasons in its standard configuration, but would there be interest in us implementing proxying functionality, using a configuration item or channel variable, enabling this reason to be proxied through?<o:p class=""></o:p></span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class=""><br class=""></span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class="">Kind Regards</span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><span lang="EN-US" style="font-size: 11pt;" class="">Jon Schøpzinsky</span></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><br class=""></div><div style="margin: 0cm 0cm 0.0001pt; font-size: 12pt; font-family: Calibri, sans-serif;" class=""><br class=""></div></body></html>