Linode Forum
https://forum.linode.com/

SFTP Jails Not Working Correctly Under Ubuntu 10.04
https://forum.linode.com/viewtopic.php?f=19&t=8345
Page 1 of 1

Author:  davidlougheed [ Tue Jan 24, 2012 9:57 pm ]
Post subject:  SFTP Jails Not Working Correctly Under Ubuntu 10.04

I am trying to create a filetransfer group with several users under it, and successfully do so. However, whenever I enable

Code:
Match group filetransfer
       ChrootDirectory %h
       X11Forwarding no
       AllowTcpForwarding yes
       ForceCommand internal-sftp


and try to connect with FileZilla, it spits out this error:

Quote:
Error: Connection reset by peer
Error: Could not connect to server


Is there any reason that it should block me, or is it a problem with FileZilla?[/quote][/code]

Author:  sweh [ Tue Jan 24, 2012 10:51 pm ]
Post subject: 

Run the daemon in debug mode, possibly on a different port, and then try to ssh as a test user on that port.

eg
Code:
/usr/sbin/sshd -ddd -p 2222


And then in another window
Code:
ssh testuser@localhost -p 2222


You should see the reason for the error

Author:  sweh [ Tue Jan 24, 2012 11:00 pm ]
Post subject: 

PS: http://www.debian-administration.org/articles/590 might help

Author:  theckman [ Tue Jan 24, 2012 11:03 pm ]
Post subject:  Re: SFTP Jails Not Working Correctly Under Ubuntu 10.04

Are you folder/file permissions correct? Can you provide the output of the following commands:

ls -lA /home
ls -lA /home/<jailed_user>

-Tim

Author:  davidlougheed [ Fri Jan 27, 2012 2:52 pm ]
Post subject:  Solved It.

Thanks sweh, I ran it in debug mode and my permissions were screwed up. :D

Page 1 of 1 All times are UTC-04:00
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/