forked from samuel-p/server-security-wiki
Compare commits
No commits in common. "58bd8267da704fffa31a0675d985b38bce808704" and "95482b21c7a72a8715bc507b61a3c0fcf53d66c1" have entirely different histories.
58bd8267da
...
95482b21c7
1 changed files with 2 additions and 6 deletions
|
@ -12,11 +12,7 @@ Create a new key pair on your client:
|
|||
ssh-keygen -b 4096
|
||||
```
|
||||
|
||||
Remember the path and password you choosed. Append the created public key from `/<your-path>/<key-name>.pub` on your client in the `/home/<user>/.ssh/authorized_keys` on your server. Alternatively you can use the command `ssh-copy-id` on your local client. For this command you can do the following:
|
||||
|
||||
```bash
|
||||
ssh-copy-id -i /<your-path>/<key-name>.pub user@host
|
||||
```
|
||||
Remember the path and password you choosed. Append the created public key from `/<your-path>/<key-name>.pub` on your client in the `/home/<user>/.ssh/authorized_keys` on your server.
|
||||
|
||||
Now edit `/etc/ssh/sshd_config` on your server and set the following values:
|
||||
|
||||
|
@ -38,4 +34,4 @@ Host <your-host-or-ip>
|
|||
|
||||
## Apply Changes
|
||||
|
||||
To apply changes you made in the ssh config simply run `systemctl restart ssh.service` or `service ssh restart`.
|
||||
To apply changes you made in the ssh config simply run `systemctl restart ssh.service` or `service ssh restart`.
|
Loading…
Reference in a new issue