Personal tools

Log in

Changes

From IGEP - ISEE Wiki

Jump to: navigation, search

Configure SSH Key-Based Authentication

116 bytes removed, 22:28, 29 October 2017
Disabling Password Authentication on your Server
Once the above conditions are true, log into your remote server with SSH keys, either as root or with an account with <code>sudo</code> privileges. Open the SSH daemon's configuration file:
<pre class="code-pre "><code>sudo nano /etc/ssh/sshd_config</code></pre>
Inside the file, search for a directive called <code>PasswordAuthentication</code>. This may be commented out. Uncomment the line and set the value to "no". This will disable your ability to log in through SSH using account passwords:
<pre class="code-pre "><code>PasswordAuthentication no</code></pre>
Save and close the file when you are finished. To actually implement the changes we just made, you must restart the service.
On Ubuntu or Debian machines, you can issue this command:
<pre class="code-pre "><code>sudo service ssh restart</code></pre>
On CentOS/Fedora machines, the daemon is called <code>sshd</code>:
<pre class="code-pre "><code>sudo service sshd restart</code></pre>
After completing this step, you've successfully transitioned your SSH daemon to only respond to SSH keys.
[https://www.digitalocean.com/community/tutorials/ssh-essentials-working-with-ssh-servers-clients-and-keys More Information]