It seems that TOPOS is not working properly on RE-INVITE and stop masking IP and contact on some RE-INVITE.
When a RE-INVITE is send with Kamailio IP as Request-URI TOPOS is not operating.
Note : we are using the HTABLE trick to rewrite $ru and match the call but we would need to have TOPOS re-evaluating the dialog once done.
We use a standard configuration with 2 modifications.
in route[DISPATCH] to set the HTABLE
if(is_method("INVITE")) {
$sht(ct=>$ci::$ft) = $sel(contact.uri);
}
in route[WITHINDLG] to find the call if R-URI = myself
if(has_totag() && uri==myself) {
if($sht(ct=>$ci::$ft) != $null && $T_reply_code > 400) $shtex(ct=>$ci::$ft) = 10 ;
if($sht(ct=>$ci::$tt) != $null) {
$ru = $sht(ct=>$ci::$tt);
if (is_method("BYE")) $shtex(ct=>$ci::$tt) = 10 ;
route(RELAY);
}
}
As you can see in the PCAP the RE-INVITE goes directly to calling stating with the Contact not updated and the 200 OK is also sent to called party with wrong Contact info too.
topos-issue.zip
This behavior breaks the BYE procedure.
Any advice ?
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.