I configured login by SSH key which is working but I can still login by password, which I don't want.
I used sudo nano /etc/ssh/sshd_config
to make the following changes:
PasswordAuthentication noPubkeyAuthentication yes
I disabled the root login because my user can log in.
It should refuse login with password but it still allows it.
My version of ssh is OpenSSH_8.9p1 Ubuntu-3, OpenSSL 3.0.2 15 Mar 2022 on Ubuntu 22.04.
How do I disable the ability to login with password over SSH?