commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Geoff Watters <geoff.watt...@oracle.com>
Subject [vfs] implementation requires List privilege on the remote directory structure
Date Wed, 21 Aug 2013 10:38:18 GMT
I am writing an application that uses VFS to implement the FTP operations.

I have found that the VFS implementation (commons-vfs2-2.0.jar)) relies 
on the List permission on the remote directory structure.

For example, if I am FTPing a file to a remote dir "uploads", then on 
the remote system, the <ftpUserHome> that already contains a 
subdirectory called "uploads", does require List privilege. This is 
targeting FileZilla Server (0.9.41 beta) on Windows 7.

If List privilege is not granted then the following exception is raised:-
Caused by: org.apache.commons.vfs2.FileSystemException: Could not create 
folder "ftp://myLaptop/upload".
     at 
org.apache.commons.vfs2.provider.AbstractFileObject.createFolder(AbstractFileObject.java:999)
     at 
org.apache.commons.vfs2.provider.AbstractFileObject.getOutputStream(AbstractFileObject.java:1424)
     at 
org.apache.commons.vfs2.provider.DefaultFileContent.getOutputStream(DefaultFileContent.java:461)
     at 
org.apache.commons.vfs2.provider.DefaultFileContent.getOutputStream(DefaultFileContent.java:441)
     at org.apache.commons.vfs2.FileUtil.copyContent(FileUtil.java:111)
     at 
org.apache.commons.vfs2.provider.AbstractFileObject.copyFrom(AbstractFileObject.java:1053)
     ... 24 more
Caused by: org.apache.commons.vfs2.FileSystemException: Could not create 
FTP directory "ftp://myLaptop/upload".
     at 
org.apache.commons.vfs2.provider.ftp.FtpFileObject.doCreateFolder(FtpFileObject.java:544)
     at 
org.apache.commons.vfs2.provider.AbstractFileObject.createFolder(AbstractFileObject.java:988)

If the remote file does exist, then the exception is not raised even 
when List privilege is not granted to the <ftpUserHome> directory.

List privilege is not needed when using a command-line FTP client.

Is this a known issue or restriction?

Thanks in advance


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@commons.apache.org
For additional commands, e-mail: user-help@commons.apache.org


Mime
View raw message