From peterjeremy@acm.org  Sat Mar 19 00:09:33 2011
Return-Path: <peterjeremy@acm.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 2360D106566B
	for <FreeBSD-gnats-submit@freebsd.org>; Sat, 19 Mar 2011 00:09:33 +0000 (UTC)
	(envelope-from peterjeremy@acm.org)
Received: from mail18.syd.optusnet.com.au (mail18.syd.optusnet.com.au [211.29.132.199])
	by mx1.freebsd.org (Postfix) with ESMTP id B1BE28FC0C
	for <FreeBSD-gnats-submit@freebsd.org>; Sat, 19 Mar 2011 00:09:32 +0000 (UTC)
Received: from server.vk2pj.dyndns.org (c220-239-116-103.belrs4.nsw.optusnet.com.au [220.239.116.103])
	by mail18.syd.optusnet.com.au (8.13.1/8.13.1) with ESMTP id p2J09TVN017869
	(version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO)
	for <FreeBSD-gnats-submit@freebsd.org>; Sat, 19 Mar 2011 11:09:30 +1100
Received: from server.vk2pj.dyndns.org (localhost.vk2pj.dyndns.org [127.0.0.1])
	by server.vk2pj.dyndns.org (8.14.4/8.14.4) with ESMTP id p2J09TY4004463;
	Sat, 19 Mar 2011 11:09:29 +1100 (EST)
	(envelope-from peter@server.vk2pj.dyndns.org)
Received: (from peter@localhost)
	by server.vk2pj.dyndns.org (8.14.4/8.14.4/Submit) id p2J09SVi004462;
	Sat, 19 Mar 2011 11:09:28 +1100 (EST)
	(envelope-from peter)
Message-Id: <201103190009.p2J09SVi004462@server.vk2pj.dyndns.org>
Date: Sat, 19 Mar 2011 11:09:28 +1100 (EST)
From: Peter Jeremy <peterjeremy@acm.org>
Reply-To: Peter Jeremy <peterjeremy@acm.org>
To: FreeBSD-gnats-submit@freebsd.org
Subject: x11/xdm [patch] Enabling IPv6 support breaks IPv4
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         155683
>Category:       ports
>Synopsis:       x11/xdm [patch] Enabling IPv6 support breaks IPv4
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    freebsd-x11
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Mar 19 00:10:10 UTC 2011
>Closed-Date:    Wed Jul 10 12:21:18 UTC 2013
>Last-Modified:  Wed Jul 10 12:21:18 UTC 2013
>Originator:     Peter Jeremy
>Release:        FreeBSD 8.2-STABLE amd64
>Organization:
n/a
>Environment:
System: FreeBSD server.vk2pj.dyndns.org 8.2-STABLE FreeBSD 8.2-STABLE #9: Sun Feb 27 17:46:10 EST 2011 root@server.vk2pj.dyndns.org:/var/obj/usr/src/sys/server amd64
	xdm-1.1.8_3

>Description:
	If the xdm configure script detects IPv6 support is available,
	it will build a version of xdm that supports xdmcp over IPv6.
	Unfortunately, due to a long outstanding bug (google shows
	references back to 2006), xdm then no longer supports IPv4.

>How-To-Repeat:
	Given two hosts A and B, both running a "generic" world (ie no
	"WITHOUT_INET6" or similar) with xorg and having only IPv4
	addresses on physical networks:

	On host A, comment out the line "DisplayManager.requestPort: 0" in
	in /usr/local/lib/X11/xdm/xdm-config, add B's FQDN to
	 /usr/local/lib/X11/xdm/Xaccess and [re]start xdm.  Use
	lsof or similar to show that xdm is listening on UDP6:177

	On host B, start X with the options '-nolisten inet6 -query A'.

	Use tcpdump or similar to show that X on host B is sending
	xdmcp packets to UDP:177 on host A and receiving ICMP port
	unreachable packets back.

>Fix:
	The correct fix is to change xdm to simultaneously handle both
	IPv4 and IPv6 xdmcp requests.  I haven't been able to find
	suitable code on the net.

	As a work-around, I suggest the following patch to the port
	Makefile to make IPv6 optional (defaulting to off).

Index: Makefile
===================================================================
RCS file: /usr/ncvs/ports/x11/xdm/Makefile,v
retrieving revision 1.10
diff -u -r1.10 Makefile
--- Makefile	25 Feb 2011 16:52:19 -0000	1.10
+++ Makefile	18 Mar 2011 23:37:48 -0000
@@ -18,6 +18,14 @@
 CONFIGURE_ARGS+=	--with-xdmconfigdir=${EXAMPLESDIR} \
 			--with-xdmscriptdir=${EXAMPLESDIR}
 
+OPTIONS=	IPV6	"Enable IPv6 support (breaks IPv4)."	Off
+
+.include <bsd.port.options.mk>
+
+.if defined(WITHOUT_IPV6)
+CONFIGURE_ARGS+=	--disable-ipv6
+.endif
+
 MAN1=		xdm.1
 
 CFFILES=	GiveConsole TakeConsole Xaccess Xreset Xresources \
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->freebsd-x11 
Responsible-Changed-By: edwin 
Responsible-Changed-When: Sat Mar 19 00:10:25 UTC 2011 
Responsible-Changed-Why:  
Over to maintainer (via the GNATS Auto Assign Tool) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=155683 
State-Changed-From-To: open->feedback 
State-Changed-By: zeising 
State-Changed-When: Wed Jun 26 17:10:30 UTC 2013 
State-Changed-Why:  
Is this still an issue with the latest x11/xdm in ports? 

http://www.freebsd.org/cgi/query-pr.cgi?pr=155683 
State-Changed-From-To: feedback->closed 
State-Changed-By: zeising 
State-Changed-When: Wed Jul 10 12:21:17 UTC 2013 
State-Changed-Why:  
Feedback timeout. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=155683 
>Unformatted:
