Advanced

How to: Restrict Users to SCP and SFTP and Block SSH Shell Access with rssh

Posted by nixcraft on · 1 comment
nixCraft; By nixCraft
Mail this story
Print this story

FTP is an insecure protocol, but file-transfer is required all the time. You can use OpenSSH Server to transfer files using SCP and SFTP (secure ftp) without setting up an FTP server. However, this feature also grants ssh shell access to a user. In this article series we will help you provide secure restricted file-transfer services to your users without resorting to http://FTP. It also covers chroot jail setup instructions to lock down users to their own home directories (allow users to transfer files but not browse the entire Linux / UNIX file system of the server) as well as per user configurations.

Full Story

  Nav
» Read more about: Story Type: Tutorial; Groups: Fedora, Linux, Red Hat

» Get new stories by e-mail: nightly or as they are published

« Return to the newswire homepage

  Related stories
» More like this

Comments (1)

I need to restrict users on Solaris.

I've found a solution but it's slightly clunky. I just put no-pty on their key in ~/.ssh/authorized_keys but it doesn't keep them from sftping down authorized_keys, editing it and sending it back. Maybe I can chmod it 400 - oh darn, they can chmod in the interactive commands for sftp. I tried a command=/some/shell/script but it failed to start up the sftp subsystem for normal use of their key.

Post a comment

A free account is needed to post. Write your comment here first: your text is kept in this browser while you sign up or log in, and is waiting for you when you come back.

Your message:
|||||
10
Markdown: **bold**, *italic*, [text](https://link), - lists, > quotes, $x^2$ for math. Formatting help

Sign up and post (it is free)  or  Log in and post