Download does not gracefully handle filenames with a colon




5 years ago
2 years ago


(Reporter: charles.goodwin, Unassigned)


Firefox Tracking Flags

(Not tracked)





5 years ago
User Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:26.0) Gecko/20100101 Firefox/26.0 (Beta/Release)
Build ID: 20131205075310

Steps to reproduce:

Firefox 26.0 on Windows 8.1 64bit.

Go here:

Click 'download'.

Actual results:

I am presented with a 'save as' dialog that presents 'Fwd_' as the filename. If you click on the image instead to open the SVG directly, you'll see the full filename ("Fwd: China door with dragon face.svg") in the url bar.

Expected results:

It should behave the same as the 'save page as' performed on the SVG directly, which is the ':' is replaced with a space.
Right click and 'save page as' and it works as desired.

Comment 1

5 years ago
GET /download/people/rejon/Fwd:%20China%20door%20with%20dragon%20face.svg HTTP/1.1

Response Header
HTTP/1.1 200 OK
Server: Apache/2.2.16 (Debian)
X-Powered-By: PHP/5.3.3-7+squeeze17
Content-Disposition: attachment; filename=Fwd: China door with dragon face.svg
content-transfer-encoding: binary
Expires: 0
Cache-Control: max-age=600, private, must-revalidate
Pragma: public
Content-Type: application/octet-stream
Content-Length: 217467
Accept-Ranges: bytes
Date: Thu, 02 Jan 2014 19:49:05 GMT
X-Varnish: 1490455428 1490294370
Age: 2869
Via: 1.1 varnish
Connection: keep-alive
Component: Untriaged → File Handling
Ever confirmed: true
Product: Firefox → Core
Version: 26 Branch → Trunk


5 years ago
Summary: Save as does not gracefully handle filenames with a colon → Download does not gracefully handle filenames with a colon

Comment 2

5 years ago
Anyone looking at this probably wants to investigate the code that flows through GetFilenameAndExtensionFromChannel (


2 years ago
Component: File Handling → File Handling
Product: Core → Firefox
Version: Trunk → unspecified
You need to log in before you can comment on or make changes to this bug.