summaryrefslogtreecommitdiff
path: root/debian/patches
diff options
context:
space:
mode:
authorColin Watson <cjwatson@debian.org>2020-12-02 10:30:09 +0000
committerColin Watson <cjwatson@debian.org>2020-12-02 10:30:09 +0000
commitc5a2f2861869c72530dc1a937e3add42957d2d11 (patch)
tree978146859edda762a1eec05f2812e7f795d939bb /debian/patches
parent6c4fd5458b0debff89651106911834a7f08278dd (diff)
parent27cf2f667b46a99f4469f41bcb8e004834a3d34f (diff)
Fix `EOF: command not found` error in ssh-copy-id
Closes: #975540
Diffstat (limited to 'debian/patches')
-rw-r--r--debian/patches/series1
-rw-r--r--debian/patches/ssh-copy-id-heredoc-syntax.patch37
2 files changed, 38 insertions, 0 deletions
diff --git a/debian/patches/series b/debian/patches/series
index 56019a479..5b00428bc 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -24,3 +24,4 @@ restore-authorized_keys2.patch
24conch-old-privkey-format.patch 24conch-old-privkey-format.patch
25revert-ipqos-defaults.patch 25revert-ipqos-defaults.patch
26revert-x32-sandbox-breakage.patch 26revert-x32-sandbox-breakage.patch
27ssh-copy-id-heredoc-syntax.patch
diff --git a/debian/patches/ssh-copy-id-heredoc-syntax.patch b/debian/patches/ssh-copy-id-heredoc-syntax.patch
new file mode 100644
index 000000000..e0259670a
--- /dev/null
+++ b/debian/patches/ssh-copy-id-heredoc-syntax.patch
@@ -0,0 +1,37 @@
1From 27cf2f667b46a99f4469f41bcb8e004834a3d34f Mon Sep 17 00:00:00 2001
2From: Oleg <Fallmay@users.noreply.github.com>
3Date: Thu, 1 Oct 2020 12:09:08 +0300
4Subject: Fix `EOF: command not found` error in ssh-copy-id
5
6Origin: upstream, https://anongit.mindrot.org/openssh.git/commit/?id=d9e727dcc04a52caaac87543ea1d230e9e6b5604
7Bug: https://github.com/openssh/openssh-portable/pull/206
8Bug-Debian: https://bugs.debian.org/975540
9Bug-Debian: https://bugs.debian.org/976242
10Last-Update: 2020-12-02
11
12Patch-Name: ssh-copy-id-heredoc-syntax.patch
13---
14 contrib/ssh-copy-id | 3 ++-
15 1 file changed, 2 insertions(+), 1 deletion(-)
16
17diff --git a/contrib/ssh-copy-id b/contrib/ssh-copy-id
18index 392f64f94..a76907717 100644
19--- a/contrib/ssh-copy-id
20+++ b/contrib/ssh-copy-id
21@@ -247,7 +247,7 @@ installkeys_sh() {
22 # the -z `tail ...` checks for a trailing newline. The echo adds one if was missing
23 # the cat adds the keys we're getting via STDIN
24 # and if available restorecon is used to restore the SELinux context
25- INSTALLKEYS_SH=$(tr '\t\n' ' ' <<-EOF)
26+ INSTALLKEYS_SH=$(tr '\t\n' ' ' <<-EOF
27 cd;
28 umask 077;
29 mkdir -p $(dirname "${AUTH_KEY_FILE}") &&
30@@ -258,6 +258,7 @@ installkeys_sh() {
31 restorecon -F .ssh ${AUTH_KEY_FILE};
32 fi
33 EOF
34+ )
35
36 # to defend against quirky remote shells: use 'exec sh -c' to get POSIX;
37 printf "exec sh -c '%s'" "${INSTALLKEYS_SH}"