Cannot show/delete hidden files or delete folders that contains hidden files on FTP

Bug #217975 reported by Dennis Heinson
32
Affects Status Importance Assigned to Milestone
gvfs
Fix Released
High
gvfs (Ubuntu)
Fix Released
Low
Ubuntu Desktop Bugs

Bug Description

Binary package hint: gvfs

Description: Hidden files do not show on FTP, even if "Show hidden files" is activated under /View in Nautilus.

gvfs:
  Installed: 0.2.3-0ubuntu2
  Candidate: 0.2.3-0ubuntu2
  Version table:
 *** 0.2.3-0ubuntu2 0

Update : invalid bug 211748 describes the same bug. This bug is caused by FTP servers which hides files. A FTP client like FileZilla has "Server / Force showing hidden files" option to show hidden files while nautilus has "View / Show hidden files". We could probably expect it to use the FTP standard "LIST -a" command to show hidden files when this option is checked and to ignore errors from servers that does not implement this correctly.

description: updated
description: updated
Revision history for this message
Saivann Carignan (oxmosys) wrote :

I confirm that this bug happens with up to date gvfs in Hardy.

Steps to reproduce :

1. Have a FTP server sharing a folder that contains a file with a filename that starts with a dot (.). Ex. ftp://127.0.0.1/myfolder/.file
2. Open that FTP share through nautilus and open the folder.
(result) nautilus does not show any files
3. Click on "View" and "Show hiddens files" to show files with filenames that starts with a dot (.).
(result) nautilus does not show any files, but now it should.
4. go back to the root of the FTP server and try to delete the folder.
(result) nautilus finally gives a error and is not able to delete the folder.
5. Login into the FTP server with a FTP client like filezilla and delete the file that starts with a dot from the folder.
6. Try to delete the folder with nautilus again.
(result) the folder is now deleted, properly.

Changed in gvfs:
importance: Undecided → Low
status: New → Confirmed
Changed in gvfs:
importance: Low → Medium
description: updated
description: updated
Changed in gvfs:
status: Confirmed → Triaged
description: updated
Changed in gvfs:
importance: Medium → Low
Revision history for this message
Saivann Carignan (oxmosys) wrote :

This bug can be tested on this server :

ftp://leservicetechnique.com/
username : "username"
password : "nothing"

Changed in gvfs:
assignee: nobody → desktop-bugs
Changed in gvfs:
status: Unknown → New
Revision history for this message
Richard Fairthorne (richard-fairthorne) wrote :

richard@lappy886:~/.gvfs/[...]/vfstest$ >htaccess
richard@lappy886:~/.gvfs/[...]/vfstest$ mv htaccess .htaccess
richard@lappy886:~/.gvfs/[...]/vfstest$ cat .htaccess
cat: .htaccess: No such file or directory

I'm struggling to do basic web work using gvfs and vim. I routinely reboot into windows, or use another FTP program. 'ls -a' should be the default behavior with any webserver that will accept it.

Revision history for this message
Tim Kosse (tim-kosse) wrote :

> We could probably expect it to use the FTP standard "LIST -a" command to show hidden files

"LIST -a" is not standard, it is nowhere mentioned in RFC 959 or any other RFC relevant for FTP. In fact, there are many servers which interpret "LIST -a" as "list the file or the contents of the directory named "-a".

A server not showing all files with LIST relies on nonstandard behavior and is essentially broken.

Revision history for this message
Saivann Carignan (oxmosys) wrote :

Tim Kosse : Then, is there a way for nautilus to verify if the server support LIST -a? If there is a command that asks the server for supported command, nautilus could verify is LIST -a is supported before using it.

Revision history for this message
Tim Kosse (tim-kosse) wrote :

No. Since "LIST -a" is not standardized, a corresponding line for the FEAT reply isn't standardized either.

You could use heuristics to test for LIST -a support (e.g. list same directory twice, first with LIST then with LIST -a and check that the second listing is a superset of the first). But as with all heuristics, they can result in failures. In the worst case, the heuristic reports support for LIST -a on a server not supporting it, causing further problems.

The only fool-proof solution is to contact the server administrator so that he can properly configure the server or alternatively install a better one.

If you really want to use LIST -a, use a heuristic and make it so that the user has to explicitly enable it, together with a big warning explaining the problem.

Remark: Some servers, e.g. vsftpd, rely on unspecified LIST -a support. force_dot_files=YES should be added to the default configuration so that no new server installations use this broken behavior.

Changed in gvfs:
status: New → Fix Released
Revision history for this message
Sebastien Bacher (seb128) wrote :

the bug has been fixed in jaunty

Changed in gvfs:
status: Triaged → Fix Released
Revision history for this message
Saivann Carignan (oxmosys) wrote :

I confirm, it is fixed

Changed in gvfs:
importance: Unknown → High
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.