User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:18.104.22.168) Gecko/2009011913 Firefox/3.0.6 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:22.214.171.124) Gecko/2009011913 Firefox/3.0.6 Mozilla Firefox seems to have changed behaviour when it comes to accessing FTP sites. The newer versions _ALWAYS_ send a PWD command, where older versions did not. Unfortunately, when access to that command is denied by the server, it produces the error "550 PWD: Permission denied" and the download does not start! If you open this URL in an older version of Firefox or in Internet Explorer, it will work. In Firefox 3.0.6 it certainly does not: ftp://ftptest:firstname.lastname@example.org/test.txt As you can see from the URL, it directs Firefox to use the FTP protocol and to use the username ftptest and the password testpassword. These are valid credentials, you may test them in any FTP client. You will however not get a directory listing. This is because this is a so-called 'blind download' account. You may only download files that you know the full name of. As I've said.. in other browsers such as IE7 and Opera it just works. Even barely older versions of Firefox work perfectly with this URL. The problem is that Firefox sends a PWD command while that is not necessary in my humble opinion. That wouldn't be so bad if Firefox would just continue the process and sent a RETR command so the file could be retrieved. Unfortunately it doesn't do that. It just stops at the error message. I have resolved this problem on the server end by using a workaround by making an exception for PWD and XPWD commands so that the server is now 'Firefox-compatible". Obviously this is only a minor problem but it is a puzzling one to see in such a fine browser. Reproducible: Always Steps to Reproduce: 1. open Mozilla Firefox 3.0.6 2. open the URL: ftp://ftptest:email@example.com/test.txt 3. enjoy the error message. no download! Actual Results: An error message showed up: Alert 550 PWD: Permission denied Expected Results: It should have either opened the text file in the browser or offered me to save or open the file or.. something. Instead it just spat out an error while it did have the filename I wanted and it did have access to it (as any other browser can confirm) This problem even occurred for me on a plain vanilla install of Firefox 3.0.6 English version. The FTP server software I am using is ProFTPD 1.3.0 on ubuntu 7.04 on an x86 platform. I have created a user that has its home directory in /test on the server and is chrooted there. The file /test/test.txt belongs to nobody:nogroup and there are read rights on it. In /etc/proftpd/proftpd.conf I have added the following information to make sure the 'blind download' user ftptest has only the ability to retrieve files if the user knows the exact filename. <Directory /test> AllowOverwrite off <Limit ALL> DenyALL </Limit> <Limit RETR SIZE> AllowALL </Limit> </Directory> If I change the line <Limit RETR SIZE> to <Limit RETR SIZE XPWD PWD> then Firefox seems to be happy and it all starts working again. However, as I've said earlier.. Slightly older versions of Firefox such as 3.0.1 and 3.0.2 do not seem to have this problem at all. I consider this a true bug as it breaks functionality when links in a webpage to blind download FTP servers are used. Or even where simply PWD is omitted or removed on purpose. Especially sites like element5.com like to do this - generate a unique filename and then link buyers to it so that only those that have the correct FTP URL will be able to download the file. I really hate having to tell my clients to use Internet Explorer to circumvent a bug in Firefox. Here's hoping it gets fixed :)
confirming with SM 1.9.1 branch on the given URL
Created attachment 365646 [details] [diff] [review] patch v1
Michal, I'm probably the wrong reviewer for this. You want dougt or someone... In any case, this seems to be a regression, right? From what bug?
(In reply to comment #3) > In any case, this seems to be a regression, right? From what bug? PWD command was added in nsFtpConnectionThread.cpp&rev=1.204 (2001-10-28 01:58) and unsuccessful PWD was always fatal (except revisions 1.259-1.260).
I'm having a hard time reconciling that with comment 0....
I've tried several versions and all fail: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.5) Gecko/20041107 Firefox/1.0 Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8) Gecko/20060101 Firefox/1.5 Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1b1) Gecko/20060808 BonEcho/2.0b1 Mozilla/5.0 (X11; U; Linux i686; en-US; rv:126.96.36.199pre) Gecko/20070227 BonEcho/188.8.131.52pre
Maybe my memory is playing up and maybe this problem was already present in previous versions. I do recall testing this FTP server when I set it up a few months ago with a browser, and since I always use Firefox I assumed it must have been an older version of Firefox. Perhaps I was mistaken and I tested it with Internet Explorer. In any case, the problem is there, and as you can see other browsers work fine with the mentioned URL and Firefox does not. Cheers,
Comment on attachment 365646 [details] [diff] [review] patch v1 this is fine. i have been running a bit seams to not cause any problems.
6 years ago