mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
From: Clemens Gruber <clemens.gruber@pqgruber.com>
To: ptxdist@pengutronix.de
Cc: Clemens Gruber <clemens.gruber@pqgruber.com>
Subject: [ptxdist] [PATCH 1/3] openssh: Generate Ed25519 keys instead of DSA keys
Date: Tue,  9 Jun 2015 18:57:52 +0200	[thread overview]
Message-ID: <1433869074-26365-2-git-send-email-clemens.gruber@pqgruber.com> (raw)
In-Reply-To: <1433869074-26365-1-git-send-email-clemens.gruber@pqgruber.com>

As it is very likely that weak DSA and ECDSA keys are created on
embedded systems (entropy problems), I suggest replacing DSA with
Ed25519, a elliptic curve signature scheme which was designed with
those problems in mind. Having not enough entropy is not that
critical with Ed25519 as it was with DSA or ECDSA.

Besides being more secure than DSA, its performance is better too.

More info on Ed25519: http://ed25519.cr.yp.to

Signed-off-by: Clemens Gruber <clemens.gruber@pqgruber.com>
---
 generic/etc/rc.once.d/openssh | 8 ++++----
 generic/etc/ssh/sshd_config   | 2 +-
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/generic/etc/rc.once.d/openssh b/generic/etc/rc.once.d/openssh
index 83e6e37..0a63433 100644
--- a/generic/etc/rc.once.d/openssh
+++ b/generic/etc/rc.once.d/openssh
@@ -3,12 +3,12 @@
 PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
 
 OPENSSH_RSAKEY_DEFAULT="/etc/ssh/ssh_host_rsa_key"
-OPENSSH_DSAKEY_DEFAULT="/etc/ssh/ssh_host_dsa_key"
+OPENSSH_ED25519KEY_DEFAULT="/etc/ssh/ssh_host_ed25519_key"
 
 test -n "$OPENSSH_RSAKEY" || \
 	OPENSSH_RSAKEY=$OPENSSH_RSAKEY_DEFAULT
-test -n "$OPENSSH_DSAKEY" || \
-	OPENSSH_DSAKEY=$OPENSSH_DSAKEY_DEFAULT
+test -n "$OPENSSH_ED25519KEY" || \
+	OPENSSH_ED25519KEY=$OPENSSH_ED25519KEY_DEFAULT
 
 gen_key() {
 
@@ -29,5 +29,5 @@ gen_key() {
 }
 
 gen_key rsa "$OPENSSH_RSAKEY"
-gen_key dsa "$OPENSSH_DSAKEY"
+gen_key ed25519 "$OPENSSH_ED25519KEY"
 
diff --git a/generic/etc/ssh/sshd_config b/generic/etc/ssh/sshd_config
index 7cd7897..f529fc4 100644
--- a/generic/etc/ssh/sshd_config
+++ b/generic/etc/ssh/sshd_config
@@ -20,7 +20,7 @@ Protocol 2
 #HostKey /etc/ssh/ssh_host_key
 # HostKeys for protocol version 2
 HostKey /etc/ssh/ssh_host_rsa_key
-HostKey /etc/ssh/ssh_host_dsa_key
+HostKey /etc/ssh/ssh_host_ed25519_key
 
 # Lifetime and size of ephemeral version 1 server key
 #KeyRegenerationInterval 1h
-- 
2.4.2


-- 
ptxdist mailing list
ptxdist@pengutronix.de

  reply	other threads:[~2015-06-09 16:58 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-09 16:57 [ptxdist] [PATCH 0/3] OpenSSH improvements Clemens Gruber
2015-06-09 16:57 ` Clemens Gruber [this message]
2015-06-09 16:57 ` [ptxdist] [PATCH 2/3] openssh: Enable pre-auth sandboxing Clemens Gruber
2015-06-09 16:57 ` [ptxdist] [PATCH 3/3] openssh: Bump to current stable version 6.8p1 Clemens Gruber

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1433869074-26365-2-git-send-email-clemens.gruber@pqgruber.com \
    --to=clemens.gruber@pqgruber.com \
    --cc=ptxdist@pengutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox