Disable rm on sftp

Ben Lindstrom mouring at eviladmin.org
Thu Oct 25 03:56:38 EST 2012


On Oct 24, 2012, at 11:17 AM, Ahmad Zayed <az1fantastic at gmail.com> wrote:

> Dear Damien,
> Good day
> 
> Thanks for your reply
> 
> This is what I found, the modified version of sftp-server is working but
> the user I tried is configure under chroot environment and I am using the
> internal-sftp as force command.
> 
> Today I tried to find out where I can modify this so I can clean out do_rm
> & do_rmdir functions


The existing code change will work, but you need to recompile the sshd and run
that instead of the one that comes with the base OS.  As you are using internal-sftp
which takes that code and compiles it directly into the sshd.

- Ben


More information about the openssh-unix-dev mailing list