[SR-Users] remove rport in INVITE Via HDR and make kamailio behave asymmetric

Nuno Miguel Reis nmreis at student.dei.uc.pt
Sat Dec 11 05:04:10 CET 2021


Hi guys.

I've a scenario here where I'm receiving inbound traffic from a Mitel PBX
on a LAN environment with a bunch of router hops between kamailio and the
Mitel. Sometimes, not always, I get traffic from the MItel PBX where the
source port is changed in transit (some kind of NAT, still don't know where
exactly) from 5060 to a dynamic port different from 5060. Every INVITE
comes with rport in via header as:

..
Via: SIP/2.0/UDP 10.21.252.35:5060
;branch=z9hG4bK-524287-1---d6bac01809527627*;rport*
..

when this happens kamailio sends all the replies to the $si:$sp
symmetrically (force_rport behavior) and I would like to force the opposite
instead, making it asymmetric and sending the traffic to $si:5060 everytime.

I'm having a hard time forcing the *unforce*_rport() behavior. Does anyone
have a good suggestion for this?
Looking forward to hear from you.

Cheers,

--
Nuno Miguel Reis
Departamento de Engenharia Informática
Faculdade de Ciências e Tecnologia
Universidade de Coimbra
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-users/attachments/20211211/bf6c55aa/attachment.htm>


More information about the sr-users mailing list