Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:72566 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 42974 invoked from network); 13 Feb 2014 21:43:42 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 13 Feb 2014 21:43:42 -0000 Authentication-Results: pb1.pair.com header.from=yohgaki@gmail.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=yohgaki@gmail.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.215.42 as permitted sender) X-PHP-List-Original-Sender: yohgaki@gmail.com X-Host-Fingerprint: 209.85.215.42 mail-la0-f42.google.com Received: from [209.85.215.42] ([209.85.215.42:46866] helo=mail-la0-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 6F/CB-09050-C8C3DF25 for ; Thu, 13 Feb 2014 16:43:41 -0500 Received: by mail-la0-f42.google.com with SMTP id hr13so8835556lab.29 for ; Thu, 13 Feb 2014 13:43:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc:content-type; bh=1rkEyVB7X4FDcQzghGRcft5RKdinQpx+G2f3zzFXUiY=; b=XarhJIpKwnALeI2LM+DSZ9tsgmpfx/oJrQsGhlzaktpYJc7VTcs/9HKuiCcH1w4QE9 1KZD2BMmf8EV70dAvL2LOoQXfEvOU+OD3z7DaIQFxcOXiqtdrZdzazMROPMZwq8KSBSS JXnysXvNDDSo4808HqIbGCo69g+MypoDw/UieTUmleDCItjTuv1+J/ep5Jd6IFtSL+XU rQC9TruAwMOOWFH7NWYihLmyhzA78ma51m2mu5dbvKknmNOETPHoRmpQbcm9698EXBka HWm5IrpaJ84VrDX9Kilp5lmzhq8zYcIGK94F1wLB+BSQKt70WhajHhKjNIneEmTXgWTY csLQ== X-Received: by 10.152.20.134 with SMTP id n6mr98044lae.83.1392327817952; Thu, 13 Feb 2014 13:43:37 -0800 (PST) MIME-Version: 1.0 Sender: yohgaki@gmail.com Received: by 10.112.199.37 with HTTP; Thu, 13 Feb 2014 13:42:57 -0800 (PST) In-Reply-To: References: Date: Fri, 14 Feb 2014 06:42:57 +0900 X-Google-Sender-Auth: UZGSK7MNiMABkZnd1EUV_305DVQ Message-ID: To: Nikita Popov Cc: "internals@lists.php.net" Content-Type: multipart/alternative; boundary=089e01493dbe0002c204f25095b2 Subject: Re: [PHP-DEV] [VOTE] Multbye char handling - Remove vulnerability related to multibyte short and long term From: yohgaki@ohgaki.net (Yasuo Ohgaki) --089e01493dbe0002c204f25095b2 Content-Type: text/plain; charset=UTF-8 Hi Nikita, On Fri, Feb 14, 2014 at 6:14 AM, Nikita Popov wrote: > I voted no on both RFCs, for about the same reasons as Joe. Voting on > mbstring-ng at this point makes about zero sense, given that the code is > nowhere even near being ready for merging into PHP. > > Regarding the other RFC for the addition of new mb_* function, I'd like to > start off by saying that I disagree with your premise that this is a > security vulnerability that needs to be fixed quickly and across all > supported versions. As far as I can see the issue is somebody using > addslashes() in an inappropriate context - this is a vulnerability in the > application, not PHP. This is a lot like saying that we have an RCE > vulnerability in eval() because someone had the genius idea of putting > eval($_GET['str']) in his or her code. > > As this constitutes no critical or non-critical vulnerability in PHP, any > function additions should only happen in PHP 5.6 and not PHP 5.4+. > > Apart from this, the RFC is very low on technical detail. It doesn't have > a patch, which is not a problem *per-se*, however it doesn't have any > implementational details whatsoever. While I guess that the addslashes part > is rather straightforward, I'm sure that addcslashes, escapeshellarg and > var_export are less trivial. > > An example of what is unclear: The addclashes functions has a charlist > parameter. Currently chars with ASCII <32, >126 are encoded in octal - what > will happen here with multibyte chars? Will you encode the unicode code > point in octal? Are there even systems that support that? And what about > the range feature? Will this cover unicode code point ranges now? Etc. > > This RFC probably has merit, but right now there is not enough detail to > make an informed decision. > Very informative comment. Thank you! Regards, -- Yasuo Ohgaki yohgaki@ohgaki.net --089e01493dbe0002c204f25095b2--