Return-Path: Delivered-To: apmail-myfaces-dev-archive@www.apache.org Received: (qmail 40721 invoked from network); 16 Oct 2006 08:13:29 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 16 Oct 2006 08:13:29 -0000 Received: (qmail 42900 invoked by uid 500); 16 Oct 2006 08:13:28 -0000 Delivered-To: apmail-myfaces-dev-archive@myfaces.apache.org Received: (qmail 42474 invoked by uid 500); 16 Oct 2006 08:13:27 -0000 Mailing-List: contact dev-help@myfaces.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "MyFaces Development" Delivered-To: mailing list dev@myfaces.apache.org Received: (qmail 42463 invoked by uid 99); 16 Oct 2006 08:13:26 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 16 Oct 2006 01:13:26 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from [209.237.227.198] (HELO brutus.apache.org) (209.237.227.198) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 16 Oct 2006 01:13:25 -0700 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 970B67142D1 for ; Mon, 16 Oct 2006 01:12:36 -0700 (PDT) Message-ID: <3591004.1160986356615.JavaMail.jira@brutus> Date: Mon, 16 Oct 2006 01:12:36 -0700 (PDT) From: "Martin Marinschek (JIRA)" To: dev@myfaces.apache.org Subject: [jira] Commented: (MYFACES-1467) Validation doesn't run for required fields if submitted value is null In-Reply-To: <16232859.1160779115001.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N [ http://issues.apache.org/jira/browse/MYFACES-1467?page=3Dcomments#act= ion_12442502 ]=20 =20 Martin Marinschek commented on MYFACES-1467: -------------------------------------------- Yes, I agree that this might be better off in an extended framework. But ho= w to build this extended framework if no validator ever gets called when th= e value is null? I don't have a place to hook in the framework then (at lea= st to existing components extending from the standard components - Trinidad= has it easier here, with a completely different component hierarchy)... regards, Martin > Validation doesn't run for required fields if submitted value is null > --------------------------------------------------------------------- > > Key: MYFACES-1467 > URL: http://issues.apache.org/jira/browse/MYFACES-1467 > Project: MyFaces Core > Issue Type: Bug > Components: General > Affects Versions: 1.2.0-SNAPSHOT, 1.1.5-SNAPSHOT > Reporter: David Chandler > Assigned To: Matthias We=C3=9Fendorf > Attachments: patch.txt > > > A component with a required value will not fail validation as expected if= the submitted value is null. This issue is not seen normally because brows= ers send the value for an empty text field as an empty string. That is, the= POST data for an empty field1 will contain the field name but no value, li= ke field1=3D&field2=3Dsomething. However, if you use a man-in-the-middle pr= oxy such as Paros to remove "fieldname=3D" from the POST data, the submitte= d value will be null. UIInput.validate() skips validation for null submitte= d values, but since requiredness is also part of validation, the requiredne= ss check gets skipped, too. --=20 This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: htt= p://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira