Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:72203 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 5504 invoked from network); 4 Feb 2014 15:57:37 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 4 Feb 2014 15:57:37 -0000 Authentication-Results: pb1.pair.com header.from=ajf@ajf.me; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=ajf@ajf.me; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain ajf.me designates 198.187.29.247 as permitted sender) X-PHP-List-Original-Sender: ajf@ajf.me X-Host-Fingerprint: 198.187.29.247 imap4-3.ox.registrar-servers.com Received: from [198.187.29.247] ([198.187.29.247:60193] helo=imap4-3.ox.registrar-servers.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id E4/B0-02016-EED01F25 for ; Tue, 04 Feb 2014 10:57:37 -0500 Received: from localhost (localhost [127.0.0.1]) by oxmail.registrar-servers.com (Postfix) with ESMTP id 907B756007D; Tue, 4 Feb 2014 10:57:32 -0500 (EST) X-Virus-Scanned: Debian amavisd-new at imap4.ox.registrar-servers.com Received: from oxmail.registrar-servers.com ([127.0.0.1]) by localhost (imap4.ox.registrar-servers.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id URrJCdCQ6zeh; Tue, 4 Feb 2014 10:57:32 -0500 (EST) Received: from [192.168.0.200] (unknown [176.25.177.94]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by oxmail.registrar-servers.com (Postfix) with ESMTPSA id A4BF0560075; Tue, 4 Feb 2014 10:57:31 -0500 (EST) Message-ID: <52F10DE9.3040504@ajf.me> Date: Tue, 04 Feb 2014 15:57:29 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0 MIME-Version: 1.0 To: Yasuo Ohgaki , "internals@lists.php.net" References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] [RFC] Improve HTML escape From: ajf@ajf.me (Andrea Faulds) Hi, Some thoughts on this. So far as I see it, the point of adding / escaping would be for unquoted attribute values. However, there's nothing we can really do for unquoted attribute values - the moment someone adds a space, they're broken. Unquoted attribute values being legal in HTML5 is, IMO, a good thing. They're nice when authoring HTML, as this: Can become this: However, you should *never* be putting user input as an attribute value without quotes around it. I don't think adding / here is a good idea. With or without it, code which does /> will be vulnerable anyway. But if we add it, people might think doing that is safe, which would be worse. -- Andrea Faulds http://ajf.me/