I have problem during configuration of Cygwin sftp server on Windows Server.When I'm trying to change root directory of one user with Match User I got "Connection closed" after sftp to this server. SSH is working correctly I'm using key authentication.
> debug1: pledge: fork> debug2: channel_input_open_confirmation: channel 0: callback done> debug2: channel 0: open confirm rwindow 0 rmax 32768> debug2: channel 0: rcvd adjust 2097152> debug3: receive packet: type 99> debug2: channel_input_status_confirm: type 99 id 0> debug2: subsystem request accepted on channel 0> debug3: receive packet: type 96> debug2: channel 0: rcvd eof> debug2: channel 0: output open -> drain> debug2: channel 0: obuf empty> debug2: chan_shutdown_write: channel 0: (i0 o1 sock -1 wfd 6 efd 7 [write])> debug2: channel 0: output drain -> closed> Connection closed> debug2: channel 0: read failed rfd 5 maxlen 32768: Broken pipe> debug2: channel 0: read failed> debug2: chan_shutdown_read: channel 0: (i0 o3 sock -1 wfd 5 efd 7 [write])> debug2: channel 0: input open -> drain> debug3: receive packet: type 98> debug1: client_input_channel_req: channel 0 rtype exit-status reply 0> debug3: receive packet: type 98> debug1: client_input_channel_req: channel 0 rtype eow@openssh.com reply 0> debug2: channel 0: rcvd eow
When I don't have Match USer part of config all is good.My sshd_config is:
> Subsystem sftp internal-sftp> Match User testuser> ChrootDirectory /cygdrive/e/ftpserv
I have to changed default directory after log in to sftp server with pubkey. Maybe I should do something else?