[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#113789: marked as done ((telnet) resolver: ignores /etc/hosts and nsswitch.conf)



Your message dated Mon, 11 Jul 2005 14:43:19 -0400 (EDT)
with message-id <Pine.BSO.4.58.0507111434560.19039@grex.cyberspace.org>
and subject line too old and merged
has caused the attached Bug report to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what I am
talking about this indicates a serious mail system misconfiguration
somewhere.  Please contact me immediately.)

Debian bug tracking system administrator
(administrator, Debian Bugs database)

--------------------------------------
Received: (at submit) by bugs.debian.org; 28 Sep 2001 15:10:00 +0000
>From gward@mems-exchange.org Fri Sep 28 10:10:00 2001
Return-path: <gward@mems-exchange.org>
Received: from relais.videotron.ca (VL-MS-MR003.sc1.videotron.ca) [24.201.245.36] 
	by master.debian.org with esmtp (Exim 3.12 1 (Debian))
	id 15mzH5-0006wq-00; Fri, 28 Sep 2001 10:09:59 -0500
Received: from cthulhu ([24.201.33.127]) by
          VL-MS-MR003.sc1.videotron.ca (Netscape Messaging Server 4.15
          MR003 Jul 24 2001 16:23:26) with ESMTP id GKDOSN01.FXH; Fri, 28
          Sep 2001 11:09:59 -0400 
Received: from gward by cthulhu with local (Exim 3.31 #1 (Debian))
	id 15mzH4-0000LC-00; Fri, 28 Sep 2001 11:09:58 -0400
From: Greg Ward <gward@python.net>
Subject: telnet: telnet ignores /etc/nsswitch.conf
To: submit@bugs.debian.org
X-Mailer: bug 3.3.10
Message-Id: <E15mzH4-0000LC-00@cthulhu>
Date: Fri, 28 Sep 2001 11:09:58 -0400
Delivered-To: submit@bugs.debian.org

Package: telnet
Version: 0.17-15
Severity: normal

The telnet.netkit client doesn't seem to use the resolver library in the
usual way, ie. /etc/hosts first, then DNS.  At least that is how I have
it configured in /etc/nsswitch.conf:
  hosts:          files dns

Rather, it looks as though it always uses DNS first, and then falls back
on /etc/hosts if the DNS lookup fails.  IOW, it seems that telnet acts
as though that line were
  hosts:          dns files

Proof: my /etc/hosts starts with this line:
  127.0.0.1       cthulhu localhost cthulhu.gerg.ca

Most TCP clients (everything from netcat to Opera) treat "cthulhu" and
"cthulhu.gerg.ca" identically, ie. as 127.0.0.1.  The gethostbyname()
library call certainly pays attention to my /etc/hosts file:
  $ python
  Python 2.1 (#2, May  8 2001, 10:50:59) 
  [GCC 2.95.2 20000220 (Debian GNU/Linux)] on linux2
  Type "copyright", "credits" or "license" for more information.
  >>> from socket import *
  >>> gethostbyname("cthulhu.gerg.ca")
  '127.0.0.1'

But telnet goes to DNS first, and uses the IP address that the outside
world sees for my FQDN (assigned by my ISP, DNS-served by dyndns.org):

  $ telnet cthulhu.gerg.ca 80
  Trying 24.201.33.127...

Because I have iptables setup to treat 127.0.0.1 very differently from
my external IP address, this doesn't work.  That's annoying, and it's
inconsistent with just about every other TCP application on my system,
which all seem to respect /etc/nsswitch.conf and therefore consult
/etc/hosts first.

-- System Information
Debian Release: testing/unstable
Kernel Version: Linux cthulhu 2.4.10 #1 Mon Sep 24 21:13:20 EDT 2001 i686 unknown

Versions of the packages telnet depends on:
ii  libc6          2.2.4-1        GNU C Library: Shared libraries and Timezone
ii  libncurses5    5.2.20010318-3 Shared libraries for terminal handling


---------------------------------------
Received: (at 109931-done) by bugs.debian.org; 11 Jul 2005 18:40:29 +0000
>From dajo@cyberspace.org Mon Jul 11 11:40:29 2005
Return-path: <dajo@cyberspace.org>
Received: from grex.cyberspace.org [216.86.77.194] (exim)
	by spohr.debian.org with esmtp (Exim 3.35 1 (Debian))
	id 1Ds3Cf-0004Ww-00; Mon, 11 Jul 2005 11:40:29 -0700
Received: from dajo (helo=localhost)
	by grex.cyberspace.org with local-esmtp (Exim 4.42)
	id 1Ds3FP-0000YK-6i; Mon, 11 Jul 2005 14:43:19 -0400
Date: Mon, 11 Jul 2005 14:43:19 -0400 (EDT)
From: Daniel Jonan <dajo@grex.cyberspace.org>
To: 26306-done@bugs.debian.org, 6798-done@bugs.debian.org, 
    159781-done@bugs.debian.org, 109931-done@bugs.debian.org
cc: 76251-done@bugs.debian.org, 89323-done@bugs.debian.org, 
    11147-done@bugs.debian.org
Subject: too old and merged
Message-ID: <Pine.BSO.4.58.0507111434560.19039@grex.cyberspace.org>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
Sender: Daniel Jonan <dajo@cyberspace.org>
Delivered-To: 109931-done@bugs.debian.org
X-Spam-Checker-Version: SpamAssassin 2.60-bugs.debian.org_2005_01_02 
	(1.212-2003-09-23-exp) on spohr.debian.org
X-Spam-Status: No, hits=-3.0 required=4.0 tests=BAYES_00 autolearn=no 
	version=2.60-bugs.debian.org_2005_01_02
X-Spam-Level: 

closing



Reply to: