Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:94831 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 3181 invoked from network); 4 Aug 2016 11:32:08 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 4 Aug 2016 11:32:08 -0000 Authentication-Results: pb1.pair.com smtp.mail=rowan.collins@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=rowan.collins@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 74.125.82.42 as permitted sender) X-PHP-List-Original-Sender: rowan.collins@gmail.com X-Host-Fingerprint: 74.125.82.42 mail-wm0-f42.google.com Received: from [74.125.82.42] ([74.125.82.42:38678] helo=mail-wm0-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id EA/17-53111-7B723A75 for ; Thu, 04 Aug 2016 07:32:07 -0400 Received: by mail-wm0-f42.google.com with SMTP id o80so374372305wme.1 for ; Thu, 04 Aug 2016 04:32:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=subject:references:from:to:message-id:date:user-agent:mime-version :in-reply-to:content-transfer-encoding; bh=P67xwzvtajg98QkVBdO15N3SWH2URPA5ieubOjuwSF0=; b=sFbe0Wo2FFb+56z+vB7himIfsTH2yL4RS4KeyhMEgqS/FOZYN7voWGH7MYs6tS7pxB Ya5xSuOHQ+liGBbzr1oUoSFB2eylbx9CfJivaKtZDUls0tWbqYMIPi+SH1VgaoawU44P m6SH7/H4+kr5zljlCvglJsvf8NTm6kAItRYsalXT2hw84ulS4DOxMXNuO016Gnf6FRxM dztCqcGsA+K/VwmDSxzxVIwNHg59RefqBjsP3gXjKbJnYL2q+4u0OsZOvY/w/h2kFJlw 9MlTcwOuFWUqKAmZ+SoAx7mBbbNxx0o98MkQNgOM5OI/JBEXw5+HJQd02oQFr0uxiS1T ZJbA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:subject:references:from:to:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=P67xwzvtajg98QkVBdO15N3SWH2URPA5ieubOjuwSF0=; b=NLEHz4DpYzoFCY/1Eld1MElIuVORJRRJFkce7uBdcFeQZB9uNjjT+7ykL20iPn55Ec J3weLTl1rXpDI4QarnJyleaQugE4JCIfmvM6zijrlW/aPOlvI7qAasKClxp5TSDKqjmS kCTXGbDHKbDVyhUg6Oqeya9mYv1qR3SidxQe0NABmcxWSdw2uqV4Sjxo3bSYeXCjFkM2 QYOxotXktDRxTonzs5ky0i3krrrk9CKaWrjwMypVrt+xz05e73537nnZdSKUuzm0l57S cX+Sb+kWVgwD9m+GBmITmbvHnLYF9EU7CeYW+707i5zEkQrBDE/lR7HnNhtDgqmYN0LL Q+DA== X-Gm-Message-State: AEkoousq1M5y8wp5Gb+7WK/AfYfCmvLJwsZgNTg/+eYAk2IiGar3xtNt+okO9QL9JrNT/A== X-Received: by 10.28.211.10 with SMTP id k10mr69732260wmg.16.1470310324778; Thu, 04 Aug 2016 04:32:04 -0700 (PDT) Received: from [192.168.0.98] ([93.188.182.58]) by smtp.gmail.com with ESMTPSA id ly9sm12390398wjb.44.2016.08.04.04.32.04 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 04 Aug 2016 04:32:04 -0700 (PDT) References: <6811e0bd-811c-bd44-2e84-6d08aa8eef9d@gmail.com> To: "internals@lists.php.net" Message-ID: <687f714c-1e1c-8ea7-7800-1148a5755f4f@gmail.com> Date: Thu, 4 Aug 2016 12:30:14 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] Re: Adding validate_var_array()/validate_input_array() to which version? From: rowan.collins@gmail.com (Rowan Collins) On 04/08/2016 11:45, Yasuo Ohgaki wrote: > Invalid inputs that violate input validation rules should not happen > almost always because input validation is _not_ the same input > mistakes by normal users. e.g. typo, user send a little too long > password. These mistakes should be handled as input errors/mistakes, > not input validation error. To me, "validation" absolutely means "checking if the user input the right things". What you're talking about sounds more like assertions, which would fit with the "this must be OK else die" implication of exceptions. Perhaps the functions could be called filter_assert_var_array() etc? Or perhaps some other term, to make it clear that these functions are not intended for the common task of "form validation". Regards, -- Rowan Collins [IMSoP]