Ssh key login for users/resellers

Dendiestdennis

Verified User
Joined
Mar 9, 2016
Messages
21
I'trying to login with a reseller through ssh with an ssh-2 RSA key
I've put the public-key in (user)/.ssh/authorized_key and using the private key with putty. Everytime i try to log in i get the message "server refuses our key"
when i try the same ssh-2 RSA key on root account(with the public_key stored in /root/.ssh/authorized_key) i can login with no problems...:confused:

I also tried after changing the /etc/ssh/sshd_config removed the # in front of PubkeyAuthentication yes
and restarted the sshd service, but stil no luck....

(yes i know it is not recommended to give resellers ssh access:p)

Please some advice

Regards,
Dennis.
 
When i add a user with adduser -m and put the key in this users .ssh/authorized_keys it works also??(after you manualy put the user in the /etc/ssh/sshd_config ofcourse! )
 
Yes SSH option is enabled on the Modify Reseller tab, it is also possible to login with a password, but not with key pairs.
 
@Andrea,

The user successfully uses root account with SSH key. So it does not work only for reseller.
 
You can enable public key authentication in /etc/ssh/sshd_config:
Code:
PubkeyAuthentication yes
Next, generate a keypair using your SSH client and then just append the generated public key (in OpenSSH format) to <user>/.ssh/authorized_keys and restart sshd.
 
I don't get it to work with default sshd config (with PubkeyAuthentication enabled) , what do i have to change in the default config in /etc/ssh/sshd_config to get it to work?
 
Last edited:
Back
Top