Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 3CEB9200CF5 for ; Sun, 27 Aug 2017 22:23:34 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 39FBF163B75; Sun, 27 Aug 2017 20:23:34 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 3432B163B09 for ; Sun, 27 Aug 2017 22:23:33 +0200 (CEST) Received: (qmail 87334 invoked by uid 500); 27 Aug 2017 20:23:31 -0000 Mailing-List: contact dev-help@jmeter.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@jmeter.apache.org Delivered-To: mailing list dev@jmeter.apache.org Received: (qmail 87322 invoked by uid 99); 27 Aug 2017 20:23:31 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 27 Aug 2017 20:23:31 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id E8F46C216A for ; Sun, 27 Aug 2017 20:23:30 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 1.68 X-Spam-Level: * X-Spam-Status: No, score=1.68 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=2, HTML_OBFUSCATE_05_10=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RCVD_IN_SORBS_SPAM=0.5, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd4-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id QucrACsa2HZG for ; Sun, 27 Aug 2017 20:23:27 +0000 (UTC) Received: from mail-qt0-f182.google.com (mail-qt0-f182.google.com [209.85.216.182]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id A06835F46F for ; Sun, 27 Aug 2017 20:23:27 +0000 (UTC) Received: by mail-qt0-f182.google.com with SMTP id v29so17712520qtv.3 for ; Sun, 27 Aug 2017 13:23:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=017rUQ2TnWsH8OYiCz8MYqNEAsVRgkxwowMw9x33dlE=; b=YqPur5vdKL8Yl5yk11Yc50uOAvwpq13ixmRtQtyYRGm3VHbRbj9Pqz7o8oO7nZz5Dm lMl9ivaxFCJmqDsNekC7fjM8dk5mGUmWVCgXS8P+xSMGnw+cyyFxQ1JbYB1Zy+KK3+7a RouoTeAdyAzFoDpe2NK0J9Bc+mZJCxOgRQtggT3qpqUiGyNcxuM/B2s54YLqPc9Ttb2q d7IYMnKvHUI+9OGaO91MB5zrm9Z6FBTaijqcQ94Pbh43MNG+bLu+rQdBg4Kp4cG8ACbG /qpL8WRCRvnjAnOH7a9ocKjwRdnQKJ19lirRaUm9sK86IkEPoR1P1nVOgeX1UeFHxStc qBhw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=017rUQ2TnWsH8OYiCz8MYqNEAsVRgkxwowMw9x33dlE=; b=BSxHPagHAcXl+PmEcz4qDsZb3t3XFlhxK2uutjW8tYxLKT5BzEE1AA0diCb8NHosFS vUKHh0gyFx4cAqz5wO423nzz0OP0hPoM/B4Z0aS7ItKTGATYceI0VzcWjFtf3WPO5y6s LPoJmnWkkkfEAzvBL8rlFYukPWcwBkbM9KVgM8OqDjyW6Gt2dh47GK/t1o+l2Tt8vjFU knXX1+COwYBHyJy3al9KtCSVu7zOUWGZbKkAVv4f4DX1R83Fw9L1QnpYeqBUkNp1T4FF HJQ7kFsQGjR+PCfrXfUaDNsaKdFS0RWFrG0LZGbyMuq1Cw9j1MrLHAsGL+gqHPw1fYZ1 WFOw== X-Gm-Message-State: AHYfb5hDnCppYTISyGkhqIoVf5wo2rhTV1WsG7zLQL7Pe/nwJrRAY8Vo 35OAixAwI6Csbjze1k01O49AfpfeO9zV X-Received: by 10.200.36.133 with SMTP id s5mr6804823qts.276.1503865400881; Sun, 27 Aug 2017 13:23:20 -0700 (PDT) MIME-Version: 1.0 Received: by 10.12.163.1 with HTTP; Sun, 27 Aug 2017 13:23:20 -0700 (PDT) In-Reply-To: References: <20170825190239.B559C3A009D@svn01-us-west.apache.org> <2BE5B043-868E-44DD-9912-00CFAC33D798@internetallee.de> From: Philippe Mouawad Date: Sun, 27 Aug 2017 22:23:20 +0200 Message-ID: Subject: Re: svn commit: r1806215 - in /jmeter/trunk: src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC4Impl.java xdocs/changes.xml To: "dev@jmeter.apache.org" Content-Type: multipart/alternative; boundary="001a114106780276380557c1f37f" archived-at: Sun, 27 Aug 2017 20:23:34 -0000 --001a114106780276380557c1f37f Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Might be interesting : https://stackoverflow.com/questions/20591599/why-arent-post-names-with-unic= ode-sent-correctly-when-using-multipart-form-data/20592910#20592910 On Sun, Aug 27, 2017 at 8:04 PM, Philippe Mouawad < philippe.mouawad@gmail.com> wrote: > Hi Felix, > I noticed while testing that Java Implementation also corrupts Parameter > name, so I think it's a bug also, but I have a doubt regarding the > encoding of parameter names, does RFC force a particular encoding for the= m > (US-ASCII) or can they be encoded in whatever encoding we want ? > > If you look at current code, I have added a check for Java Implementation > to check for corrupt "?_param" instead of "=E5=AE=89_param" > > Please review and give your feedback. > > Thanks > > On Sun, Aug 27, 2017 at 2:41 PM, Philippe Mouawad < > philippe.mouawad@gmail.com> wrote: > >> Hi Felix, >> Look also at this report for Aka HTTP following their fix to >> https://github.com/akka/akka-http/issues/338 >> >> - https://github.com/akka/akka-http/issues/647 >> >> I confirmed current trunk has a similar issue, see >> https://bz.apache.org/bugzilla/show_bug.cgi?id=3D61384#c6. >> >> So I committed my alternative patch, please review. >> >> Still , I don't think it fixes https://bz.apache.org/bugzilla >> /show_bug.cgi?id=3D56141 >> >> >> Regards >> >> On Sun, Aug 27, 2017 at 12:21 PM, Philippe Mouawad < >> philippe.mouawad@gmail.com> wrote: >> >>> Hi Felix, >>> I attached an alternative patch which : >>> >>> - set surrounding header only if we have a charset >>> - same for parameters >>> >>> I have asked a question on HC client mailing list: >>> >>> - http://mail-archives.apache.org/mod_mbox/hc-httpclient-users >>> /201704.mbox/%3CCAH9fUpbxye8-rydo143Bk%3Dr6q2QDJTEndhPmd5GQ3 >>> TjxtLpDxA%40mail.gmail.com%3E >>> >>> >>> I think the following bugs have potentially the same root cause: >>> >>> - https://bz.apache.org/bugzilla/show_bug.cgi?id=3D61384 >>> - https://bz.apache.org/bugzilla/show_bug.cgi?id=3D60800 >>> - https://bz.apache.org/bugzilla/show_bug.cgi?id=3D56141 >>> >>> See this interesting comment also: >>> >>> - https://bz.apache.org/bugzilla/show_bug.cgi?id=3D56141#c4 >>> >>> >>> Regards >>> >>> On Sun, Aug 27, 2017 at 10:59 AM, Felix Schumacher < >>> felix.schumacher@internetallee.de> wrote: >>> >>>> >>>> >>>> Am 26. August 2017 15:11:19 MESZ schrieb Philippe Mouawad < >>>> philippe.mouawad@gmail.com>: >>>> >Hi Felix, >>>> >Are we sure that when encoding is UTF-8 there is no need to set chars= et >>>> >? >>>> >>>> We keep the charset. We only remove it from the surrounding header. >>>> >>>> > >>>> >AFAIK, there were already issue with Multipart forms even before >>>> >refactoring. >>>> >>>> Right. The most questions I found stated that they had problems when >>>> the charset was set. >>>> >>>> What do you think would be the correct way? >>>> >>>> Felix >>>> >>>> > >>>> >Thanks >>>> >Thanks >>>> > >>>> >On Fri, Aug 25, 2017 at 9:02 PM, wrote: >>>> > >>>> >> Author: fschumacher >>>> >> Date: Fri Aug 25 19:02:36 2017 >>>> >> New Revision: 1806215 >>>> >> >>>> >> URL: http://svn.apache.org/viewvc?rev=3D1806215&view=3Drev >>>> >> Log: >>>> >> Don't set the charset on enclosing multipart/form-data header. It >>>> >> irritates some servers. >>>> >> >>>> >> The charset was added sometime back while refactoring to use a newe= r >>>> >api >>>> >> of http client. >>>> >> See https://bz.apache.org/bugzilla/show_bug.cgi?id=3D56141 for more >>>> >info. >>>> >> >>>> >> Bugzilla Id: 61384 >>>> >> >>>> >> >>>> >> Modified: >>>> >> jmeter/trunk/src/protocol/http/org/apache/jmeter/ >>>> >> protocol/http/sampler/HTTPHC4Impl.java >>>> >> jmeter/trunk/xdocs/changes.xml >>>> >> >>>> >> Modified: jmeter/trunk/src/protocol/http/org/apache/jmeter/ >>>> >> protocol/http/sampler/HTTPHC4Impl.java >>>> >> URL: http://svn.apache.org/viewvc/jmeter/trunk/src/protocol/ >>>> >> >>>> >http/org/apache/jmeter/protocol/http/sampler/HTTPHC4Impl.ja >>>> va?rev=3D1806215& >>>> >> r1=3D1806214&r2=3D1806215&view=3Ddiff >>>> >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >>>> >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >>>> >> --- jmeter/trunk/src/protocol/http/org/apache/jmeter/ >>>> >> protocol/http/sampler/HTTPHC4Impl.java (original) >>>> >> +++ jmeter/trunk/src/protocol/http/org/apache/jmeter/ >>>> >> protocol/http/sampler/HTTPHC4Impl.java Fri Aug 25 19:02:36 2017 >>>> >> @@ -1242,7 +1242,7 @@ public class HTTPHC4Impl extends HTTPHCA >>>> >> if(getUseMultipartForPost()) { >>>> >> // If a content encoding is specified, we use that as >>>> >the >>>> >> // encoding of any parameter values >>>> >> - Charset charset =3D null; >>>> >> + Charset charset; >>>> >> if(haveContentEncoding) { >>>> >> charset =3D Charset.forName(contentEncoding); >>>> >> } else { >>>> >> @@ -1254,8 +1254,7 @@ public class HTTPHC4Impl extends HTTPHCA >>>> >> getDoBrowserCompatibleMultipart(), charset= , >>>> >> haveContentEncoding); >>>> >> } >>>> >> // Write the request to our own stream >>>> >> - MultipartEntityBuilder multipartEntityBuilder =3D >>>> >> MultipartEntityBuilder.create() >>>> >> - .setCharset(charset); >>>> >> + MultipartEntityBuilder multipartEntityBuilder =3D >>>> >> MultipartEntityBuilder.create(); >>>> >> if(getDoBrowserCompatibleMultipart()) { >>>> >> multipartEntityBuilder.setLaxMode(); >>>> >> } else { >>>> >> >>>> >> Modified: jmeter/trunk/xdocs/changes.xml >>>> >> URL: http://svn.apache.org/viewvc/jmeter/trunk/xdocs/changes. >>>> >> xml?rev=3D1806215&r1=3D1806214&r2=3D1806215&view=3Ddiff >>>> >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >>>> >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >>>> >> --- jmeter/trunk/xdocs/changes.xml [utf-8] (original) >>>> >> +++ jmeter/trunk/xdocs/changes.xml [utf-8] Fri Aug 25 19:02:36 2017 >>>> >> @@ -167,6 +167,9 @@ Incorporated feed back about unclear doc >>>> >> >>>> >>

HTTP Samplers and Test Script Recorder

>>>> >>
    >>>> >> +
  • 61384Don't set the charset on enclosing >>>> >> multipart/form-data header. It irritates some >>>> >servers.
    >>>> >> + The charset was added sometime back while refactoring to use = a >>>> >newer >>>> >> api of http client. >>>> >> + See 56141 for more info.
  • >>>> >>
>>>> >> >>>> >>

Other Samplers

>>>> >> >>>> >> >>>> >> >>>> >>> >>> >>> >>> -- >>> Cordialement. >>> Philippe Mouawad. >>> >>> >>> >> >> >> -- >> Cordialement. >> Philippe Mouawad. >> >> >> > > > -- > Cordialement. > Philippe Mouawad. > > > --=20 Cordialement. Philippe Mouawad. --001a114106780276380557c1f37f--