Uploaded image for project: 'Click'
  1. Click
  2. CLK-312

request.setCharacterEncoding is called after request parameters are read

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: core
    • Labels:
      None
    • Environment:
      Click 1.4RC3

      Description

      Ricardo identified a problem in ClickServlet where request.setCharacterEncoding is called after ClickRequestWrapper is created which can potentially read request parameters in the case of a file upload.

      According to the Servlet javadoc ServletRequest#setCharacterEncoding states:

      This method must be called prior to reading request parameters or reading input using getReader().

      To fix we can move the request.setCharacterEncoding code before we create a new Context.

      Kudos to Ricardo for identifying and providing a fix for this issue!

        Attachments

          Activity

            People

            • Assignee:
              sabob Bob Schellink
              Reporter:
              sabob Bob Schellink
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: