From eefe27ae6647b1858c0200fdaa4ae58f6d182b7b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Arkadiusz=20Mi=C5=9Bkiewicz?= Date: Sat, 12 Nov 2011 10:43:14 +0000 Subject: [PATCH] - rel 7; when ipv6 sockets are allowed to be created (AF_INET6 is supported) sshd tries to bind to ::1, too which may be unavailable (for example in vserver guests or when net.ipv6.conf.all.disable_ipv6=1) - skip af family then Changed files: openssh-bind.patch -> 1.1 openssh.spec -> 1.379 --- openssh-bind.patch | 11 +++++++++++ openssh.spec | 4 +++- 2 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 openssh-bind.patch diff --git a/openssh-bind.patch b/openssh-bind.patch new file mode 100644 index 0000000..718caa6 --- /dev/null +++ b/openssh-bind.patch @@ -0,0 +1,11 @@ +--- openssh-5.9p1/channels.c~ 2011-06-23 00:31:57.000000000 +0200 ++++ openssh-5.9p1/channels.c 2011-11-12 11:37:15.242015675 +0100 +@@ -3301,6 +3301,8 @@ + if (bind(sock, ai->ai_addr, ai->ai_addrlen) < 0) { + debug2("bind port %d: %.100s", port, strerror(errno)); + close(sock); ++ if (errno == EADDRNOTAVAIL) ++ continue; + + for (n = 0; n < num_socks; n++) { + close(socks[n]); diff --git a/openssh.spec b/openssh.spec index f942796..624a2cd 100644 --- a/openssh.spec +++ b/openssh.spec @@ -30,7 +30,7 @@ Summary(ru.UTF-8): OpenSSH - свободная реализация прото Summary(uk.UTF-8): OpenSSH - вільна реалізація протоколу Secure Shell (SSH) Name: openssh Version: 5.9p1 -Release: 6 +Release: 7 Epoch: 2 License: BSD Group: Applications/Networking @@ -64,6 +64,7 @@ Patch11: %{name}-chroot.patch # http://people.debian.org/~cjwatson/%{name}-blacklist.diff Patch12: %{name}-blacklist.diff Patch13: %{name}-kuserok.patch +Patch14: %{name}-bind.patch URL: http://www.openssh.com/portable.html BuildRequires: %{__perl} %{?with_audit:BuildRequires: audit-libs-devel} @@ -524,6 +525,7 @@ openldap-a. %patch11 -p1 %patch12 -p1 %patch13 -p1 +%patch14 -p1 cp -p %{SOURCE3} sshd.pam install -p %{SOURCE2} sshd.init -- 2.44.0