Skip to main content
added 567 characters in body
Source Link
frlan
  • 746
  • 10
  • 28

I'm looking for a way to run a opensshd offering sftp to users as a unprivileged user e.g. on port 8022. This opensshd should take something like a customer passwd file which can include information like username, password etc and put all into per user dedicated folders inside a common root directory. How could this be achieved if possible at all with opensshd?

To make it more clear I need to have:

  • opensshd running under a non-root user on some port >1024 with a custom sshd-config file
  • possibility to define users for openssh that are not system users of current system provided by e.g. a local text file and ideal without PAM interaction
  • some kind of changeroot for this users so user1 is not able to access data of user2 during up- and download.

I have found some examples defining a chroot for openssh, but not supporting virtual users without PAM. Now I'm wondering whether it's possible at all.

I'm looking for a way to run a opensshd offering sftp to users as a unprivileged user e.g. on port 8022. This opensshd should take something like a customer passwd file which can include information like username, password etc and put all into per user dedicated folders inside a common root directory. How could this be achieved if possible at all with opensshd?

I'm looking for a way to run a opensshd offering sftp to users as a unprivileged user e.g. on port 8022. This opensshd should take something like a customer passwd file which can include information like username, password etc and put all into per user dedicated folders inside a common root directory. How could this be achieved if possible at all with opensshd?

To make it more clear I need to have:

  • opensshd running under a non-root user on some port >1024 with a custom sshd-config file
  • possibility to define users for openssh that are not system users of current system provided by e.g. a local text file and ideal without PAM interaction
  • some kind of changeroot for this users so user1 is not able to access data of user2 during up- and download.

I have found some examples defining a chroot for openssh, but not supporting virtual users without PAM. Now I'm wondering whether it's possible at all.

Source Link
frlan
  • 746
  • 10
  • 28

openssh with virtual users and chroot

I'm looking for a way to run a opensshd offering sftp to users as a unprivileged user e.g. on port 8022. This opensshd should take something like a customer passwd file which can include information like username, password etc and put all into per user dedicated folders inside a common root directory. How could this be achieved if possible at all with opensshd?