Return-Path: X-Original-To: apmail-struts-issues-archive@minotaur.apache.org Delivered-To: apmail-struts-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 252131748D for ; Fri, 13 Mar 2015 16:59:41 +0000 (UTC) Received: (qmail 83817 invoked by uid 500); 13 Mar 2015 16:59:41 -0000 Delivered-To: apmail-struts-issues-archive@struts.apache.org Received: (qmail 83782 invoked by uid 500); 13 Mar 2015 16:59:40 -0000 Mailing-List: contact issues-help@struts.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@struts.apache.org Delivered-To: mailing list issues@struts.apache.org Received: (qmail 83771 invoked by uid 99); 13 Mar 2015 16:59:40 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 13 Mar 2015 16:59:40 +0000 Date: Fri, 13 Mar 2015 16:59:40 +0000 (UTC) From: "Aleksandr Mashchenko (JIRA)" To: issues@struts.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (WW-4457) FileUploadInterceptor uses injected pattern matcher MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/WW-4457?page=3Dcom.atlassian.ji= ra.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D1436064= 5#comment-14360645 ]=20 Aleksandr Mashchenko commented on WW-4457: ------------------------------------------ Are you sure? I just run an app in debug mode with 2.3.22-SNAPSHOT and {{De= faultContentTypeMatcher}} is being injected in {{FileUploadInterceptor}} ni= cely and it uses wildcard matching. > FileUploadInterceptor uses injected pattern matcher > --------------------------------------------------- > > Key: WW-4457 > URL: https://issues.apache.org/jira/browse/WW-4457 > Project: Struts 2 > Issue Type: Bug > Components: Core Interceptors > Reporter: Aleksandr Mashchenko > Assignee: Lukasz Lenart > Fix For: 2.3.22 > > > Currently {{FileUploadInterceptor}} uses injected pattern matcher for che= cking {{allowedTypes}}, which yields inconsistent behavior with different d= efault pattern matchers. Some mime types which are working fine with {{Wild= cardHelper}} are not working with the {{RegexPatternMatcher}}, because of t= he special regex character presented in them (e.g. {{image/svg+xml}} - {{+}= } is a special character in regex). > IMO file upload interceptor should use {{WildcardHelper}} no matter what = pattern matcher is set as the default one. Or is there any point in injecti= ng pattern matcher in file upload interceptor? > Original report: [=E2=80=9CContent-Type not allowed=E2=80=9D while upload= ing an SVG file, that is in the allowed whitelist|http://stackoverflow.com/= q/28304692/1700321] -- This message was sent by Atlassian JIRA (v6.3.4#6332)