Re: [rtcweb] JSEP-19: Impact of BYE on ssrc table (Appendix B)

Bernard Aboba <bernard.aboba@gmail.com> Tue, 21 March 2017 15:08 UTC

Return-Path: <bernard.aboba@gmail.com>
X-Original-To: rtcweb@ietfa.amsl.com
Delivered-To: rtcweb@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 91303129A04 for <rtcweb@ietfa.amsl.com>; Tue, 21 Mar 2017 08:08:04 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.698
X-Spam-Level:
X-Spam-Status: No, score=-2.698 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id zQbkCgCiXOcv for <rtcweb@ietfa.amsl.com>; Tue, 21 Mar 2017 08:08:02 -0700 (PDT)
Received: from mail-vk0-x231.google.com (mail-vk0-x231.google.com [IPv6:2607:f8b0:400c:c05::231]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id A17CB1299FD for <rtcweb@ietf.org>; Tue, 21 Mar 2017 08:08:00 -0700 (PDT)
Received: by mail-vk0-x231.google.com with SMTP id j64so82639323vkg.3 for <rtcweb@ietf.org>; Tue, 21 Mar 2017 08:08:00 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=oBWNYx/Vn7Z1S8DaXh20mVL+4oDV3V0os9n9BxgXlUA=; b=nQKaPNpcz+JGogy96Z8PumwBPOS7LG8pilg8vsjNDoXQ0gUsymVNaOVw7eeaGuaT5z m+I99LbWpIqki9RHCpbgOR1sdBJ0ZzLHkydScV7ovr83WTjG4DXwoPF/bl76q25scYUg c49zj0zUioAh8z6W5dcuA38k8imzd0g7Pd34Uwqfk0NRviEOuVq4fKUVhT33A+4HWQW1 2bJn0jiyABgyEG4yw3cawwOdxDUzwtsLhG14I09K6OFaRtspOqfSSCKfySyJCesql488 x79OxK3/5shQDzqwd2C3hzIYYY3X3Zg3rFRwpdBCGTFr840ERKGE/erXdHsZ5FLJDoHb OTPg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=oBWNYx/Vn7Z1S8DaXh20mVL+4oDV3V0os9n9BxgXlUA=; b=ZQc+fSThZIDyEIbWk3EoT4+Be8ujzffkfLqvTDykDp5Lf6AKRw/btXi8FZPihGuG5d dkq26YAteV6COt6wEaWafZnnW8h2i/KEUBuAxuBfJ6/vNSOu1AsnfBx+BF+PuAe6D/UP xivLonvJTFL1kUTHjDzxTDqO/Czwh8nYXqpFDPq3cKZeMMoZcLA+FgmaP5lDo7QrldeE ZsnpXHWSwaDl/yRcbQG8mFx25W3NUnkx9Qe/oqUSsyRGcpDB+gHBaehjtg06infN89hQ 2HpSVheZ4hgRva0KaLXk/zsOpVrKiyPYLYQVyuDOl0ukA07ApcZ4fm3doSeG8RT0Oe5R DBTA==
X-Gm-Message-State: AFeK/H1SgfgjJf/mVfAF1HoExqQ26CWIY2np+VUpI8mwcxp15QT80hm3cNovJS4IzBudbcZoYz3vy4eYbKyVSA==
X-Received: by 10.176.70.66 with SMTP id z2mr15715182uab.131.1490108879309; Tue, 21 Mar 2017 08:07:59 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.176.6.71 with HTTP; Tue, 21 Mar 2017 08:07:38 -0700 (PDT)
In-Reply-To: <a46cbd91-006a-2fdd-ab51-8edeb28839d0@ericsson.com>
References: <CAOW+2dvyV=mpY1Qh9ZQVirgAC3YUHT6dLxs+RPicKPGg9fKenw@mail.gmail.com> <30B46FE1-4E99-4622-8E2C-F4AA455D08D8@iii.ca> <a46cbd91-006a-2fdd-ab51-8edeb28839d0@ericsson.com>
From: Bernard Aboba <bernard.aboba@gmail.com>
Date: Tue, 21 Mar 2017 11:07:38 -0400
Message-ID: <CAOW+2duqz7mxFb7w0E_k9r3pdeTu7DJSGZpSpxCSMSPrT5jHKw@mail.gmail.com>
To: Magnus Westerlund <magnus.westerlund@ericsson.com>
Cc: Cullen Jennings <fluffy@iii.ca>, RTCWeb IETF <rtcweb@ietf.org>
Content-Type: multipart/alternative; boundary="f40304361e246d95ab054b3f0275"
Archived-At: <https://mailarchive.ietf.org/arch/msg/rtcweb/7EFwM_LEWUqfam5ztHKJcesBx_4>
Subject: Re: [rtcweb] JSEP-19: Impact of BYE on ssrc table (Appendix B)
X-BeenThere: rtcweb@ietf.org
X-Mailman-Version: 2.1.22
Precedence: list
List-Id: Real-Time Communication in WEB-browsers working group list <rtcweb.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/rtcweb>, <mailto:rtcweb-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/rtcweb/>
List-Post: <mailto:rtcweb@ietf.org>
List-Help: <mailto:rtcweb-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/rtcweb>, <mailto:rtcweb-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 21 Mar 2017 15:08:05 -0000

Consider the impact of calling transceiver.stop().  This stops the sender,
and then sends a BYE.  However, due to reordering, the RTCP BYE can arrive
while there are still RTP packets in flight, and if the signaled SSRCs are
removed they will be thrown away unnecessarily.

Another cause of a BYE could be an SSRC conflict.  However, in this case we
should expect MID SDES packets as well as the MID RTP header extension to
be emitted with the new SSRC, so that a new "latched" entry will be
installed. Therefore removing "latched" entries on receipt of a BYE does
not have the same consequences.

On Tue, Mar 21, 2017 at 10:16 AM, Magnus Westerlund <
magnus.westerlund@ericsson.com> wrote:

> Hi,
>
> I have to agree with Cullen here. If one sends a RTCP BYE on an SSRC that
> is signalled, then one better do an signalling update with a new signalled
> SSRC before starting the RTP stream if one changes ones mind about it being
> ended.
>
> Cheers
>
> Magnus
>
> Den 2017-03-17 kl. 03:30, skrev Cullen Jennings:
>
>>
>> Looking at the RTP specs ... it seems like it would not matter if an
>> endpoint initially learned about a SSRC via RTP or SDP, either way it
>> seems like the state for the SSRC should be mostly removed at the BYE.
>> Thoughts on why we would handle them differently ?
>>
>> (If we do need to handle them differently, this looks like an OK approach
>> )
>>
>>
>> On Mar 10, 2017, at 3:31 PM, Bernard Aboba <bernard.aboba@gmail.com
>>> <mailto:bernard.aboba@gmail.com>> wrote:
>>>
>>> In the algorithm described in Appendix B, SSRCs that are entered into
>>> the SSRC table due to signalling are not distinguished from those that
>>> are "latched" into the table dynamically.
>>>
>>> The distinction is important because only "latched" SSRCs should be
>>> removed due to receipt of a BYE (or a timeout).
>>>
>>> My suggestion of how to address this is to add a "D" flag to an SSRC
>>> table entry, indicating that the entry was added dynamically.
>>>
>>> For example:
>>>
>>>       If the packet has a MID, and the packet's extended sequence number
>>>       is greater than that of the last MID update, as discussed in
>>>       [RFC7941], Section 4.2.6
>>> <https://tools.ietf.org/html/rfc7941#section-4.2.6>, update the
>>> incoming SSRC mapping table
>>>       to include an entry [with the "D" flag set] that maps the packet's
>>>       SSRC to the "m=" line for that MID.
>>>
>>> Also:
>>>
>>>       If the packet's payload type is in the payload type table, update
>>>       the the incoming SSRC mapping table to include an entry
>>>       [with the "D" flag set] that maps the packet's SSRC to the "m="
>>>       line for that payload type.  In addition, route the packet to the
>>>       associated "m=" line and stop.
>>>
>>> Then when a BYE is received, check the "D" flag:
>>>
>>>       If the packet is of type BYE, it indicates that the RTP streams
>>>       referenced in the packet are ending.  Therefore, for each SSRC
>>>       indicated in the packet that is found in the incoming SSRC table,
>>>       first deliver a copy of the packet to the "m=" line associated
>>>       with that SSRC, but then [if the "D" flag is set] remove the
>>>       entry for that SSRC from the incoming SSRC table.
>>>
>>> _______________________________________________
>>> rtcweb mailing list
>>> rtcweb@ietf.org <mailto:rtcweb@ietf.org>
>>> https://www.ietf.org/mailman/listinfo/rtcweb
>>>
>>
>>
>>
>> _______________________________________________
>> rtcweb mailing list
>> rtcweb@ietf.org
>> https://www.ietf.org/mailman/listinfo/rtcweb
>>
>>
>
> --
>
> Magnus Westerlund
>
> ----------------------------------------------------------------------
> Media Technologies, Ericsson Research
> ----------------------------------------------------------------------
> Ericsson AB                 | Phone  +46 10 7148287
> Färögatan 6                 | Mobile +46 73 0949079
> SE-164 80 Stockholm, Sweden | mailto: magnus.westerlund@ericsson.com
> ----------------------------------------------------------------------
>
>