Project

General

Profile

Actions

Bug #2256

closed

Strange Filename Leads to 404

Added by TheOnly92 about 11 years ago. Updated about 8 years ago.

Status:
Invalid
Priority:
Normal
Category:
core
Target version:
-
ASK QUESTIONS IN Forums:

Description

I have a filename like this: 林俊杰 - 西界.zip, when I try to do GET with the original filename, it gives me a 400 bad request error. If I try to urlencode it into 26%2326519%3B%26%2320426%3B%26%2326480%3B+-+%26%2335199%3B%26%2330028%3B.zip, it gives me 404. The file does exist in the webroot directory.

Example: http://beta.theonly92.com/林俊杰 - 西界.zip
I'm dead sure the file exists.


Related issues

Is duplicate of Feature #1695: Chinese file name support?InvalidActions
Actions #1

Updated by TheOnly92 about 11 years ago

The filename is htmlentity'd 林俊杰 - 西界.zip Here's the true filename.

Actions #2

Updated by bert about 8 years ago

This works just fine for me on current trunk, revision 2903:

sumner: wget -O- "http://192.168.1.5:2000/??? - ??.zip" 
--2013-09-13 12:11:44--  http://192.168.1.5:2000/%E6%9E%97%E4%BF%8A%E6%9D%B0%20-%20%E8%A5%BF%E7%95%8C.zip
Connecting to 192.168.1.5:2000... connected.
HTTP request sent, awaiting response... 200 OK
Length: 44 [application/zip]
Saving to: ‘STDOUT’

 0% [                                       ] 0           --.-K/s              
<html>
    <body>
        Chinese!
    </body>
</html>

From the access log, showing wget and chrome fetching the same URL:

192.168.1.5 192.168.1.5:2000 - [13/Sep/2013:12:11:44 +0200] "GET /%E6%9E%97%E4%BF%8A%E6%9D%B0%20-%20%E8%A5%BF%E7%95%8C.zip HTTP/1.1" 200 44 "-" "Wget/1.14 (linux-gnu)" 
192.168.1.5 192.168.1.5:2000 - [13/Sep/2013:12:12:33 +0200] "GET /%E6%9E%97%E4%BF%8A%E6%9D%B0%20-%20%E8%A5%BF%E7%95%8C.zip HTTP/1.1" 200 44 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/29.0.1547.65 Safari/537.36" 

Actions #3

Updated by stbuehler about 8 years ago

  • Status changed from New to Invalid

Yes.

lighttpd doesn't handle the filename encoding (utf8, iso-8859-1, ...); it is your job to build the correct byte string with url encoding.

Actions

Also available in: Atom