[asterisk-dev] After a BYE, chan_sip need 32s to destroy a SIP dialog. bug or feature?

Kevin P. Fleming kpfleming at digium.com
Fri Sep 16 10:17:51 CDT 2011


On 09/16/2011 09:36 AM, Leo Leo wrote:

> The difference is: Version 1.4 don't follow the SIP recommendation and
> version 1.8 does.
>
> By the documment, after receiving a BYE, the dialog shall be destroyed
> after 32*T1 timer expires.

Correction: it's 64*T1, and T1 defaults to 500ms, so the result is 32 
seconds. In Asterisk, T1 is adjustable (but not lower than 100ms), so 
this interval can be reduced when it is safe to do so.

> As I remmember, the recommendation doesn't say anything about SDP and
> UDP ports. In asterisk, this is only freed when the dialog ends.

RFC3261 doesn't have anything to say about media ports at all; they 
aren't part of SIP, they are part of SDP and usage of RTP and UDPTL. It 
would be reasonable for Asterisk to shut down the ports that had been 
used by a SIP dialog, but it would not be safe to allow them to be 
re-used by another dialog, because the remote endpoint from the first 
dialog might still be sending media to them.

-- 
Kevin P. Fleming
Digium, Inc. | Director of Software Technologies
Jabber: kfleming at digium.com | SIP: kpfleming at digium.com | Skype: kpfleming
445 Jan Davis Drive NW - Huntsville, AL 35806 - USA
Check us out at www.digium.com & www.asterisk.org



More information about the asterisk-dev mailing list