3 ms·
Just curious, why would symlinks not work here? That's traditionally how this sort of thing was done, even on Linux. Is it a chroot issue? Interestingly, OpenB
by wahern 2y ago
Just curious, why would symlinks not work here? That's traditionally how this sort of thing was done, even on Linux.
Is it a chroot issue? Interestingly, OpenBSD services seem to be moving away from chroot now that it has unveil. (Not that that would help you here and now.)
- serbuvlad 2y ago> Is it a chroot issue? Yes. In my particular case I was setting up a server for some non-technical users to share files with me via FileZilla. So I use ChrootDirectory %h to restrict users to their home directory. Even if it wouldn't be a security issue to omit this, my users would be confused by seeing the whole /usr, /bin, /var etc. directory hierarchy show up in FileZilla. And even if they could learn their way around it, I don't want them to see the whole directory hierarchy. I just want them to see their own files. Granted, this could be solved by symlinks if SFTP provided a way other than chroot to change the user-perceived home directory. But the fact that mount --bind works across filesystem namespace changes makes it more robust and useful in my book.