Jul 16, 2016
5
1
3
At home
cPanel Access Level
Website Owner
I canceled the ability to login via SSH on my server with CPanel. So when I try to login to SSH (to see if it's working) I get this message:

"Disconnected : No supported authentication methods available (server sent :publickey)."

Then an alert message comes up with a public key. It scared me so I canceled blocking SSH login immediately. My question: why is a public key sent? And can anyone then login into my server using that key? That seems counter intuitive to what I was trying to accomplish by blocking being able to login with SSH. Thanks for any help with this.
 

cPanelLauren

Product Owner II
Staff member
Nov 14, 2017
13,266
1,300
363
Houston
The server sent the public key because you had key authentication enabled at some point but the message "No supported authentication methods available" means you cannot connect via SSH. No one can use the publickey for that user without the associated privatekey and even then you would not be able to login.
 
Jul 16, 2016
5
1
3
At home
cPanel Access Level
Website Owner
Thanks for your reply, Lauren. I unauthorized the key and I still get the alert message with a public key. If no one is allowed to login it's OK. That's all I care about. Thanks for your help.
 

cPanelLauren

Product Owner II
Staff member
Nov 14, 2017
13,266
1,300
363
Houston
No problem! I understand it's just because it still exists and publickey authentication is enabled in the SSH config - but that doesn't mean that users without shell access will be allowed to login, nor does it mean that the key is still valid.
 

malban

Registered
Jun 18, 2005
1
0
151
In WHM goto Security Center option SSH Password Authorization Tweak and click Enable Password Auth.

In case someone else has this same problem