| Summary: | [Fileupload] special characters (ä,ö,ü etc.) in filename | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [RT] RAP | Reporter: | Stefan Milchram <stefan.milchram> | ||||
| Component: | Incubator | Assignee: | Project Inbox <rap.incubator-inbox> | ||||
| Status: | RESOLVED NOT_ECLIPSE | QA Contact: | |||||
| Severity: | normal | ||||||
| Priority: | P3 | ||||||
| Version: | 2.1 | ||||||
| Target Milestone: | --- | ||||||
| Hardware: | All | ||||||
| OS: | All | ||||||
| Whiteboard: | |||||||
| Attachments: |
|
||||||
|
Description
Stefan Milchram
Stefan, we can't reproduce the filename corruption with all browsers. Can you give some hints what to look for in org.eclipse.rap.rwt.supplemental.fileupload.internal.FileUploadProcessor.readUploaddedFileItem(HttpServletRequest)? Created attachment 235715 [details]
Screenshot showing corrupted file name
The screenshot shows that the corrupted filename comes from the apache-code. I googled for apache fileupload and character issues, but did not find a solution for this. I used Chrome and IE to reproduce the error. Could you check the request body when uploading a file? Is the filename corrupted in the request as well (filename inside Content-Disposition)? It is already corrupted there: ------WebKitFormBoundaryXHrWzMItZPiBBlZl Content-Disposition: form-data; name="file"; filename="ä.txt" Content-Type: text/plain ------WebKitFormBoundaryXHrWzMItZPiBBlZl-- This means it's not a RAP (Apache FileUpload) issue. If browser transmit the filename corrupted we can't do anything about it. Which OS are you using? Yes, sry i missed that. We currently use Windows XP. I will close it as NOT_ECLIPSE. Please reopen if you disagree. The problem seems to be caused by a missing charset=UTF-8 in the ContentType of the request to the servicehandler "org.eclipse.rap.fileupload". Copy of the headers of the request: " POST /abs?servicehandler=org.eclipse.rap.fileupload&cid=713d0ed5&token=e9d2b2ec0c07cf HTTP/1.1 Host: 127.0.0.1:10080 Connection: keep-alive Content-Length: 180 Cache-Control: max-age=0 Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 Origin: http://127.0.0.1:10080 User-Agent: Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/29.0.1547.76 Safari/537.36 Content-Type: multipart/form-data; boundary=----WebKitFormBoundaryp5yCqqWAB6rTdDns Referer: http://127.0.0.1:10080/abs Accept-Encoding: gzip,deflate,sdch Accept-Language: en-US,en;q=0.8,de;q=0.6 Cookie: JSESSIONID=gri268d0cedvicsfk47c3pqs; settingStore=1346400222265_0 " When i set the encoding manually in org.eclipse.rap.rwt.supplemental.fileupload.internal.FileUploadProcessor.readUploadedFileItem(HttpServletRequest) before "upload.parseRequest( request );" it also works, but the charset should be specified in the request. Stefan, I can't reproduce it on my virtual machine with Windows XP (SP3) - both with Firefox and IE8. The filename is not corrupted. Is the server running on the Windows XP machine or the client? I am running the server directly from eclipse using the rap-launcher. Browser and eclipse are running on Windows XP. |