Closed Bug 146781 Opened 22 years ago Closed 21 years ago

download file misnaming, when the downloaded file comes from a redirected URL [extension]

Categories

(Core Graveyard :: File Handling, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: rnd, Assigned: law)

References

()

Details

(Keywords: platform-parity)

From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.0rc3)
Gecko/20020523
BuildID:    2002052306

When attempting to download this file, upon download completion, Mozilla renames
the file bal1.wmv to get.php.wmv.  After further investigation, mozilla renames
any *.mpg or *.wmv file to get.php.<filetype> that are downloaded from this
website.  There's no other mime types available to try this with, but I doubt
that really matters.

Reproducible: Always
Steps to Reproduce:
1. find linke to download video
2. rick click on link
3. click save target link as
4. download save window opens up and file has been renamed


Actual Results:  Mozilla renames the file every time

Expected Results:  the correct file name should appear in the save window
-> File Handling
Assignee: Matti → law
Component: Browser-General → File Handling
QA Contact: imajes-qa → sairuh
http://cgi.stileproject.com/get.php?f=bal11.wmv&k=53694669

is the link in question.  The filename in this link is "get.php".  The site 
sends no Content-Disposition header with a filename.

So why would we use any filename other than "get.php"?  Are we supposed to 
mind-read and figure out that the thing followint "f=" is a _filename_?
IE does this better.

the link (which you right-click) is:
http://cgi.stileproject.com/get.php?f=bal11.wmv&k=53694669

however, what comes back from that link is:

HTTP/1.1 302 Found
Date: Wed, 26 Jun 2002 01:06:33 GMT
Server: Apache/1.3.26 (Unix) PHP/4.1.1
X-Powered-By: PHP/4.1.1
Location: http://static.stileproject.com/kuki/bal11.wmv
Connection: close
Transfer-Encoding: chunked
Content-Type: text/html

and http://static.stileproject.com/kuki/bal11.wmv has a reasonable file name,
and a content-type of WMV.

the issue here is that mozilla is taking the name from the right-clicked link,
rather than taking it from the URL where the file actually comes from.

should this be confirmed?
even ns4 does it right, dont ask me how ...
Linux 1.1 names it properly: bal11.wmv
Keywords: pp
then its due to bug 120327

*** This bug has been marked as a duplicate of 120327 ***
Status: UNCONFIRMED → RESOLVED
Closed: 22 years ago
Resolution: --- → DUPLICATE
um... I'm not sure how this can be a dupe of that bug.  with a 1.1 branch build
on win32, this still happens, and bug 120327 is fixed.

the problem here is that mozilla is taking the content-type from the first thing
it gets, not the file it actually downloads (after the redirect).
Confirming and reopening... 2002081419 on Win98.  Going to dup a bug against
this one...
Status: RESOLVED → UNCONFIRMED
Resolution: DUPLICATE → ---
*** Bug 163755 has been marked as a duplicate of this bug. ***
Status: UNCONFIRMED → NEW
Ever confirmed: true
Need testcase - the url doesn't work to me.
I could probably put together a testcase in my web space given a little time,
but the URL given in the URL field works for me and demonstrates the problem.

just a guess, but are you using (or behind) any kind of content filter? the site
mentioned hosts adult videos (pr0n).
Re: Comment 11

Make sure you use the one in the URL field, not the one Boris mentioned.  Click
the URL link, and then right click the link on the page that results.  It looks
like the URL changes so people don't link directly to the file.
No - no content filtering here.
But maybe you need to be registered somehow to download the file? I get only
some error page, when I click on the URL. Maybe it would be really good to make
a simple testcase.
And maybe there is a problem that I'm trying the URL from Linux, because I think
it isn't platform specific bug.
Ah, I didn't read the description of the bug well.

Sorry for that.

It isn't platform specific.
OS: Windows 2000 → All
Hardware: PC → All
Summary: download file misnaming → download file misnaming, when the downloaded file comes from a redirected URL
So let's get a few things clear here:

1) bug 163755 is a different bug from this (and I am accordingly reopening it)
2) We should be putting up that filepicker before we start the retrieval (on a
   right-click save-as).  We're not quite doing that now, but we will be soon.
   Accordingly, I would be tempted to mark this as wontfix.
*** Bug 166725 has been marked as a duplicate of this bug. ***
QA Contact: sairuh → petersen
*** Bug 132649 has been marked as a duplicate of this bug. ***
*** Bug 170239 has been marked as a duplicate of this bug. ***
*** Bug 181597 has been marked as a duplicate of this bug. ***
*** Bug 184609 has been marked as a duplicate of this bug. ***
Summary: download file misnaming, when the downloaded file comes from a redirected URL → download file misnaming, when the downloaded file comes from a redirected URL [extension]
Any chance on a fix for 1.4?
This is a wontfix, per comment 16.
Status: NEW → RESOLVED
Closed: 22 years ago21 years ago
Resolution: --- → WONTFIX
*** Bug 230641 has been marked as a duplicate of this bug. ***
*** Bug 261773 has been marked as a duplicate of this bug. ***
*** Bug 350552 has been marked as a duplicate of this bug. ***
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.