[wp-trac] [WordPress Trac] #17846: WP_Filesystem_FTPext::dirlist() doesn't handle symbolic links properly

WordPress Trac wp-trac at lists.automattic.com
Sun Jun 19 20:29:01 UTC 2011


#17846: WP_Filesystem_FTPext::dirlist() doesn't handle symbolic links properly
--------------------------+-----------------------------
 Reporter:  Oded          |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  Filesystem    |    Version:
 Severity:  normal        |   Keywords:
--------------------------+-----------------------------
 When listing files using WP_Filesystem_FTPext::dirlist() and encountering
 symbolic linux on a Unix FTP server, dirlist() returns the "file name" as
 a symbolic link textual description such as shown by "ls -l", e.g.
 "linkname -> /absolute/path/to/file".

 It stands to reason as this is the expected format of the FTP LIST
 command, but users of dirlist() are getting a structure with full details
 and expect the value associated with the "name" key to contain only the
 name of the file (or the name of the link in this case).

 WP_Filesystem_FTPext should parse links properly in parselisting() and
 hide the extraneous data so as not to confuse users of dirlist() that
 expect specific file names, when the expected file name is a symbolic
 link.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/17846>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list