summaryrefslogtreecommitdiff
path: root/doc/note/ssh/ssh-setup.txt
diff options
context:
space:
mode:
authorAndreas Fankhauser hiddenalpha.ch2024-05-12 12:55:07 +0200
committerAndreas Fankhauser hiddenalpha.ch2024-05-12 12:55:07 +0200
commit5cc4c2b95df9bf6998d92496ca0e0064314fba39 (patch)
treeac7d979f81a86703508ff23e2694a6b4d6bfe4d5 /doc/note/ssh/ssh-setup.txt
parent1dc9f8c9db499a326ceee6cb3b48878ee17ff9fa (diff)
parent95d934e8e3918832c03f05b2fc32cb5d5272cb83 (diff)
downloadUnspecifiedGarbage-5cc4c2b95df9bf6998d92496ca0e0064314fba39.zip
UnspecifiedGarbage-5cc4c2b95df9bf6998d92496ca0e0064314fba39.tar.gz
Merge remote-tracking branch 'ha-public/master' into wip-LatitudeReSetup-20230620wip-LatitudeReSetup-20230620
Diffstat (limited to 'doc/note/ssh/ssh-setup.txt')
-rw-r--r--doc/note/ssh/ssh-setup.txt12
1 files changed, 12 insertions, 0 deletions
diff --git a/doc/note/ssh/ssh-setup.txt b/doc/note/ssh/ssh-setup.txt
index 6a2812b..9f3dde2 100644
--- a/doc/note/ssh/ssh-setup.txt
+++ b/doc/note/ssh/ssh-setup.txt
@@ -7,6 +7,7 @@ SSH Setup & Key Management
- [Insane answer about key formats](https://stackoverflow.com/a/29707204/4415884)
+
## Create New Ssh Key
Create "path/to/key" and "path/to/key.pub" as a 2048 bit RSA with
@@ -16,6 +17,13 @@ Create "path/to/key" and "path/to/key.pub" as a 2048 bit RSA with
ssh-keygen -t rsa -b 2048 -f path/to/key -C "your comment"
```
+Create "path/to/key" and "path/to/key.pub" as an elliptic curve.
+
+```sh
+ssh-keygen -t ed25519 -f path/to/key -C "your comment"
+```
+
+
## Change Passphrase
@@ -26,6 +34,7 @@ ssh-keygen -p -f path/to/key
NOTE: Just hitting enter when asked for the new one will remove the passphrase.
+
## Inspect keys
Print public key hash:
@@ -46,6 +55,7 @@ Print detailed DER file content:
openssl x509 -in dumpcertfile -inform DER -text
+
## Export pub key in misc formats
ssh-keygen -e -f path/to/ssh2pub-or-privKey -m PKCS8
@@ -62,11 +72,13 @@ TODO to PKCS8:
ssh-keygen -i -f path/to/key.pub -e -m PKCS8 > path/to/pub.pem
+
## Remove obsolete entry from known_hosts
ssh-keygen -f path/to/known_hosts -R "example.com"
+
## TODO
-e This option will read a private or public OpenSSH key file