diff options
author | Michael Olbrich <m.olbrich@pengutronix.de> | 2020-08-17 09:08:44 +0200 |
---|---|---|
committer | Michael Olbrich <m.olbrich@pengutronix.de> | 2020-08-17 10:05:21 +0200 |
commit | a2b1426f1a573ec4235394661f27f7d36308e7e5 (patch) | |
tree | 387212f64039a56c0518f8b633d0421f4e0c71ba /projectroot | |
parent | 6e227fbb5b951d910b228aa4f65ce085bb97d1ea (diff) | |
download | ptxdist-a2b1426f1a573ec4235394661f27f7d36308e7e5.tar.gz ptxdist-a2b1426f1a573ec4235394661f27f7d36308e7e5.tar.xz |
openssh: fix debug output in rc-once script
The variable $_type does not exist, so $prettykeytype is always empty.
And 'tr' may not be available. It's just the debug output, so use the
lowercase key type to avoid any problem.
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
Diffstat (limited to 'projectroot')
-rw-r--r-- | projectroot/etc/rc.once.d/openssh | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/projectroot/etc/rc.once.d/openssh b/projectroot/etc/rc.once.d/openssh index 66cfa06df..fe8b00691 100644 --- a/projectroot/etc/rc.once.d/openssh +++ b/projectroot/etc/rc.once.d/openssh @@ -19,7 +19,6 @@ host_keys_required() { create_key() { keytype="$1" - prettykeytype="$(echo $_type | tr a-z A-Z)" shift hostkeys="$1" shift @@ -27,10 +26,10 @@ create_key() { file="/etc/ssh/ssh_host_${keytype}_key" if echo "$hostkeys" | grep -x -F "$file" >/dev/null; then - echo "Create $prettykeytype key; this may take some time ..." + echo "Create $keytype key; this may take some time ..." rm -f $file && ssh-keygen -q -f "$file" -N '' -t "$keytype" "$@" || return - echo "Created $prettykeytype key." + echo "Created $keytype key." fi } |