FTP(s) has bug with GetList(string path) function when the folder is can not access

0 votes
asked Sep 29, 2017 by lanopk (1,620 points)


  1. Connect Linux Ftp Server(vsftpd) with normal user account.
  2. GetList("/root") : root permission is "drwx------".
  3. Returned list has 1 child item without error and name is "root".
    : /root folder has 2 files('.bashrc' and '.profile')

I thinks in this case, GetList("/root") has to return empty list or raise exception.

When I did calls ChangeDirectory("/root") and GetList(), ChangeDirectory function raise exception 550. (this is correct action).

Sorry my short English.
Thank you.

Applies to: Rebex FTP/SSL

1 Answer

0 votes
answered Oct 2, 2017 by stepantalalayev (3,940 points)
selected Oct 2, 2017 by lanopk
Best answer


The problem is that different FTP servers interpreting the same GetList(string) argument differently. Some servers interpret it strictly as path, while others (such as vsftpd) treat it as path and filter.

The recommended approach is to use ChangeDirectory method followed by the argument-less variant of GetList method (which does not work in this case due to insufficient permissions).