I need to create a safe environment for a foreign SSH user that has to have very restricted access to our server. That is:
I have tried using chroot jail before using the jailkit tool for a smaller project that did not need as much customization and it worked fine, but this project is much bigger and requires a lot more customization in terms of allowed software and commands.
The requirements for the safe environment are:
I have heard about multistrap or debootstrap but I am not sure whether these are adequate tools for solving my problem.
The servers are running on Debian OS v. 9 and 10. All the required software is installed in the root filesystem and is running fine. All I need is for the restricted user to be able to utilize it without being able to damage/corrupt the root filesystem.
My questions are:
In case somebody is facing the same problem. I solved it using Docker container with separate SSH server and all required software installed on it.