Hier werden die Unterschiede zwischen zwei Versionen der Seite angezeigt.
| Beide Seiten, vorherige ÜberarbeitungVorherige ÜberarbeitungNächste Überarbeitung | Vorherige Überarbeitung | ||
| knowledge_base:linux:ssh [2023/01/29 18:20] – ↷ Links angepasst weil Seiten im Wiki verschoben wurden julian.lemmerich | knowledge_base:linux:ssh [2024/11/04 22:49] (aktuell) – add 1Password Agent link julian.lemmerich | ||
|---|---|---|---|
| Zeile 1: | Zeile 1: | ||
| ====== SSH ====== | ====== SSH ====== | ||
| - | ===== debian | + | ===== Debian |
| - | from [[https:// | + | === Recommended config === |
| - | <file bash / | + | <code bash> |
| - | PermitRootLogin yes | + | mkdir ~/.ssh |
| + | cd ~/.ssh | ||
| + | wget https:// | ||
| + | </ | ||
| + | |||
| + | <file . / | ||
| + | Port 22 | ||
| + | #Port 22222 | ||
| + | |||
| + | PermitRootLogin | ||
| + | |||
| + | PasswordAuthentication no | ||
| + | ChallengeResponseAuthentication no | ||
| + | |||
| + | #Match Address 10.0.0.0/ | ||
| + | # PasswordAuthentication | ||
| </ | </ | ||
| <code bash> | <code bash> | ||
| - | /etc/init.d/ssh restart | + | echo " |
| </ | </ | ||
| - | ===== add Pubkey to server ===== | + | === allow root pw login === |
| + | |||
| + | from [[https:// | ||
| + | |||
| + | <file bash / | ||
| + | PermitRootLogin yes | ||
| + | </ | ||
| + | |||
| + | === Pubkeyauth | ||
| from [[https:// | from [[https:// | ||
| Zeile 27: | Zeile 50: | ||
| password has to be explicitely disabled | password has to be explicitely disabled | ||
| + | |||
| + | === SSH-Agent === | ||
| + | |||
| + | To not have to reauth ssh key all the time use ssh-agent: | ||
| + | |||
| + | < | ||
| + | eval `ssh-agent` | ||
| + | ssh-add ~/ | ||
| + | </ | ||
| ===== See also ===== | ===== See also ===== | ||
| - | [[knowledge_base: | + | * [[https:// |
| + | * [[https:// | ||
| + | * [[knowledge_base: | ||
| + | * [[knowledge_base: | ||