Make WordPress Core

#57063 closed defect (bug) (duplicate)

WordPress 6.1, WP_Filesystem_FTPext breaks on the default FreeBSD FTPD server

Reported by: gamecreature's profile gamecreature Owned by:
Milestone: Priority: normal
Severity: normal Version: 6.1
Component: Filesystem API Keywords:
Focuses: Cc:


I update my WordPress installations via WP_Filesystem_FTPext .

The FTP server I use is the default FTPD deamon from FreeBSD 13.1.
Since the 6.1 update plugin installing doesn't work anymore. (It doesn't create the plugin directories)

The reason is that the method exists doesn't return the correct value anymore.
It always return true.

Reason is that the raw ls command returns a 'ftpd: /nonexisten/file: No such file or directory'

ftp> ls /nonexisten/file
229 Entering Extended Passive Mode (|||65185|)
150 Opening ASCII mode data connection for '/bin/ls'.
ftpd: /nonexisten/file: No such file or directory
226 Transfer complete.

The exist method checks if the empty method if the result is empty.

! empty( ftp_rawlist( $this->link, $path ) );

Which it never will because it contains the message ftpd: /nonexisten/file: No such file or directory

When I copy the 6.0 version of wp-admin/includes/class-wp-filesystem-ftpext.php it works again.

This issue is related to #56966

Change History (3)

#1 @costdev
14 months ago

  • Keywords reporter-feedback added

Hi @gamecreature, welcome back to Trac and thanks for opening this ticket!

The change to ::exists() was reverted in [54816] and released with WordPress 6.1.1.

Can you test this again and let us know if you still have this issue in WordPress 6.1.1? Thanks!

#2 @gamecreature
14 months ago

Hi @costdev, I can confirm this has been resolved in the 6.1.1 version.

#3 @costdev
14 months ago

  • Keywords reporter-feedback removed
  • Milestone Awaiting Review deleted
  • Resolution set to duplicate
  • Status changed from new to closed

Thanks @gamecreature!

Closing as a duplicate of #56966

Note: See TracTickets for help on using tickets.