users@jersey.java.net

[Jersey] Attribute "filename" of header Content-Disposition with incorrect codificacition

From: nelson rivera <nelsonrivera12_at_gmail.com>
Date: Wed, 16 Nov 2016 16:37:31 -0500

Processing a post request of Content-Type: multipart/form-data, if the
original file name of one of the parts in the client side have
accentuated characters, the attribute "filename" of header
Content-Disposition of this bodypart that i get in the server side
when i parse the multimpart iterating for the parts, is incorrectly
encoded.

I use jersey 2.22.2 y mimepull 1.9.6.
The configuration of servlet jersey with spring in web.xml :
<servlet>
        <servlet-name>jersey-spring</servlet-name>
        <servlet-class>org.glassfish.jersey.servlet.ServletContainer</servlet-class>

        <init-param>
            <param-name>jersey.config.server.provider.packages</param-name>
            <param-value>org.rp.platform;com.fasterxml.jackson.jaxrs.json</param-value>
        </init-param>

        <init-param>
            <param-name>jersey.config.server.provider.classnames</param-name>
            <param-value>org.rp.platform.filters.ResponseCorsFilter;org.glassfish.jersey.jackson.JacksonFeature;org.glassfish.jersey.media.multipart.MultiPartFeature</param-value>
        </init-param>

    </servlet>