[SR-Users] Callee BYE routing issue

Daniel W. Graham dan at cmsinter.net
Sat Apr 11 03:41:28 CEST 2020


I’ve tested with two different UA types and same thing happens, must be a result of the B2BUA sending the alias in the To header of the invite.
Example -

2020/04/10 12:31:36.851987 Proxy_IP:5060 -> NAT_Device_IP:58090
INVITE sip:399 at UA1_IP:60916;rinstance=8ec7d4acf9c3436c SIP/2.0
Record-Route: <sip:Poxy_IP;lr=on;ftag=as4220330a;did=a2c.1d81>
Via: SIP/2.0/UDP Proxy_IP;branch=z9hG4bKbfa9.767ffbe5f0e31be8c27932008d28844e.0
Via: SIP/2.0/UDP B2BUA_IP:5160;received= B2BUA_IP;branch=z9hG4bK22bd58aa;rport=5160
Max-Forwards: 69
From: "Dan Test" <sip:398@ B2BUA_IP:5160>;tag=as4220330a
To: <sip:399 at UA1_IP:60916;rinstance=8ec7d4acf9c3436c;alias=NAT_Device_IP~58090~1>
Contact: <sip:398@ B2BUA_IP:5160>
Call-ID: 1835b7eb541743600e1b79c07615206c@ B2BUA_IP:5160
CSeq: 102 INVITE
User-Agent: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Date: Fri, 10 Apr 2020 16:31:34 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE
Supported: replaces, timer
P-Asserted-Identity: "Dan Test" <sip:398 at B2BUA_IP>
Content-Type: application/sdp
Content-Length: 566

The alias is in the contact header for the invite sent by kamailio, so everything looks fine there.

Thanks,

-dan


From: sr-users <sr-users-bounces at lists.kamailio.org> on behalf of Sergiu Pojoga <pojogas at gmail.com>
Reply-To: "Kamailio (SER) - Users Mailing List" <sr-users at lists.kamailio.org>
Date: Friday, April 10, 2020 at 2:29 AM
To: "Kamailio (SER) - Users Mailing List" <sr-users at lists.kamailio.org>
Subject: Re: [SR-Users] Callee BYE routing issue

From: <sip:399 at UA1_IP:52884;rinstance=705e0af5f4be485c;alias=NAT_Device_IP:~57808~1>;tag=64f4b712

Something wrong with the above From, no closing ">", also there's no place for alias in From headers.

On Fri, Apr 10, 2020 at 1:25 AM Daniel W. Graham <dan at cmsinter.net<mailto:dan at cmsinter.net>> wrote:
Have an issue with BYE routing in a lab setup, any suggestions on what I should be looking at?

Topology:

UA1  <-> NAT device 1 <-> Proxy1 <-> Registrar/B2BUA <-> Proxy1 <-> NAT device 1 <-> UA2

All UA to UA calls flow through B2BUA.

All IP’s are public except for UA1 and UA2.

-Both endpoints can call each other.
-If the caller hangs up first, BYE is routed properly.
-If the callee hangs up first, BYE causes proxy to send 478.

On calls where BYE results in 478:
if(!isdsturiset()) {
    ……….…………………….not executed
    handle_ruri_alias()
}
return;

Example issue call: UA2 to UA1, UA1 hang-up.

