[asterisk-dev] [Code Review] 3438: Implement SIP TImer C in Asterisk
Mark Michelson
reviewboard at asterisk.org
Wed Apr 23 09:13:03 CDT 2014
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/3438/#review11719
-----------------------------------------------------------
Like Matt, I'm also a bit confused on the use case for a proxy-specific timer. At the same time, though, I have to say that this can be a useful feature to have in case a situation were to arise where Asterisk sends out an INVITE, gets a provisional response (which kills timer B), and then never gets any further response. This would allow for the call to be torn down automatically in such a situation. In fact, I'm curious what a UAC is supposed to do in such a situation if it does not implement timer C.
/trunk/channels/chan_sip.c
<https://reviewboard.asterisk.org/r/3438/#comment21491>
RFC 3261 section 16.7, bullet point 2 states:
"...if the response is a provisional response with status codes 101 to 199 inclusive (i.e., anything but 100), the proxy MUST reset timer C..."
This else case needs to be modified to not execute if the response is a 100.
/trunk/channels/chan_sip.c
<https://reviewboard.asterisk.org/r/3438/#comment21492>
I'm a bit confused by this. If the configured timerc value is greater than 100 seconds, then that is considered invalid and the default of 180 seconds is used instead.
RFC 3261 Section 16.6, bullet point 11 states that timer C MUST be larger than 3 minutes. I would expect, then, that if the configured value were less than 180 seconds, that is when you would consider the configuration to be invalid and go with the default value of 180 seconds.
/trunk/channels/chan_sip.c
<https://reviewboard.asterisk.org/r/3438/#comment21493>
Use sscanf here instead of atoi. Like with the peer option, I think that if the value is less than 180, then it should be considered invalid.
/trunk/configs/sip.conf.sample
<https://reviewboard.asterisk.org/r/3438/#comment21494>
Since the other timers are configured with milliseconds, I suggest configuring timer c in milliseconds as well.
- Mark Michelson
On April 11, 2014, 8:41 a.m., Olle E Johansson wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/3438/
> -----------------------------------------------------------
>
> (Updated April 11, 2014, 8:41 a.m.)
>
>
> Review request for Asterisk Developers.
>
>
> Repository: Asterisk
>
>
> Description
> -------
>
> SIP Timer C is defined for proxys that forward messages. In some ways, we forward calls. It is activated when we receive a 100 trying and wait for any other message. If that's not received, timer C triggers and cancels the call attempt.
>
> This is required in an interoperability test I'm working with.
>
> Red dots will be handled in the way they deserve.
>
>
> Diffs
> -----
>
> /trunk/configs/sip.conf.sample 412166
> /trunk/channels/sip/include/sip.h 412166
> /trunk/channels/chan_sip.c 412166
>
> Diff: https://reviewboard.asterisk.org/r/3438/diff/
>
>
> Testing
> -------
>
> Passed interoperability testing with funky test tool.
>
>
> Thanks,
>
> Olle E Johansson
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20140423/241b47b3/attachment-0001.html>
More information about the asterisk-dev
mailing list