ALT Linux Community general discussions
 help / color / mirror / Atom feed
* [Comm] XDMCP
@ 2013-11-02 17:45 Roman Savochenko
  2013-11-05  8:26 ` Michael Shigorin
  0 siblings, 1 reply; 2+ messages in thread
From: Roman Savochenko @ 2013-11-02 17:45 UTC (permalink / raw)
  To: community

[-- Attachment #1: Type: text/plain, Size: 331 bytes --]

Приветствую, Всех

А XDMCP у нас, как минимум на T6, уже без IPV6 никак, без пересборки, не 
работает?
XDMCP warning: INET6 UDP socket creation failed
Fatal server error:
XDMCP fatal error: Session declined No valid address

Из исходников вроде видно, что если IPV6 определён, то остальное он даже 
не смотрит!

С уважением, Роман

[-- Attachment #2: rom_as.vcf --]
[-- Type: text/x-vcard, Size: 298 bytes --]

begin:vcard
fn:Roman Savochenko
n:Savochenko;Roman
org:DIYA Ltd
adr:;;;Dneprodzerzinsk;Dnepropetrovsk;51925;Ukraine
email;internet:rom_as@oscada.org
title:Leading engineer-programer
tel;work:+380675675542
tel;fax:+380569262025
tel;cell:+380679859815
url:http://diyaorg.dp.ua
version:2.1
end:vcard


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [Comm] XDMCP
  2013-11-02 17:45 [Comm] XDMCP Roman Savochenko
@ 2013-11-05  8:26 ` Michael Shigorin
  0 siblings, 0 replies; 2+ messages in thread
From: Michael Shigorin @ 2013-11-05  8:26 UTC (permalink / raw)
  To: community

[-- Attachment #1: Type: text/plain, Size: 366 bytes --]

On Sat, Nov 02, 2013 at 07:45:43PM +0200, Roman Savochenko wrote:
> XDMCP warning: INET6 UDP socket creation failed
> Из исходников вроде видно, что если IPV6 определён,
> то остальное он даже не смотрит!

Возможно, следует откатить эти или подобные им патчи.

-- 
 ---- WBR, Michael Shigorin / http://altlinux.org
  ------ http://opennet.ru / http://anna-news.info

[-- Attachment #2: 01_gdmchooser-ipv6_bindv6only-workaround.patch --]
[-- Type: text/plain, Size: 893 bytes --]

Debian #562126; enable gdmchooser to work with netbase default setting
net.ipv6.bindv6only=1

diff -Naur gdm-2.20.10/gui/gdmchooser.c gdm-2.20.10/gui/gdmchooser.c
--- gdm-2.20.10/gui/gdmchooser.c	2009-03-19 00:29:11.000000000 -0430
+++ gdm-2.20.10/gui/gdmchooser.c	2010-02-09 20:10:08.000000000 -0430
@@ -1121,6 +1121,7 @@
 {
 	static XdmcpHeader header;
 	gint sockopts = 1;
+	int ipv6_only_flag = 0;
 
 	/* Open socket for communication */
 #ifdef ENABLE_IPV6
@@ -1140,6 +1141,13 @@
 		gdm_common_fail_exit ("Could not set socket options!");
 	}
 
+	if (have_ipv6) {
+		if (setsockopt (sockfd, IPPROTO_IPV6, IPV6_V6ONLY,
+			(char*)&ipv6_only_flag, sizeof(ipv6_only_flag)) < 0) {
+			gdm_common_fail_exit ("Could not set socket options!");
+            }
+	}
+
 	/* Assemble XDMCP BROADCAST_QUERY packet in static buffer */
 	header.opcode  = (CARD16) BROADCAST_QUERY;
 	header.length  = 1;

[-- Attachment #3: 02_xdmcp-ipv6_bindv6only.patch --]
[-- Type: text/plain, Size: 899 bytes --]

Debian #563406

Index: gdm-2.20.10/daemon/gdm-xdmcp-manager.c
===================================================================
--- gdm-2.20.10.orig/daemon/gdm-xdmcp-manager.c	2010-02-28 13:57:47.685002928 +0100
+++ gdm-2.20.10/daemon/gdm-xdmcp-manager.c	2010-02-28 14:01:54.697504018 +0100
@@ -398,6 +398,7 @@ static int
 create_socket (struct addrinfo *ai)
 {
 	int sock;
+	int zero = 0;
 
 	sock = socket (ai->ai_family, ai->ai_socktype, ai->ai_protocol);
 	if (sock < 0) {
@@ -405,6 +406,14 @@ create_socket (struct addrinfo *ai)
 		return sock;
 	}
 
+	if (ai->ai_family == AF_INET6) {
+		if (setsockopt(sock, IPPROTO_IPV6, IPV6_V6ONLY, &zero, sizeof zero) < 0) {
+			gdm_error("setsockopt(IPV6_V6ONLY): %s\n", g_strerror(errno));
+			close(sock);
+			return -1;
+		}
+	}
+
 	if (bind (sock, ai->ai_addr, ai->ai_addrlen) < 0) {
 		gdm_error ("bind: %s", g_strerror (errno));
 		close (sock);

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-11-05  8:26 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-11-02 17:45 [Comm] XDMCP Roman Savochenko
2013-11-05  8:26 ` Michael Shigorin

ALT Linux Community general discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/community/0 community/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 community community/ http://lore.altlinux.org/community \
		mandrake-russian@linuxteam.iplabs.ru community@lists.altlinux.org community@lists.altlinux.ru community@lists.altlinux.com
	public-inbox-index community

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.community


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git