Apr 10 00:31:28 edgedev /usr/local/sbin/kamailio[5317]: ERROR: {1 2 BYE 24dc84a4592515245177483c2a657042 at B2BUA_IP:5160} *** cfgtrace:dbg_cfg_trace(): request_route=[DLGURI] c=[/usr/local/etc/kamailio/kamailio.cfg] l=540 a=16 n=if
Apr 10 00:31:28 edgedev /usr/local/sbin/kamailio[5317]: ERROR: {1 2 BYE 24dc84a4592515245177483c2a657042 at B2BUA_IP:5160} *** cfgtrace:dbg_cfg_trace(): request_route=[DLGURI] c=[/usr/local/etc/kamailio/kamailio.cfg] l=532 a=24 n=isdsturiset
Apr 10 00:31:28 edgedev /usr/local/sbin/kamailio[5317]: ERROR: {1 2 BYE 24dc84a4592515245177483c2a657042 at B2BUA_IP:5160} *** cfgtrace:dbg_cfg_trace(): request_route=[DLGURI] c=[/usr/local/etc/kamailio/kamailio.cfg] l=540 a=2 n=return
………..
Apr 10 00:31:28 edgedev /usr/local/sbin/kamailio[5317]: ERROR: {1 2 BYE 24dc84a4592515245177483c2a657042 at B2BUA_IP:5160} tm [ut.h:245]: uri2dst2(): bad_uri: [sip::;transport=]
Apr 10 00:31:28 edgedev /usr/local/sbin/kamailio[5317]: ERROR: {1 2 BYE 24dc84a4592515245177483c2a657042 at B2BUA_IP:5160} tm [t_fwd.c:1732]: t_forward_nonack(): failure to add branches
Apr 10 00:31:28 edgedev /usr/local/sbin/kamailio[5317]: ERROR: {1 2 BYE 24dc84a4592515245177483c2a657042 at B2BUA_IP:5160} *** cfgtrace:dbg_cfg_trace(): request_route=[RELAY] c=[/usr/local/etc/kamailio/kamailio.cfg] l=275 a=24 n=sl_reply_error
Apr 10 00:31:28 edgedev /usr/local/sbin/kamailio[5317]: ERROR: {1 2 BYE 24dc84a4592515245177483c2a657042 at B2BUA_IP:5160} sl [sl_funcs.c:401]: sl_reply_error(): stateless error reply used: Unresolvable destination (478/SL)
Apr 10 00:31:28 edgedev /usr/local/sbin/kamailio[5317]: ERROR: {1 2 BYE 24dc84a4592515245177483c2a657042 at B2BUA_IP:5160} *** cfgtrace:dbg_cfg_trace(): request_route=[RELAY] c=[/usr/local/etc/kamailio/kamailio.cfg] l=277 a=2 n=exit

2020/04/10 00:31:28.625060 NAT_Device_IP:57808 -> Proxy_IP:5060
BYE sip:398 at B2BUA_IP:5160 SIP/2.0
Via: SIP/2.0/UDP UA1_IP:52884;branch=z9hG4bK-524287-1---43b5f31829f20952
Max-Forwards: 70
Route: <sip:Proxy_IP;lr=on;ftag=as78671fd9;did=b1b.a27>
Contact: <sip:399 at UA1_IP:52884>
To: "Dan Test" <sip:398 at B2BUA_IP:5160>;tag=as78671fd9
From: <sip:399 at UA1_IP:52884;rinstance=705e0af5f4be485c;alias=NAT_Device_IP:~57808~1>;tag=64f4b712
Call-ID: 24dc84a4592515245177483c2a657042 at B2BUA_IP:5160
CSeq: 2 BYE
User-Agent: xxxxxxxxxxxxxxxx
Content-Length: 0

#########################################

For comparison, here is a BYE from another test call: UA1 to UA2, UA1 hang-up.

This BYE was routed correctly.

2020/04/10 00:44:02.688608 NAT_Device_IP:57808 -> Proxy_IP:5060
BYE sip:398 at B2BUA_IP:5160 SIP/2.0
Via: SIP/2.0/UDP UA1_IP:52884;branch=z9hG4bK-524287-1---ce36df02e8a80a48
Max-Forwards: 70
Route: <sip:Proxy_IP;lr=on;ftag=9078f232;did=49e.8c01>
Contact: <sip:399 at UA1_IP:52884>
To: <sip:398 at B2BUA_IP>;tag=as5874901f
From: <sip:399 at B2BUA_IP:5060>;tag=9078f232
Call-ID: 103104NGU1NjkxNGZkYmM4MzA3Y2FkMzY1OGNkZTZmMTMyZDU
CSeq: 3 BYE
User-Agent: xxxxxxxxxxxxxxxx
Authorization: Digest username= xxxxxxxxxxxxxxxx
Content-Length: 0

-dan

_______________________________________________
Kamailio (SER) - Users Mailing List
sr-users at lists.kamailio.org<mailto:sr-users at lists.kamailio.org>
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-users/attachments/20200411/ebf66656/attachment.html>


More information about the sr-users mailing list