Re: [MMUSIC] [rtcweb] Updating JSEP and BUNDLE: Semantics of same port in multiple m- lines

Roman Shpount <roman@telurix.com> Tue, 02 February 2021 03:39 UTC

Return-Path: <roman@telurix.com>
X-Original-To: mmusic@ietfa.amsl.com
Delivered-To: mmusic@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 13F9F3A16F5 for <mmusic@ietfa.amsl.com>; Mon, 1 Feb 2021 19:39:19 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.898
X-Spam-Level:
X-Spam-Status: No, score=-1.898 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HTML_MESSAGE=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=unavailable autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=telurix-com.20150623.gappssmtp.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 aQkEXHjKa66a for <mmusic@ietfa.amsl.com>; Mon, 1 Feb 2021 19:39:16 -0800 (PST)
Received: from mail-io1-xd2f.google.com (mail-io1-xd2f.google.com [IPv6:2607:f8b0:4864:20::d2f]) (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 782403A16F4 for <mmusic@ietf.org>; Mon, 1 Feb 2021 19:38:48 -0800 (PST)
Received: by mail-io1-xd2f.google.com with SMTP id u20so5742292iot.9 for <mmusic@ietf.org>; Mon, 01 Feb 2021 19:38:48 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telurix-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=uH9ZUV7/LqGXcpAsOvftxGacX5pZRlooKqfZhvBQwmw=; b=yz7T1bkWhTUk+SkRRJQ7VVWA5aO9wcyZ5EI4idmChLXC7SZHL0bwOiX0ns+aqE/7EU Fs023usESYLQa7/B0omlt7Tc76Clh+XqMD4UL8ozamJ/L3cCIbxEVT+gXoy21tGuGoRQ uFO96+jsH6GDSsGR9ZNDyTdroNPafqNASGBtOKpm9tb7CKwSQZIf14UU2WXRQCa2CBF9 wXADCBmuFPo2S36e75zIRJp0TSd6jiY9jE92olnrrjq06EpvGHFyKyfM0jUaOWWOd4fp 160k7Cf1/Q/U6FlSQJ+tK3N84n+Ghx7lkuV64mtbqT775fUASlBovYkeHXPaZiR6sfxq L84A==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=uH9ZUV7/LqGXcpAsOvftxGacX5pZRlooKqfZhvBQwmw=; b=YG+LC3acX7OzbleRZnJygwecPtYf36be9axPX/rz2lRbX42WzUOIVs7r5z5wnII90X 7HpygwHRsJA+VkRoYvQCb4QFF2ky3xyu1o1IDEOH04vTYysAdGMxbitCIh7DVMDGU+kL B/0wWVhTZTVMegEgLl3Bh7cxcWSvAzIJn+qTRnUlsOrIKLZqzRp2hiBWQoBKN3z0JwfJ IxRe3BQRMbqbnlemwZe4jgcq4gki1RET27UUJ5MAe66/3/yqeIgFjwQ7iGyTRuTRsc18 QTWMl614gDbCipa+79TT4+S+a3YS5Co25EpCGhPFzlR/Vvg1EEUkuQxsizLsHoTL+/ug CYAQ==
X-Gm-Message-State: AOAM533AT7kMKNJIKn/QS8wbQgibEh6Ef5tHUq+rxLFhzbw4tb5H1Q3n IosplaHKpJxOFl8w4RFoz64UJ2ljqF8TKA==
X-Google-Smtp-Source: ABdhPJztHp4I3GTjDqm2t4diApEh+aKkC5pIoHoHip6wzgTMGoMsbhYe6I5OXAuehXQb5eHGA6Lpiw==
X-Received: by 2002:a02:2a83:: with SMTP id w125mr18165688jaw.48.1612237127329; Mon, 01 Feb 2021 19:38:47 -0800 (PST)
Received: from mail-io1-f43.google.com (mail-io1-f43.google.com. [209.85.166.43]) by smtp.gmail.com with ESMTPSA id s9sm10355982ilt.2.2021.02.01.19.38.46 for <mmusic@ietf.org> (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 01 Feb 2021 19:38:46 -0800 (PST)
Received: by mail-io1-f43.google.com with SMTP id s24so8282998iob.6 for <mmusic@ietf.org>; Mon, 01 Feb 2021 19:38:46 -0800 (PST)
X-Received: by 2002:a05:6638:d8a:: with SMTP id l10mr18093907jaj.2.1612237126087; Mon, 01 Feb 2021 19:38:46 -0800 (PST)
MIME-Version: 1.0
References: <AM0PR07MB3860A872DE7E09ED79FE4EAD93BA9@AM0PR07MB3860.eurprd07.prod.outlook.com> <AM0PR07MB38600ED79AA323A8C38098AB93B99@AM0PR07MB3860.eurprd07.prod.outlook.com> <CAD5OKxsLL=+DLu-D2y-rOFGMDpKXgsWhVDFLiWS1k68LhwU8Dg@mail.gmail.com> <AM0PR07MB3860D4EC744D231497EFA5F993B89@AM0PR07MB3860.eurprd07.prod.outlook.com> <CAOJ7v-0juBeH3g4MY6jSj+pRnk6+CBFt24p9jFQ+Fwd4qjp_nw@mail.gmail.com> <AM0PR07MB38600147C590A3D84054036D93B89@AM0PR07MB3860.eurprd07.prod.outlook.com> <CAOJ7v-2oL-YP=CGUkCZ8NuP5xPur0z+BK3qZZTdHCNxQZ16HqA@mail.gmail.com> <AM0PR07MB38609424137713FAA193CAE193B79@AM0PR07MB3860.eurprd07.prod.outlook.com> <CAD5OKxshWvy69fs5tgrME9CT6YV6eaqR3K5w8mOQEnm0CcyMpw@mail.gmail.com> <AM0PR07MB3860F88FFE187446FBDB786193B69@AM0PR07MB3860.eurprd07.prod.outlook.com> <49cd0938-1f48-8a00-69b0-8063b99282b3@alum.mit.edu> <AM0PR07MB3860F7CF9926F51856AD5FED93B69@AM0PR07MB3860.eurprd07.prod.outlook.com> <CAD5OKxv728xY42iv39wA1EW3XUw-LPRDKAG=6-Jr67mA=sBfhw@mail.gmail.com> <76e438f4-e8b3-f805-e213-d7b52d36481d@alum.mit.edu>
In-Reply-To: <76e438f4-e8b3-f805-e213-d7b52d36481d@alum.mit.edu>
From: Roman Shpount <roman@telurix.com>
Date: Mon, 1 Feb 2021 22:38:35 -0500
X-Gmail-Original-Message-ID: <CAD5OKxu_rmWOgMDdgp8rdvorkodBRyUi1aDgDx9+UQmARufL-g@mail.gmail.com>
Message-ID: <CAD5OKxu_rmWOgMDdgp8rdvorkodBRyUi1aDgDx9+UQmARufL-g@mail.gmail.com>
To: Paul Kyzivat <pkyzivat@alum.mit.edu>
Cc: Christer Holmberg <christer.holmberg=40ericsson.com@dmarc.ietf.org>, "mmusic@ietf.org" <mmusic@ietf.org>
Content-Type: multipart/alternative; boundary="00000000000031b95805ba5235bb"
Archived-At: <https://mailarchive.ietf.org/arch/msg/mmusic/K7pdgHQPnpk2tKuUYgmx8CqDT84>
Subject: Re: [MMUSIC] [rtcweb] Updating JSEP and BUNDLE: Semantics of same port in multiple m- lines
X-BeenThere: mmusic@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Multiparty Multimedia Session Control Working Group <mmusic.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/mmusic>, <mailto:mmusic-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/mmusic/>
List-Post: <mailto:mmusic@ietf.org>
List-Help: <mailto:mmusic-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/mmusic>, <mailto:mmusic-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 02 Feb 2021 03:39:19 -0000

On Mon, Feb 1, 2021 at 6:26 PM Paul Kyzivat <pkyzivat@alum.mit.edu> wrote:

> On 2/1/21 12:43 PM, Roman Shpount wrote:
> > On Mon, Feb 1, 2021 at 12:27 PM Christer Holmberg
> > <christer.holmberg=40ericsson.com@dmarc.ietf.org
> > <mailto:40ericsson.com@dmarc.ietf.org>> wrote:
> >
> >      >>>> Sure, we could have done that. However, as has been discussed
> >     that in the past (in MMUSIC, SIPCORE etc), we typically don't
> >     describe situations that can occur when endpoints behave strangely,
> >     because it would easily become a slippery slope.
> >      >>>> Also note that, in addition to bundle-only there can also be
> >     other attributes that have been copy/pasted by the remote endpoint.
> >      >>>
> >      >>> This is not "endpoints behaving strangely". This is the
> >     expected behavior of an endpoint that does not support bundle.
> >      >>
> >      >> I don't think copy/pasting attributes you don't understand is
> >     expected behavior. That in general can cause lots of problems.
> >      >>
> >      >> But, I do buy the argument that some endpoints do that, and that
> >     it is not (as far as I remember) explicitly forbidden.
> >      >
> >      > Shooting yourself in the head isn't AFAIK explicitly forbidden.
> >     But unless you understand and desire the consequences it is
> >     generally an unwise thing to do.
> >      >
> >      > I don't think an IETF document is obligated to protect against
> >     people doing either.
> >      >
> >      > Also, if we have an implementation that doesn't support bundle
> >     that is copying an a=bundle-only it doesn't understand, won't it
> >     also likely be copying a=group:bundle and a=mid???
> >
> >     My understanding was that it only affected media-level attributes.
> >
> >     But, sure, in theory an endpoint could copy ANYTHING it doesn't
> >     understand...
> >
> >
> > The issue is how does an endpoint generate an m= line to refuse
> > something that the endpoint does not understand. For instance, the
> > endpoint gets an application webrtc-datachannel m= line but has no idea
> > what any of the SDP attributes mean and which ones are required to form
> > a valid m= line. The simplest way is to refuse such an m= line was to
> > copy the entire m= line in the answer and set the m= line port to 0. As
> > far as the endpoint is concerned, there is no difference between
> > a=sctp-port or a=bundle-only, if neither are supported.
> >
> > If this is an invalid procedure to refuse an m= line, please point out
> > where it says this is invalid and let me know where the correct
> > procedure is described.
>
> I will grant you that the guidance on what do do in this situation is
> lacking.
>
> BUT, it cannot be assumed that attributes are symmetric in their use in
> offers and answers. While that is true of some, it is definitely not
> true of others. So it is unreasonable to assume you should copy
> un-understood attributes from offer to answer. The only thing it is
> reasonably safe to do is what Christer says.
>

What does Christer say, exactly? Copy just an m= line from the offer and
set the port to zero, or copy the entire m= section with attributes from
the offer and set the port to zero?

RFC 3264 Section 6 Says:
An offered stream MAY be rejected in the answer for any reason.  If a
stream is rejected, the offerer and answerer MUST NOT generate media (or
RTCP packets) for that stream.  To reject an offered stream, the port
number in the corresponding stream in the answer MUST be set to zero.  Any
media formats listed are ignored.  At least one MUST be present, as
specified by SDP.

So, it implies that an m= line must be valid and include at least one media
format. What if all the payloads are dynamic? Should it include the
corresponding a=rtpmap attribute? What if this payload format requires
other attributes to be valid? What if the m= line refers to an application
type stream and the receiving endpoint does not support it and does not
know how to generate the valid m= line or section in response. What should
be done then? What if this is an m= line with an unknown proto? In this
case, media formats are just a list of unspecified tokens.

> Session level attributes are different since this is something that is
> > negotiated, it would be logical not to include them if the endpoint does
> > not support them.
>
> I don't see it as much different. In both cases, your answer should only
> contain stuff you understand and support. The only exception is for
> m-lines themselves, where you can copy the rejected m-line except for
> replacing the port with zero.
>

As I have mentioned earlier, an m= line might not be valid without the
corresponding attributes. Since these attributes per RFC 3264 MUST be
ignored if the m= line port is zero, they were often included. BUNDLE RFC
changes this, so it should specify what happens in this case, which used to
be legal before.

Perhaps we should have instead specified a placeholder <media>, <proto>,
> and <fmt> to use in rejected m-lines. But that is water over the dam.
>

We should have just specified that none of the fmt or attributes MUST be
included, but this is, indeed, water under the dam.

Best Regards,
_____________
Roman Shpount