Skip to content

Instantly share code, notes, and snippets.

@antelio
Created February 19, 2020 13:28
Show Gist options
  • Save antelio/99ae70f2a612a831f913d8c221864416 to your computer and use it in GitHub Desktop.
Save antelio/99ae70f2a612a831f913d8c221864416 to your computer and use it in GitHub Desktop.
sed -i "s/.*PasswordAuthentication.*/PasswordAuthentication no/g" /etc/ssh/sshd_config
service sshd restart
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment