From 1535a5531635cd34b6db831fcdc605eed59a2edc Mon Sep 17 00:00:00 2001 From: Ludwig Mey Date: Sun, 7 Dec 2025 14:19:51 +1300 Subject: [PATCH] Adding notes about ssh key generation --- SSH/keygen.md | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 SSH/keygen.md diff --git a/SSH/keygen.md b/SSH/keygen.md new file mode 100644 index 0000000..74df95b --- /dev/null +++ b/SSH/keygen.md @@ -0,0 +1,41 @@ +**SSH Key Gen** +After a fresh install we want to generate an SSH key pair (public and private) +we can then use this key to ssh onto hosts without having to share passwords. + +On the new host + +``` +ssh-keygen -t ecdsa +``` + +you could add a -C for comment and then add your emaiul address but... meh + + +Example + +``` +~$ ssh-keygen -t ecdsa +Generating public/private ecdsa key pair. +Enter file in which to save the key (/home/luddie/.ssh/id_ecdsa): +Created directory '/home/luddie/.ssh'. +Enter passphrase for "/home/luddie/.ssh/id_ecdsa" (empty for no passphrase): +Enter same passphrase again: +Your identification has been saved in /home/luddie/.ssh/id_ecdsa +Your public key has been saved in /home/luddie/.ssh/id_ecdsa.pub +The key fingerprint is: +SHA256:gA+5oVKPdtlG7JQC5pL3NQ+OokUK7WoosTevWBCd1E0 luddie@debian-base +The key's randomart image is: ++---[ECDSA 256]---+ +| +. oE | +| B o.+.. | +|= 1 * X | +|.O = / = | +|B = B * S | +|.X o . | +|*.+ | +|o+ o | +|. ... | ++----[SHA256]-----+ +~$ + +``` \ No newline at end of file