Closed
Bug 697508
Opened 14 years ago
Closed 14 years ago
Firefox does not consistently handle attachments when utilizing content-disposition header with a space character in the attachment field
Categories
(Firefox :: File Handling, defect)
Tracking
()
RESOLVED
DUPLICATE
of bug 221028
People
(Reporter: phil, Unassigned)
Details
User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:7.0.1) Gecko/20100101 Firefox/7.0.1
Build ID: 20110928134238
Steps to reproduce:
Attempted to force download as attachment by providing "Content-disposition: attachment;" header via php. Test code follows:
<?php
header('Content-disposition: attachment; filename=' . $testvalue);
header('Content-Type: application/octet-stream');
readfile('testfile.pdf');
?>
Actual results:
In the example code above, if $testvalue is set to foo.pdf, it will show up in the browser as an "adobe acrobat document", and provide standard document handling for that file type. If the test value is set to "f oo.pdf", the file will show up as simply "f" and as an "application/octet-stream", without any options or functionality to open the file. Removing the content-type header provides a dialog showing the file to be downloaded as a 'firefox file'. This occurred in latest public release of firefox, 7.0.1.
Expected results:
The addition of a space character in the header shouldn't change the way Firefox handles an attachment and displays the dialog to the user. I haven't checked the RFCs, and I would not be surprised if the space character may be entirely disallowed in the content-disposition field. That said, this issue does not occur in contemporary releases of Chrome, IE or opera browsers..
Updated•14 years ago
|
Status: UNCONFIRMED → RESOLVED
Closed: 14 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•