Subject: [hybi] [Technical Errata Reported] RFC6455 (3215)

From: RFC Errata System <[email-masked]>
Date: Sun, 6 May 2012 17:30:08 -0700 (PDT)

The following errata report has been submitted for RFC6455,
"The WebSocket Protocol".

--------------------------------------
You may review the report below and at:
http://www.rfc-editor.org/errata_search.php?rfc=6455&eid=3215

--------------------------------------
Type: Technical
Reported by: Jesse Katzman <[email-masked]>

Section: 5.3

Original Text
-------------
The unpredictability of the masking key is essential to prevent authors of malicious applications from selecting the bytes that appear on the wire.

Corrected Text
--------------

Notes
-----
I don't see how the client-to-server masking prevents "authors of malicious applications from selecting the bytes that appear on the wire".

Maliciously changing the contents of a message simply requires a few more steps than it would without masking, as far as I can tell.

I'm quite new at networking, so perhaps I'm missing something.  Thank you.

Instructions:
-------------
This errata is currently posted as "Reported". If necessary, please
use "Reply All" to discuss whether it should be verified or
rejected. When a decision is reached, the verifying party (IESG)
can log in to change the status and edit the report, if necessary. 

--------------------------------------
RFC6455 (draft-ietf-hybi-thewebsocketprotocol-17)
--------------------------------------
Title               : The WebSocket Protocol
Publication Date    : December 2011
Author(s)           : I. Fette, A. Melnikov
Category            : PROPOSED STANDARD
Source              : BiDirectional or Server-Initiated HTTP
Area                : Applications
Stream              : IETF
Verifying Party     : IESG

---

From: Peter Saint-Andre <[email-masked]>
Date: Sun, 06 May 2012 18:58:27 -0600

IMHO this is not really a valid erratum, although it's a worthy topic
for discussion if and when this working group (or a successor working
group) decides to work on a document that might supersede RFC 6455.

On 5/6/12 6:30 PM, RFC Errata System wrote:
> _______________________________________________
> hybi mailing list
> [email-masked]
> https://www.ietf.org/mailman/listinfo/hybi

---

From: Barry Leiba <[email-masked]>
Date: Sun, 6 May 2012 21:03:13 -0400

> group) decides to work on a document that might supersede RFC 6455.

Absolutely -- not appropriate for the errata system.  I'm going to
reject this erratum, and suggest that the submitter participate in the
HyBi working group instead.

Barry, responsible AD

---

From: Jesse Katzman <[email-masked]>
Date: Sun, 6 May 2012 21:05:43 -0400

Okay, thank you.  Will do.

2012/5/6 Barry Leiba <[email-masked]>

> >> The unpredictability of the masking key is essential to prevent authors
> of malicious applications from selecting the bytes that appear on the wire.
> >>
> >> Corrected Text
> >> --------------
> >>
> >>
> >> Notes
> >> -----
> >> I don't see how the client-to-server masking prevents "authors of
> malicious applications from selecting the bytes that appear on the wire".
> >>
> >> Maliciously changing the contents of a message simply requires a few
> more steps than it would without masking, as far as I can tell.
> >>

---

From: John Tamplin <[email-masked]>
Date: Sun, 6 May 2012 23:00:42 -0400

On Sun, May 6, 2012 at 8:30 PM, RFC Errata System <[email-masked]
> wrote:

> The unpredictability of the masking key is essential to prevent authors of
> malicious applications from selecting the bytes that appear on the wire.
>
> Corrected Text
> --------------
>
>
> Notes
> -----
> Maliciously changing the contents of a message simply requires a few more
> steps than it would without masking, as far as I can tell.
>

Masking the client->server frames was heavily debated on this list for
months -- I encourage you read the archives rather than rehashing the
debate.

Basically, WebSockets is unique in that you need to protect the network
infrastructure, even if you have hostile code running in the client, full
hostile control of the server, and the only piece you can trust is the
client browser.  By having the browser generate a random mask for each
frame, the hostile client code cannot choose the byte patterns that appear
on the wire and use that to attack vulnerable network infrastructure.

-- 
John A. Tamplin
Software Engineer (GWT), Google

---

From: Jesse Katzman <[email-masked]>
Date: Tue, 8 May 2012 01:00:27 -0400

Hi John,

Thank you for the explanation.  I didn't realize it meant an in-browser
application.  I understand now.

Thanks again,
Jesse
On May 6, 2012 11:01 PM, "John Tamplin" <[email-masked]> wrote:

> On Sun, May 6, 2012 at 8:30 PM, RFC Errata System <
> [email-masked]> wrote:
>
>> Type: Technical