[Wish] Issue: WISH and TURN servers

Adam Roach <adam@nostrum.com> Fri, 30 July 2021 23:11 UTC

Return-Path: <adam@nostrum.com>
X-Original-To: wish@ietfa.amsl.com
Delivered-To: wish@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id AAADF3A0B9C for <wish@ietfa.amsl.com>; Fri, 30 Jul 2021 16:11:01 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.079
X-Spam-Level:
X-Spam-Status: No, score=-2.079 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, T_SPF_HELO_PERMERROR=0.01, T_SPF_PERMERROR=0.01, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=nostrum.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 QwbfvW38jbTr for <wish@ietfa.amsl.com>; Fri, 30 Jul 2021 16:10:56 -0700 (PDT)
Received: from nostrum.com (raven-v6.nostrum.com [IPv6:2001:470:d:1130::1]) (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 BA3353A1573 for <wish@ietf.org>; Fri, 30 Jul 2021 16:10:54 -0700 (PDT)
Received: from Zephyrus.local (76-218-40-253.lightspeed.dllstx.sbcglobal.net [76.218.40.253]) (authenticated bits=0) by nostrum.com (8.16.1/8.16.1) with ESMTPSA id 16UNAqkT033743 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NO) for <wish@ietf.org>; Fri, 30 Jul 2021 18:10:53 -0500 (CDT) (envelope-from adam@nostrum.com)
DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=nostrum.com; s=default; t=1627686653; bh=GX3lMbnsJ/FkIvKUxGE0xXV0g5RBjuxwtfPbDaky810=; h=To:From:Subject:Date; b=fecYvKvIVO5hsEvtlGWNNCzwS2vc5ChOucTAQmlxRdl+P201r97qEKxQcZFXkACBi 4Su6Z+jgbgOZv0jlDb6pSRDasdKM4fxSyj+r5mCNpBwPaDnnPSvIZnt4Fvpv+cwuu3 nhPV6udXXiHYRGP4X/9WdQwrNF3yLYvEOWXK5yfc=
X-Authentication-Warning: raven.nostrum.com: Host 76-218-40-253.lightspeed.dllstx.sbcglobal.net [76.218.40.253] claimed to be Zephyrus.local
To: "wish@ietf.org" <wish@ietf.org>
From: Adam Roach <adam@nostrum.com>
Message-ID: <a6a9e516-2a73-27b4-a0e5-201c8c2687c5@nostrum.com>
Date: Fri, 30 Jul 2021 18:10:47 -0500
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:68.0) Gecko/20100101 Thunderbird/68.11.0
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding: 7bit
Content-Language: en-US
Archived-At: <https://mailarchive.ietf.org/arch/msg/wish/_tWh9P1-UhdyHklp5jS8Ys8pS14>
Subject: [Wish] Issue: WISH and TURN servers
X-BeenThere: wish@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: WebRTC Ingest Signaling over HTTPS <wish.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/wish>, <mailto:wish-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/wish/>
List-Post: <mailto:wish@ietf.org>
List-Help: <mailto:wish-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/wish>, <mailto:wish-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 30 Jul 2021 23:11:02 -0000

During today's meeting, there were a couple of topics relating to TURN 
server provisioning that came up.


The first issue was which mechanism we should use for conveying TURN 
server addresses & credentials. One proposal was to re-use the mechanism 
described in draft-uberti-behave-turn-rest. Justin made it clear that, 
with the publication of RFC 7635, he was no longer interested in 
progressing that mechanism as an independent document; however, it was 
proposed that we could instead roll the mechanism into WHIP itself.

In practice, the mechanism described in that document is quite simple at 
its core: clients sent a GET to an HTTP server, and receive a JSON 
object containing TURN URIs, a username, a password, and an expiration 
time. It also talks about query parameters for this request, but my 
initial analysis is that they may be useful for general-purpose use, but 
aren't really applicable to WHIP's use.

Adding text to the base WHIP document that documents a simplified form 
of this mechanism would be a straightforward exercise, and I'd be happy 
to put together the necessary text.


The second issue was discovery (bootstrapping) of the aforementioned 
mechanism. Today's discussion had two proposals for how this might be 
performed:

 1. Add a ".well-known" URL to the WHIP server that can be used to
    retrieve credentials
 2. Define behavior for OPTIONS (or possibly HEAD?) on the WHIP endpoint
    such that the response contains a "Location" header field with a
    link that the client uses to retrieve the information.

Option 1 has the benefit of using one fewer round trips prior to 
starting a broadcast (GET to the ".well-known" endpoint, and then POST 
to the WHIP endpoint, versus OPTIONS to the WHIP endpoint, then GET to 
the TURN endpoint, then POST to the WHIP endpoint).

Option 2 is architecturally cleaner and keeps all of the WHIP behavior 
nicely contained.

It should be noted that clients that don't wish to use TURN won't have 
to perform the additional operations, and can still start a session in a 
single HTTP operation, so the extra RTT only applies to those clients 
that wish to use TURN.


There was also a short discussion of sending the TURN Location header 
field back in the response to the offer PUT. I missed the exact nature 
of the objection for doing so, although it seemed to be based on 
information that we needed to have available to create the offer. I'm 
trying to work out whether this is true: I /think/ all of the 
information relating to the TURN server can be sent in a trickle ICE 
candidate. So you'd have something that looks like this:


Unless I've overlooked something that makes this infeasible, I think I 
like this approach the best, since it allows ICE checks to start on 
non-relayed candidates with the same amount of latency as without this 
mechanism.

/a