Return-Path: Delivered-To: apmail-commons-issues-archive@minotaur.apache.org Received: (qmail 31191 invoked from network); 26 Jan 2011 14:37:10 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 26 Jan 2011 14:37:10 -0000 Received: (qmail 71674 invoked by uid 500); 26 Jan 2011 14:37:09 -0000 Delivered-To: apmail-commons-issues-archive@commons.apache.org Received: (qmail 71305 invoked by uid 500); 26 Jan 2011 14:37:07 -0000 Mailing-List: contact issues-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: issues@commons.apache.org Delivered-To: mailing list issues@commons.apache.org Received: (qmail 71292 invoked by uid 99); 26 Jan 2011 14:37:06 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 26 Jan 2011 14:37:06 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 26 Jan 2011 14:37:05 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id p0QEahPV006656 for ; Wed, 26 Jan 2011 14:36:43 GMT Message-ID: <16764613.215801296052603470.JavaMail.jira@thor> Date: Wed, 26 Jan 2011 09:36:43 -0500 (EST) From: "Sebb (JIRA)" To: issues@commons.apache.org Subject: [jira] Commented: (CODEC-95) Base64: optionally allow strict parsing of base64 strings MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/CODEC-95?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12987023#action_12987023 ] Sebb commented on CODEC-95: --------------------------- The problem with setters is that they cannot be used with final variables. This means that the setting may be changed subsequently, and cause odd errors. It also make testing much harder because of the additional mutable state. Adding a setter "grows the API" just as much as adding another constructor. If there are several setters, then the API grows further for each one. With my suggestion, only the Validation API will grow, and it's optional. > Base64: optionally allow strict parsing of base64 strings > --------------------------------------------------------- > > Key: CODEC-95 > URL: https://issues.apache.org/jira/browse/CODEC-95 > Project: Commons Codec > Issue Type: Improvement > Affects Versions: 1.4 > Reporter: Adam Rabung > Priority: Minor > Attachments: strictMode.zip > > > Currently, Codec skips base64 characters that are outside of the encode table. I realize this is perfectly to spec, but I wonder if other users might appreciate a "strict" mode that throws an exception when one of these illegal characters are encountered. For example, I would love an exception to be thrown here: > new Base64().decode("!@#$ iHaveIllegalCharsAtBeginningAndEnd %^&")); -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.