Re: [HASMAT] Parsing Content-Type

Julian Reschke <julian.reschke@gmx.de> Tue, 13 July 2010 16:26 UTC

Return-Path: <julian.reschke@gmx.de>
X-Original-To: hasmat@core3.amsl.com
Delivered-To: hasmat@core3.amsl.com
Received: from localhost (localhost [127.0.0.1]) by core3.amsl.com (Postfix) with ESMTP id E00733A6927 for <hasmat@core3.amsl.com>; Tue, 13 Jul 2010 09:26:13 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -4.599
X-Spam-Level:
X-Spam-Status: No, score=-4.599 tagged_above=-999 required=5 tests=[AWL=-2.000, BAYES_00=-2.599]
Received: from mail.ietf.org ([64.170.98.32]) by localhost (core3.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id xj65hDbxmRuC for <hasmat@core3.amsl.com>; Tue, 13 Jul 2010 09:26:13 -0700 (PDT)
Received: from mail.gmx.net (mailout-de.gmx.net [213.165.64.23]) by core3.amsl.com (Postfix) with SMTP id BB50E3A6870 for <hasmat@ietf.org>; Tue, 13 Jul 2010 09:26:12 -0700 (PDT)
Received: (qmail invoked by alias); 13 Jul 2010 16:26:19 -0000
Received: from p508FE44B.dip.t-dialin.net (EHLO [192.168.178.33]) [80.143.228.75] by mail.gmx.net (mp013) with SMTP; 13 Jul 2010 18:26:19 +0200
X-Authenticated: #1915285
X-Provags-ID: V01U2FsdGVkX1/J/LZAxiPJpGclVj30LwMdDFmjDzAq8dzc5L3B8W 8D//TgztKI1hct
Message-ID: <4C3C93A5.30903@gmx.de>
Date: Tue, 13 Jul 2010 18:26:13 +0200
From: Julian Reschke <julian.reschke@gmx.de>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.1.10) Gecko/20100512 Lightning/1.0b1 Thunderbird/3.0.5
MIME-Version: 1.0
To: Adam Barth <ietf@adambarth.com>
References: <op.vfr1o4on64w2qv@annevk-t60> <4C3C4831.5000007@gmx.de> <AANLkTilTSZHIdCxQ8Ip_c7aRHNYYQSghsRaPYFY9_VNM@mail.gmail.com>
In-Reply-To: <AANLkTilTSZHIdCxQ8Ip_c7aRHNYYQSghsRaPYFY9_VNM@mail.gmail.com>
Content-Type: text/plain; charset="ISO-8859-1"; format="flowed"
Content-Transfer-Encoding: 7bit
X-Y-GMX-Trusted: 0
Cc: hasmat@ietf.org
Subject: Re: [HASMAT] Parsing Content-Type
X-BeenThere: hasmat@ietf.org
X-Mailman-Version: 2.1.9
Precedence: list
List-Id: HTTP Application Security Minus Authentication and Transport <hasmat.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/listinfo/hasmat>, <mailto:hasmat-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/hasmat>
List-Post: <mailto:hasmat@ietf.org>
List-Help: <mailto:hasmat-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/hasmat>, <mailto:hasmat-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 13 Jul 2010 16:26:14 -0000

On 13.07.2010 18:10, Adam Barth wrote:
> ...
>> Speaking of which: why would the fallback be "text/plain"?
>
> It depends on how the UA treats text/potato.  It would not be
> unreasonable to treat text/potato similarly to text/plain, depending
> on the UA's purpose.

Hm, no. Imho.

"text/html;" is a parse error according to the ABNF.

So the likely outcomes seem to be:

1) Treated as missing parameter, thus as "tex/html", or

2) Treated as invalid header value, thus same as absent content-type header.

In case 2 I wouldn't expect a default text handling.

> ...

Best regards, Julian