[OpenSIPS-Users] How to intercept CANCEL and change fu&tu

Bogdan-Andrei Iancu bogdan at opensips.org
Mon Dec 9 08:31:20 UTC 2024


Hi,

The CANCEL is internally generated as it goes hop-by-hop (when using 
transaction stateful mode).

How do you change the FROM/TO  URIs? if you change them with the 
uac_replace_to/from functions, the CANCEL will be accordingly generated, 
no need for any manual intervention.

Regards,

Bogdan-Andrei Iancu

OpenSIPS Founder and Developer
   https://www.opensips-solutions.com
   https://www.siphub.com

On 27.11.2024 05:58, 陈子妍 wrote:
> Hello, I am green hand here.
> In my case, with topology_hiding and fU&tU rewrite, I have to mask 
> initial fU & tU when proxying sip messages. All succeed, but CANCEL 
> message inited locally by server, I can not change fu & tu, If I do it 
> manually, tm can not match. Any suggestions?
>
> thing I have:
>
> *CANCEL sip:a.rewrite at b.domain:5060 SIP/2.0
> Via: SIP/2.0/UDP proxy.domain:5060;branch=z9hG4bK932b.33154787.0
> From: <sip:a at a.domain>;tag=877556c1e3e94f9da53100d72eefa195
> Call-ID: TArYzB5EQMMZ3w1Yi5JAwtle2Bne0QGXmovMTc-
> To: <sip:b at proxy.domain>
> CSeq: 26759 CANCEL
> Max-Forwards: 70
> Reason: SIP;cause=487;text="ORIGINATOR_CANCEL"
> User-Agent: OpenSIPS (3.5.2 (x86_64/linux))
> Content-Length: 0 *
>
>
> thing I want:
>
> *CANCEL sip:a.rewrite at b.domain:5060 SIP/2.0
> Via: SIP/2.0/UDP proxy.domain:5060;branch=z9hG4bK932b.33154787.0
> From: <sip:a.rewrite at a.domain>;tag=877556c1e3e94f9da53100d72eefa195
> Call-ID: TArYzB5EQMMZ3w1Yi5JAwtle2Bne0QGXmovMTc-
> To: <sip:b.rewrite at proxy.domain>
> CSeq: 26759 CANCEL
> Max-Forwards: 70
> Reason: SIP;cause=487;text="ORIGINATOR_CANCEL"
> User-Agent: OpenSIPS (3.5.2 (x86_64/linux))
> Content-Length: 0 *
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20241209/8b050729/attachment.html>


More information about the Users mailing list