- (djm) [channels.c configure.ac]

Do not set SO_REUSEADDR on wildcard X11 listeners (X11UseLocalhost=no)
   bz#1464; ok dtucker
This commit is contained in:
Damien Miller 2008-06-12 06:05:12 +10:00
parent b8e0500351
commit 4401e45be6
3 changed files with 10 additions and 14 deletions

View File

@ -1,3 +1,8 @@
20080611
- (djm) [channels.c configure.ac]
Do not set SO_REUSEADDR on wildcard X11 listeners (X11UseLocalhost=no)
bz#1464; ok dtucker
20080610 20080610
- (dtucker) OpenBSD CVS Sync - (dtucker) OpenBSD CVS Sync
- djm@cvs.openbsd.org 2008/06/10 03:57:27 - djm@cvs.openbsd.org 2008/06/10 03:57:27
@ -4154,4 +4159,4 @@
OpenServer 6 and add osr5bigcrypt support so when someone migrates OpenServer 6 and add osr5bigcrypt support so when someone migrates
passwords between UnixWare and OpenServer they will still work. OK dtucker@ passwords between UnixWare and OpenServer they will still work. OK dtucker@
$Id: ChangeLog,v 1.4966 2008/06/10 23:47:59 dtucker Exp $ $Id: ChangeLog,v 1.4967 2008/06/11 20:05:12 djm Exp $

View File

@ -3018,7 +3018,8 @@ x11_create_display_inet(int x11_display_offset, int x11_use_localhost,
error("setsockopt IPV6_V6ONLY: %.100s", strerror(errno)); error("setsockopt IPV6_V6ONLY: %.100s", strerror(errno));
} }
#endif #endif
channel_set_reuseaddr(sock); if (x11_use_localhost)
channel_set_reuseaddr(sock);
if (bind(sock, ai->ai_addr, ai->ai_addrlen) < 0) { if (bind(sock, ai->ai_addr, ai->ai_addrlen) < 0) {
debug2("bind port %d: %.100s", port, strerror(errno)); debug2("bind port %d: %.100s", port, strerror(errno));
close(sock); close(sock);
@ -3030,17 +3031,8 @@ x11_create_display_inet(int x11_display_offset, int x11_use_localhost,
break; break;
} }
socks[num_socks++] = sock; socks[num_socks++] = sock;
#ifndef DONT_TRY_OTHER_AF
if (num_socks == NUM_SOCKS) if (num_socks == NUM_SOCKS)
break; break;
#else
if (x11_use_localhost) {
if (num_socks == NUM_SOCKS)
break;
} else {
break;
}
#endif
} }
freeaddrinfo(aitop); freeaddrinfo(aitop);
if (num_socks > 0) if (num_socks > 0)

View File

@ -1,4 +1,4 @@
# $Id: configure.ac,v 1.403 2008/06/10 18:15:05 dtucker Exp $ # $Id: configure.ac,v 1.404 2008/06/11 20:05:12 djm Exp $
# #
# Copyright (c) 1999-2004 Damien Miller # Copyright (c) 1999-2004 Damien Miller
# #
@ -15,7 +15,7 @@
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
AC_INIT(OpenSSH, Portable, openssh-unix-dev@mindrot.org) AC_INIT(OpenSSH, Portable, openssh-unix-dev@mindrot.org)
AC_REVISION($Revision: 1.403 $) AC_REVISION($Revision: 1.404 $)
AC_CONFIG_SRCDIR([ssh.c]) AC_CONFIG_SRCDIR([ssh.c])
AC_CONFIG_HEADER(config.h) AC_CONFIG_HEADER(config.h)
@ -553,7 +553,6 @@ main() { if (NSVersionOfRunTimeLibrary("System") >= (60 << 16))
no_dev_ptmx=1 no_dev_ptmx=1
check_for_libcrypt_later=1 check_for_libcrypt_later=1
check_for_openpty_ctty_bug=1 check_for_openpty_ctty_bug=1
AC_DEFINE(DONT_TRY_OTHER_AF, 1, [Workaround more Linux IPv6 quirks])
AC_DEFINE(PAM_TTY_KLUDGE, 1, AC_DEFINE(PAM_TTY_KLUDGE, 1,
[Work around problematic Linux PAM modules handling of PAM_TTY]) [Work around problematic Linux PAM modules handling of PAM_TTY])
AC_DEFINE(LOCKED_PASSWD_PREFIX, "!", AC_DEFINE(LOCKED_PASSWD_PREFIX, "!",