[wp-trac] [WordPress Trac] #21610: ssh2/sftp doesn't work with chrooted/openssh sftp-internal user accounts (no shell)

WordPress Trac wp-trac at lists.automattic.com
Thu Aug 16 16:06:35 UTC 2012


#21610: ssh2/sftp doesn't work with chrooted/openssh sftp-internal user accounts
(no shell)
-----------------------------------+-----------------------------------
 Reporter:  albert@…               |      Owner:  albert@…
     Type:  defect (bug)           |     Status:  new
 Priority:  normal                 |  Milestone:  Awaiting Review
Component:  Filesystem             |    Version:  3.4.1
 Severity:  normal                 |   Keywords:  has-patch
-----------------------------------+-----------------------------------
 The current wordpress 3.4.1 wp-admin/includes/class-wp-filesystem-ssh2.php
 code will crash php or spin in an endless loop when someone supplies
 ssh/sftp credentials (username/password) to an (open)ssh server where
 users don't have a shell and are chrooted to their home directory e.g. by
 using openssh's sftp-internal server and ChrootDirectory functionality.
 There is no neat fix for the code in the WP_Filesystem_SSH2 class. I've
 implemented a new WP_Filesystem_SFTP class making use of the portable
 phpseclib library.

 At this moment it is necessary to change a line in wp-
 admin/includes/file.php to be able to use WP_Filesystem_SFTP.
 Attached is the code for this new class up for review or for anyone with
 the same problem.

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


More information about the wp-trac mailing list