Re: [rtcweb] Strawman for how to prevent voice-hammer without ICE

Matthew Kaufman <matthew.kaufman@skype.net> Thu, 28 July 2011 11:38 UTC

Return-Path: <matthew.kaufman@skype.net>
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 AF66521F8BD6 for <rtcweb@ietfa.amsl.com>; Thu, 28 Jul 2011 04:38:18 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.449
X-Spam-Level:
X-Spam-Status: No, score=-2.449 tagged_above=-999 required=5 tests=[AWL=0.150, BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.30]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id dKE80ZVc22F1 for <rtcweb@ietfa.amsl.com>; Thu, 28 Jul 2011 04:38:17 -0700 (PDT)
Received: from mx.skype.net (mx.skype.net [78.141.177.88]) by ietfa.amsl.com (Postfix) with ESMTP id 8FF7F21F88A6 for <rtcweb@ietf.org>; Thu, 28 Jul 2011 04:38:17 -0700 (PDT)
Received: from mx.skype.net (localhost [127.0.0.1]) by mx.skype.net (Postfix) with ESMTP id B3E2016E2; Thu, 28 Jul 2011 13:38:13 +0200 (CEST)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=skype.net; h=subject :mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; s=mx; bh=Qr 1U7uMY2q2HFlg9hvUKRXSPg2w=; b=OyMA0Gbsp8e5FnU6wfpkh/if456kim2uIx dw8ohVTB9BcCjX5ccbjthIBv2k4nxM5Ez06yOtQrbgGADKogSUtDe4sKIA13pPox Ve/ZUfIVzuiXQq0AaGj6aULYFZzEkHvicHaK33LDEZHNjVyF5KQCuBJ108ZAEXbd zW2+Ougts=
DomainKey-Signature: a=rsa-sha1; c=nofws; d=skype.net; h=subject:mime-version :content-type:from:in-reply-to:date:cc:content-transfer-encoding :message-id:references:to; q=dns; s=mx; b=Tyb8/XAyfURLp5DD92sNJR H/8TliMFA+qZczT2kvyq3E7aArtXQ1SYMH7ccqlLwwyZT+EsdFrhajf44D0dC93V mo2Y+ey1gXE4xTEbceRIAhx5yloH/YrN0OyjAAdKuuB1DZiWt9d23tqKZcYxDI6Y 3gLfElSNjJm4AU4GX+bkE=
Received: from zimbra.skype.net (zimbra.skype.net [78.141.177.82]) by mx.skype.net (Postfix) with ESMTP id B23427F8; Thu, 28 Jul 2011 13:38:13 +0200 (CEST)
Received: from localhost (localhost [127.0.0.1]) by zimbra.skype.net (Postfix) with ESMTP id 997253507E77; Thu, 28 Jul 2011 13:38:13 +0200 (CEST)
X-Virus-Scanned: amavisd-new at lu2-zimbra.skype.net
Received: from zimbra.skype.net ([127.0.0.1]) by localhost (zimbra.skype.net [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id GU0K20H82gN8; Thu, 28 Jul 2011 13:38:12 +0200 (CEST)
Received: from dhcp-4649.meeting.ietf.org (dhcp-4649.meeting.ietf.org [130.129.70.73]) by zimbra.skype.net (Postfix) with ESMTPSA id 333EB3507E39; Thu, 28 Jul 2011 13:38:12 +0200 (CEST)
Mime-Version: 1.0 (Apple Message framework v1082)
Content-Type: text/plain; charset="us-ascii"
From: Matthew Kaufman <matthew.kaufman@skype.net>
In-Reply-To: <B6527F21-4DE2-46B1-AE2E-891D56461313@acmepacket.com>
Date: Thu, 28 Jul 2011 07:38:10 -0400
Content-Transfer-Encoding: quoted-printable
Message-Id: <8D6E4E5F-E1E4-47FB-8D8D-F3D9976AC29E@skype.net>
References: <B6527F21-4DE2-46B1-AE2E-891D56461313@acmepacket.com>
To: Hadriel Kaplan <HKaplan@acmepacket.com>
X-Mailer: Apple Mail (2.1082)
Cc: "rtcweb@ietf.org" <rtcweb@ietf.org>
Subject: Re: [rtcweb] Strawman for how to prevent voice-hammer without ICE
X-BeenThere: rtcweb@ietf.org
X-Mailman-Version: 2.1.12
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: <http://www.ietf.org/mail-archive/web/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: Thu, 28 Jul 2011 11:38:18 -0000

On Jul 28, 2011, at 3:52 AM, Hadriel Kaplan wrote:

> Howdy,
> With regard to mandating ICE, such that an RTCWEB browser cannot send RTP without doing ICE successfully first... is that restriction purely to prevent the voice-hammer attacks?  If so, then it's unfortunate because obviously it would seriously reduce interop with non-RTCWEB VoIP devices.

Agree that it limits interoperability.

>  But I think there's a way to prevent the hammer attack without using ICE, and without requiring legacy VoIP devices to change whatsoever.
> 
> One way would be to use the receipt of RTP as an indicator the far-end expects to receive it from you.  So have the browser generate RTP/RTCP packets, at a relatively slow rate, for a short duration (e.g., use the same rate/retransmit timers of STUN connectivity checks in ICE).  If the browser receives RTP/RTCP packets, then the far-end expected to receive them as well and the browser can do normal RTP from then on.

This is not as safe. There are devices/software that do things upon receipt of RTP packets (like play them out through loudspeakers, or initiate ringing of the softphone), and more important RTP packets are not carefully designed to avoid imitating other types of traffic such as SNMP, whereas STUN packets contain a relatively large header with a magic number that makes them much less likely to be misinterpreted by other protocols.

Additionally the STUN connectivity check used for ICE contains short-term credentials and a transaction ID that is unknown to the signaling layer (or Javascript) that ensure that you are in fact conducting a pairwise negotiation with the far end that you are thinking of. With RTP/RTCP packets alone you can create attacks both from the browser (by sending RTP/RTCP and using something else to spoof enough replies that the test passes) or on the browser (by sending it RTP from somewhere else).

And of course ICE, or something like it, is required anyway for doing NAT traversal.


> 
> If this was a hammer attack, this doesn't generate any more load on the target than ICE, since ICE would have sent X number of STUN packets for Y time as well, and I'm suggesting the X and Y be the same values for the initial RTP packets during the "check" phase.

Problem is that it isn't just load. Another class of attack is sending packets to things like SNMP servers behind a firewall. No matter how slow the rate, if one of the packets causes bad things to happen then you have a security problem.

> 
> The major weakness of this approach is that a malicious web-server trying to get your browser to do the voice hammer could send RTP to your browser, since it knows the address/ports of both sides, codec payload types, etc. (i.e., it can spoof being the attack target to make your browser think it's ok to do normal RTP)

Indeed. See above.

>  But we could probably play games with RTCP SR/RR or even just require continued RTP receipt to send RTP, in order to mitigate this weakness or make it of low value to exploit.

I don't believe this is the case. There's so many cases where one side sends A+V but the other side sends audio only, and sending HD-video-rate traffic to an unsuspecting endpoint is unacceptable.

This is even worse if we allow arbitrary datagrams with a relatively short header, as these will be even easier to craft into attacks on other protocols if there isn't confirmed consent.

> 
> Does anyone else care about interop-ing with legacy non-RTCWEB voip devices?  I checked draft-ietf-rtcweb-use-cases-and-requirements-01 and I don't see it, so I'm not sure.

I care, but I think that the legacy devices are going to need a way to consent. At one of our first meetings prior to forming the WG I came up with additional terminology to describe devices which are legacy and cannot be upgraded vs. devices which are legacy but which can be upgraded sufficiently to add the ICE handshake... we should probably bring that back for convenience.

Matthew Kaufman