Blame openssh-8.4p1-ssh-copy-id.patch
|
Jakub Jelen |
dc5e31 |
From 66f16e5425eb881570e82bfef7baeac2e7accc0a Mon Sep 17 00:00:00 2001
|
|
Jakub Jelen |
dc5e31 |
From: Oleg <Fallmay@users.noreply.github.com>
|
|
Jakub Jelen |
dc5e31 |
Date: Thu, 1 Oct 2020 12:09:08 +0300
|
|
Jakub Jelen |
dc5e31 |
Subject: [PATCH] Fix `EOF: command not found` error in ssh-copy-id
|
|
Jakub Jelen |
dc5e31 |
|
|
Jakub Jelen |
dc5e31 |
---
|
|
Jakub Jelen |
dc5e31 |
contrib/ssh-copy-id | 3 ++-
|
|
Jakub Jelen |
dc5e31 |
1 file changed, 2 insertions(+), 1 deletion(-)
|
|
Jakub Jelen |
dc5e31 |
|
|
Jakub Jelen |
dc5e31 |
diff --git a/contrib/ssh-copy-id b/contrib/ssh-copy-id
|
|
Jakub Jelen |
dc5e31 |
index 392f64f94..a76907717 100644
|
|
Jakub Jelen |
dc5e31 |
--- a/contrib/ssh-copy-id
|
|
Jakub Jelen |
dc5e31 |
+++ b/contrib/ssh-copy-id
|
|
Jakub Jelen |
dc5e31 |
@@ -247,7 +247,7 @@ installkeys_sh() {
|
|
Jakub Jelen |
dc5e31 |
# the -z `tail ...` checks for a trailing newline. The echo adds one if was missing
|
|
Jakub Jelen |
dc5e31 |
# the cat adds the keys we're getting via STDIN
|
|
Jakub Jelen |
dc5e31 |
# and if available restorecon is used to restore the SELinux context
|
|
Jakub Jelen |
dc5e31 |
- INSTALLKEYS_SH=$(tr '\t\n' ' ' <<-EOF)
|
|
Jakub Jelen |
dc5e31 |
+ INSTALLKEYS_SH=$(tr '\t\n' ' ' <<-EOF
|
|
Jakub Jelen |
dc5e31 |
cd;
|
|
Jakub Jelen |
dc5e31 |
umask 077;
|
|
Jakub Jelen |
dc5e31 |
mkdir -p $(dirname "${AUTH_KEY_FILE}") &&
|
|
Jakub Jelen |
dc5e31 |
@@ -258,6 +258,7 @@ installkeys_sh() {
|
|
Jakub Jelen |
dc5e31 |
restorecon -F .ssh ${AUTH_KEY_FILE};
|
|
Jakub Jelen |
dc5e31 |
fi
|
|
Jakub Jelen |
dc5e31 |
EOF
|
|
Jakub Jelen |
dc5e31 |
+ )
|
|
Jakub Jelen |
dc5e31 |
|
|
Jakub Jelen |
dc5e31 |
# to defend against quirky remote shells: use 'exec sh -c' to get POSIX;
|
|
Jakub Jelen |
dc5e31 |
printf "exec sh -c '%s'" "${INSTALLKEYS_SH}"
|
|
Jakub Jelen |
dc5e31 |
|