Firefox destroys name of downloaded file depending on the file name characters
Categories
(Firefox :: File Handling, defect)
Tracking
()
People
(Reporter: peterm.eller, Unassigned)
Details
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Firefox/60.0
Steps to reproduce:
I use convert2mp3.net for the downloading of files in mp4 format, mostly Youtube files.
Example: http://convert2mp3.net/index.php?p=complete&id=youtube_ARVKe03RWUg&key=2ezuz5lNJX8C
Actual results:
Depending of the name (title) of the file, Firefox destroys the name of the downloaded file in mp4-format.
After clicking the green button "Start Download" the name is still shown correctly when the user is asked to choose a directory where to save, but in the further processing the file name will be changed, depending of the characters of the file name.
Example:
- Youtube video (file name): (MIAC #166) If You Were a Global Leader What Would You Do?
- Youtube URL: https://www.youtube.com/watch?v=ARVKe03RWUg
After showing the correct name like above and choosing a directory the file name after saving is just: (MIAC.
So the name is not only incorrect, the file extension is missing, too.
Expected results:
File name should be: "(MIAC #166) If You Were a Global Leader What Would You Do?.mp4" as it is possible to rename the file to that name plus extension.
If http://convert2mp3.net/index.php?p=complete&id=youtube_ARVKe03RWUg&key=2ezuz5lNJX8C is already deleted, use the whole procedure from the beginning.
Comment 2•5 years ago
|
||
The server convert2mp3 sends the file with this header:
attachment; filename="(MIAC #166) If You Were a Global Leader What Would You Do_.mp3"
Comment 3•5 years ago
|
||
sorry, the website puts the filename in quotes and that should work and it does indeed work on Firefox66 on windows when I disable the generating the mp3 Tag on the website.
I get the broken filename if I let the website set incorrect MP3 Tags and it detects the Interpret as "MIAC (" and the Title as " #166)" and the result is that it sends the file as :
attachment; filename="(MIAC - #166).mp3"
I will test this on Linux.
Comment 4•5 years ago
|
||
I tested this on Ubuntu18.04LTS and with Firefox64.
I get the correct filename if I select on the website to not set an MP3 Tag and I get a wrong filename if I let the website set the mp3 Tags with default values.
Updated•5 years ago
|
Comment 5•5 years ago
|
||
Reporter:
This works for me except in that case that the website sends the file with a wrong filename as you can see at the content-disposition http header visible in the Firefox developer tools(F12)/networking section but that is a fault of the server.
I get the same behavior with Chrome.
Chrome saves the file correctly, but changes the filename slightly from "(MIAC #166) If You Were a Global Leader What Would You Do?.mp4" to "(MIAC %23166) If You Were a Global Leader What Would You Do_.mp4" (? becomes _).
Description
•