[rtcweb] JSEP: codecs in answer: MUST vs. MAY

Jonathan Lennox <jonathan@vidyo.com> Tue, 24 October 2017 19:58 UTC

Return-Path: <jonathan@vidyo.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 5499413F826 for <rtcweb@ietfa.amsl.com>; Tue, 24 Oct 2017 12:58:59 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.099
X-Spam-Level:
X-Spam-Status: No, score=-1.099 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_SORBS_WEB=1.5, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=no autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=vidyo-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 v3e50HFjUlAA for <rtcweb@ietfa.amsl.com>; Tue, 24 Oct 2017 12:58:58 -0700 (PDT)
Received: from mail-qk0-x22b.google.com (mail-qk0-x22b.google.com [IPv6:2607:f8b0:400d:c09::22b]) (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 E8624139602 for <rtcweb@ietf.org>; Tue, 24 Oct 2017 12:58:57 -0700 (PDT)
Received: by mail-qk0-x22b.google.com with SMTP id m189so27804283qke.4 for <rtcweb@ietf.org>; Tue, 24 Oct 2017 12:58:57 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vidyo-com.20150623.gappssmtp.com; s=20150623; h=from:mime-version:subject:message-id:date:to; bh=g6EBVZrFyXa98aGLOb3uN+8D/w5Dflfc1+dpQA9mvUI=; b=nYGhiNinyN+lRI+EblP+f7aSVM3s4QG8UpBss4pN1ihn+wkpweaFyh7niI2LfQirdP PNI9asM9XPOpotvcow4+LdDSItCw+l8yfUsll7e4AeL2cpKCnc5+cS+Q8haydhoWyono 5mvw0np1XGpOZPHLD4R73OBTGiDSYBDQtoS3E7scWEClkFksa33CtD/oBAhtHLfj/sE1 oPPkZAAC/Gp6+RFgnm7TU9/T7ZeawHVOiSdU5M2gvzyKwW0TyhqRNXV/JQCWaIRnSxTO wAf2S/bur2blbdxW00YK0aWEKCYMZKkiVcTS7uy4j6/UKE7UcDvnOc+fURnhzzxM8CJH XISQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:mime-version:subject:message-id:date:to; bh=g6EBVZrFyXa98aGLOb3uN+8D/w5Dflfc1+dpQA9mvUI=; b=BV4mLNG04heOJsE0RDaV2uoTXQlzq60RCdKs+1IKaEop/z0Da25fWhzoV8VptWp9Y1 jrv05MwLZHjERqHdQDLl/gXsI4lX5zM5a5yHzWX/u7uJeyjTZObJL9fvpgk+021xL8Eh rgmDRv2Fonn2282TAeamJGvAu6YsuZtAr5fzy0kaIQbUbzrRUfJexk8grbuuk7sS5EPw M+lzmpwYRADpddEmaTaJ4lAPKOy43pHy6M5MsNMPQ7wyhZ8GHKELUYZEQhBAfTsWF81v eeLMjn4HtFPEfdKRT8uK6wGSLaEGmNpKjJPFSs3YTkYGnpY9aif5fGfHHBxsWMyIV8b1 4LhQ==
X-Gm-Message-State: AMCzsaVEwZDMEz5zTpbIrY8+XKlD/pa6LYiBwS5Fr+pXrnyksnawLyNR ouHAtc7VlYTw/hRBmCsm8lk6iPQIpaw=
X-Google-Smtp-Source: ABhQp+R2N8/P++tpTwgHHAKJ23r3q3wLDnDJ23VtkBghBeVVILmUwqfOC5jTjuTTfgOgodWBjr4//A==
X-Received: by 10.55.170.74 with SMTP id t71mr25653170qke.84.1508875136864; Tue, 24 Oct 2017 12:58:56 -0700 (PDT)
Received: from [172.16.2.142] ([160.79.219.114]) by smtp.gmail.com with ESMTPSA id g11sm699992qkb.58.2017.10.24.12.58.55 for <rtcweb@ietf.org> (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 24 Oct 2017 12:58:56 -0700 (PDT)
From: Jonathan Lennox <jonathan@vidyo.com>
Content-Type: multipart/alternative; boundary="Apple-Mail=_3AD33538-CB84-4C5C-8156-983C1B79ED32"
Mime-Version: 1.0 (Mac OS X Mail 10.3 \(3273\))
Message-Id: <4CB5EF91-8CB2-433F-85E9-A86140CECC62@vidyo.com>
Date: Tue, 24 Oct 2017 15:58:55 -0400
To: "rtcweb@ietf.org" <rtcweb@ietf.org>
X-Mailer: Apple Mail (2.3273)
Archived-At: <https://mailarchive.ietf.org/arch/msg/rtcweb/3Xbssaelb79BBiiKP9-AA8Zwgvc>
Subject: [rtcweb] JSEP: codecs in answer: MUST vs. MAY
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, 24 Oct 2017 19:58:59 -0000

JSEP (section 5.3.1) seems to be inconsistent about how whether locally-supported codecs that weren’t listed in a remote offer MUST, or MAY, be included in an answer:

   o  If codec preferences have been set for the associated transceiver,
      media formats MUST be generated in the corresponding order,
      regardless of what was offered, and MUST exclude any codecs not
      present in the codec preferences.

   o  Otherwise, the media formats on the m= line MUST be generated in
      the same order as those offered in the current remote description,
      excluding any currently unsupported formats.  Any currently
      available media formats that are not present in the current remote
      description MUST be added after all existing formats.

   o  In either case, the media formats in the answer MUST include at
      least one format that is present in the offer, but MAY include
      formats that are locally supported but not present in the offer,
      as mentioned in [RFC3264], Section 6.1 <https://tools.ietf.org/html/rfc3264#section-6.1>.  If no common format
      exists, the m= section is rejected as described above.

The first two paragraphs certainly seem to indicate that these codecs MUST be included in the answer; however, the third paragraph suddenly weakens this to a MAY.

Is the intent of the third paragraph simply to restate RFC 3264’s loose requirements, whereas the first two are JSEP’s more binding ones?  If so, I think this should be stated more clearly, otherwise the required behavior is unclear.