sftp chroot_safe

Martin Nordin martin.nordin at gmail.com
Mon Dec 4 22:52:55 UTC 2006

On 12/3/06, Adam Ronthal <aronthal at fugue.net> wrote:
> Hi,
> You need to create the /dev/null device in each user's home directory... e.g.:
> mknod /dev/null c 2 2
> The sftp server requires access to /dev/null starting in more recent
> releases, and the chroot_safe script does not provide it that access.
> Hope this helps!
> -Adam

Thanks Adam, now it works beautifully.

I did have to add #!/bin/sh to the top of sftp-server-chroot script in
order for it to work.

This may have been implicitly obvious to all previous readers of the
how-to, however I thought it would execute by some magic thingie
behind the scenes, or maybe I just didn't think.

Maybe someone with an account on crux.nu could update the script with
#!/bin/sh and add a note about the /dev/null creation for the benefit
of future dummies like myself.

Best Regards,

More information about the CRUX mailing list