Hello,

I have a pipeline to handle file uploads using a custom action that
works fine over HTTP but not over HTTPS (SSL). There is no error message
in the log files, just a "Malformed stream" message sent to the browser
(details below). I've tried with Firefox 1.5 on Windows and Linux, and
IE6 on Windows, but always see the same error message.

Can you help?

Any assistance would be much appreciated.

Thanks,

Antony

Error message:

Problem in creating the Request
Message: null
Description: No details available.
Sender: org.apache.cocoon.servlet.CocoonServlet
Source: Cocoon Servlet
cause
Malformed stream

Pipeline:

<map:match pattern="protected/upload">
  <map:act type="file-upload">
    <map:parameter name="directory"
value="{naming:java:comp/env/upload-directory}/{request:remoteUser}" />
    </map:act>
  <map:redirect-to uri="admin.html"/>
</map:match>

Code:

// Get the file
Part part = (Part) request.get("upload-file");
...
// Save the file
String uploadName = part.getUploadName();
// Strip off path (IE on Windows includes it)
uploadName = uploadName.substring(uploadName.lastIndexOf('\\') + 1);
String path = directory + File.separator + uploadName;
part.copyToFile(path);





---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to