[SR-Users] Dialog module's keep-alive feature uses wrong CSeq?

Daniel-Constantin Mierla miconda at gmail.com
Tue Apr 17 08:48:49 CEST 2018


Hello,

the keepalive is done via sort of a trick which needs to detect:

  - if one side is no longer connected to the network -- keepalive
results in retransmission timeout

  - if one side is no longer knowing the dialog - so call-id, to-tag and
from-tag values do not match -- keepalive results in 481 Call
Leg/Transaction Does Not Exist

Any other case is not relevant for the keepalive purpose of detecting if
a side is still in the call.

Therefore, CSeq is intentionally set to an lower value than expected by
each side, in order not to impact what is sent by each side.

If you want to do nat keepalive for the duration of the dialog, that can
be achieved by using nat_traversal. Or if you use a location service,
usrloc+nathelper does it for the registration session.

Cheers,
Daniel

On 17.04.18 08:25, Oded Arbel wrote:
>
>
> On Mon, Apr 16, 2018, 16:24 Dmitri Savolainen <savolainen at erinaco.ru
> <mailto:savolainen at erinaco.ru>> wrote:
>
>         Ideally I think Kamailio should send correct (i.e increasing)
>         CSeq numbers.
>
>     in my mind it can't be increased by kamailio because of:
>     1. kamailio send OPTIONS with cseq+1
>     2. media server may send some  indialog reinvite with cseq+1 and
>     then kamailio have to remember that OPTIONS and  translate
>     reinvite to cseq+2.
>
>
> Fair point, statelessness is important.
>
>
>     I don't know why for "ka-src" CSeq is 0 and for "ka-dst"  the one
>     is  equal: so may be it is possible to be fixed 
>
>
> I'll investigate, under the assumption everyone agrees it's a bug.
>
>
>
>          (for example BYE) to be dropped by the firewall.
>
>     this may be achieved by
>     1. usrloc pinging
>
>
> I'm not sure that is usrloc pinging, but if you mean nathelper's
> nat_ping, then that wouldn't work for me because it's only for MUAs
> that use REGISTER, which on my system does not always happen.
>
>     2. short re-registration period for endpoint (60 sec for ex)
>
>
> Aside from the fact that REGISTER is not guaranteed to ever happen,
> this is also a UA setting that can't be enforced by the server and has
> serious implications on battery life outside of a call.
>
>     3. let's media server send options by itself via kamailio
>
>
> This may or may not be possible on my setup, I'll have to investigate
> - thanks for the suggestion!
>
> -- 
>
> Oded Arbel
>
> oded.arbel at greenfieldtech.net <mailto:oded.arbel at greenfieldtech.net>
> Greenfield Tech <http://greenfieldtech.net/>
>
>
> _______________________________________________
> Kamailio (SER) - Users Mailing List
> sr-users at lists.kamailio.org
> https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users

-- 
Daniel-Constantin Mierla
www.twitter.com/miconda -- www.linkedin.com/in/miconda
Kamailio Advanced Training - April 16-18, 2018, Berlin - www.asipto.com
Kamailio World Conference - May 14-16, 2018 - www.kamailioworld.com

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-users/attachments/20180417/59899a84/attachment.html>


More information about the sr-users mailing list