Re: [rtcweb] [MMUSIC] Default proto transport in JSEP

Roman Shpount <> Mon, 19 November 2018 19:31 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id BF4051292F1 for <>; Mon, 19 Nov 2018 11:31:02 -0800 (PST)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -1.88
X-Spam-Status: No, score=-1.88 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIMWL_WL_MED=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, T_KAM_HTML_FONT_INVALID=0.01, T_SPF_PERMERROR=0.01] autolearn=unavailable autolearn_force=no
Authentication-Results: (amavisd-new); dkim=pass (2048-bit key)
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id ChMaammINEz7 for <>; Mon, 19 Nov 2018 11:31:00 -0800 (PST)
Received: from ( [IPv6:2607:f8b0:4864:20::632]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by (Postfix) with ESMTPS id 3F08D130DED for <>; Mon, 19 Nov 2018 11:30:59 -0800 (PST)
Received: by with SMTP id a14so10445313plm.12 for <>; Mon, 19 Nov 2018 11:30:59 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=pLdIaVyIJHM79C49feJxjYKe6UnBUKcZOx2JZFif84Y=; b=DjSm4nRXEfEBf6/tK4UABoI2osCPhWc7XJkcHpcIKh44QwRww+MjG8uHjwA14U7KeB 90ErHlMKEaKJavgG4Lydh3PjkC8ON69D3fANrPpeMc+HUimJAtn0xVwtUuBh7g84x1V5 PLOrv9ChC4BWGTqs17Ldahlyi99lq6S88h9XNGbTm0YkYlv25QPiYWssYL5uvV5IkCtr tep/p3F1efou8xAIiUlabEBnt3hcOwJf3DqaxttKeEGr93ksnz3O2VtvgtHAm5fuxfRe PC63I4eKBbeFFTtvjfDtRzZucgsY0cKp94aAPmongFAgTQuA1zqYepeUS7X3U6id1DKS GlMQ==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=pLdIaVyIJHM79C49feJxjYKe6UnBUKcZOx2JZFif84Y=; b=KEl1nLQVWLOkWPCxtyyKVDLUNM1e2pfLmA4hXtftmCWvihFmxJIYFXOVVBM/sspDJq iXABCljwmI/+zib1NWc0EQFk2ABIqH8rtt8+YtQOZn4cu0txMy6lUzhqSa0PP8/EmCVT psLQkUS0B3fJlw/UxX2EG7AEJu4b+znaQvqTYzwg2jfbQEO8RKa4yDuv7nPR2XwpgY/0 AljbZkJfnvHNngVVIamSCexG/xrY479Ve9tYTT4NVNApRoN68HEeqplPWWracrdEy82q OpEo+WNLlM/iZ5CBzxL4ObDonOwqY7sPlTToE0lbv4q2zJEhmnZKhoTOZzofBbpUAsUz JXuQ==
X-Gm-Message-State: AGRZ1gL7k/UbhYut1brRaIVI1W1ZAz3UHoln1X2TcBLIRDFo5YeHI1xj L11z0aq1o3mqqh4upUs004x2El5yt98=
X-Google-Smtp-Source: AJdET5eOGbmMVFF1dJB9npxmjz5lnj8NjbqMS8xbphoh8ghWA/sDXtj5swqKq2DMkQH+KzSuuHHU4w==
X-Received: by 2002:a17:902:868b:: with SMTP id g11-v6mr20696429plo.96.1542655858579; Mon, 19 Nov 2018 11:30:58 -0800 (PST)
Received: from ( []) by with ESMTPSA id b2sm55729977pfm.3.2018. (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 19 Nov 2018 11:30:57 -0800 (PST)
Received: by with SMTP id 64so10849325pfr.9; Mon, 19 Nov 2018 11:30:57 -0800 (PST)
X-Received: by 2002:a62:1b50:: with SMTP id b77mr24339172pfb.36.1542655857615; Mon, 19 Nov 2018 11:30:57 -0800 (PST)
MIME-Version: 1.0
References: <> <> <>
In-Reply-To: <>
From: Roman Shpount <>
Date: Mon, 19 Nov 2018 14:30:52 -0500
X-Gmail-Original-Message-ID: <>
Message-ID: <>
To: Justin Uberti <>
Cc: RTCWeb IETF <>, mmusic WG <>
Content-Type: multipart/alternative; boundary="000000000000676ab2057b098ec5"
Archived-At: <>
Subject: Re: [rtcweb] [MMUSIC] Default proto transport in JSEP
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Real-Time Communication in WEB-browsers working group list <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Mon, 19 Nov 2018 19:31:03 -0000

On Mon, Nov 19, 2018 at 1:35 PM Justin Uberti <> wrote:

> IIRC, one reason JSEP chose the behavior described is because
> 5245-compliant implementations would declare an ICE mismatch if we used a
> bogus address/port in the c=/m= lines. Is this not a problem?

RFC 5245 compatibility is a problem, but I assume we were past this point
and was trying to propose something that at least is going to be compatible
with ice-sip-sdp. BTW, Edge browser with RTCPeerConnection-shim is already
putting and port 9 in all session descriptions:

v=0 o=thisisadapterortc 3331475186201587 0 IN IP4 s=- t=0 0
a=group:BUNDLE mzxjdusv69 a=ice-options:trickle m=audio 9 UDP/TLS/RTP/SAVPF
104 102 0 8 103 97 13 118 101 c=IN IP4 a=rtcp:9 IN IP4
(codec parameters removed for clarity)
a=maxptime:100 a=rtcp-mux a=extmap:1
a=ice-ufrag:x+3s a=ice-pwd:Re8NpJqQfXVtpbOg7oBgmoHL a=setup:actpass
a=mid:mzxjdusv69 a=sendrecv a=msid:6E374666-5BBB-43E9-B1C2-89312C920723
BD9F838A-5483-42E5-99A7-A861999D5C0A a=ssrc:1001
BD9F838A-5483-42E5-99A7-A861999D5C0A a=ssrc:1001 cname:m4gynh3dc1
a=rtcp-rsize a=candidate:1 1 UDP 2130706431 63862 typ host
ufrag x+3s a=candidate:2 1 UDP 2130705919 55458 typ host ufrag
x+3s a=candidate:3 1 TCP 1684798463 63862 typ srflx raddr rport 63862 tcptype active ufrag x+3s a=end-of-candidates

If RFC 5245 compatibility is required, it means offer/answer exchange with
no trickle, session refresh after nomination completion, and using default
candidate protocol, address and port in c= and m= line. No trickle and
session refresh can be achieved through existing API. Setting protocol,
address, and port in c= and m= line is harder and will require SDP mangling.

When ICE-SIP-SDP and related protocols were discussed in mmusic, in order
to be RFC 5245 compatible, the plan was to:
1. Use protocol, address, and port of the default candidate in c= and m=
2. In order to avoid protocol mismatch during offer/answer, require in
specific protocol specifications, such as sctp-sdp, that end points should
implement UDP based transport and use it as default transport during ICE
restart in both offer and answer
3. In subsequent offers, where only a single candidate is present, use
protocol, address and port of this candidate in c= and m= lines

This means the same protocol should always be used for the specific m= line
during offer/answer, but it can change between offer/answer exchanges. For
instance, m= line which was UDP/DTLS/SCTP during the initial exchange, can
become TCP/DTLS/SCTP in subsequent exchange, and then change back to
UDP/DTLS/SCTP when ICE restart is initiated. It was assumed that it should
not be a problem but JSEP is currently trying to overwrite this. I
understand this is ugly, but this was the only thing we came up with to
keep things compatible with existing implementations.

Roman Shpount