|
I'm not sure whether it will satisfy your exact need.
SSH Password Auth Tweak is kept as enabled itself .
I'm setting this for a particular user named "test" . Set the user's shell to:
/usr/libexec/openssh/sftp-server ( give the correct path for sftp-server , wherever it is on the server)
You can do this by opening /etc/passwd and change the shell field to
/usr/libexec/openssh/sftp-server
It may look like
test:x:528:528::/home/test:/usr/libexec/openssh/sftp-server
2) Add /usr/libexec/openssh/sftp-server to /etc/shells
This will allow sftp and disable shell access to user test
But I haven't tried the SSH Private Key method .
|