Your message dated Tue, 23 Aug 2005 00:17:04 -0700
with message-id <[EMAIL PROTECTED]>
and subject line Bug#303579: fixed in hostname 2.90
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; 7 Apr 2005 15:21:59 +0000
>From [EMAIL PROTECTED] Thu Apr 07 08:21:59 2005
Return-path: <[EMAIL PROTECTED]>
Received: from smtp-104-thursday.noc.nerim.net (mallaury.noc.nerim.net) 
[62.4.17.104] 
        by spohr.debian.org with esmtp (Exim 3.35 1 (Debian))
        id 1DJYpT-0006Sy-00; Thu, 07 Apr 2005 08:21:59 -0700
Received: from smoke.sprite.patnet (sprite.fr.eu.org [213.41.136.74])
        by mallaury.noc.nerim.net (Postfix) with ESMTP id BD15A62DB3
        for <[EMAIL PROTECTED]>; Thu,  7 Apr 2005 17:21:55 +0200 (CEST)
Received: from sprite by smoke.sprite.patnet with local (Exim 3.35 #1 (Debian))
        id 1DJYxf-0002KH-00
        for <[EMAIL PROTECTED]>; Thu, 07 Apr 2005 17:30:27 +0200
Date: Thu, 7 Apr 2005 17:30:26 +0200
To: [EMAIL PROTECTED]
Subject: hostname: fails to work on IPv6-only hosts
Message-ID: <[EMAIL PROTECTED]>
Mime-Version: 1.0
Content-Type: multipart/mixed; boundary="h31gzZEtNLTqOjlF"
Content-Disposition: inline
User-Agent: Mutt/1.3.28i
From: Jeremie Koenig <[EMAIL PROTECTED]>
Delivered-To: [EMAIL PROTECTED]
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=-8.0 required=4.0 tests=BAYES_00,HAS_PACKAGE 
        autolearn=no version=2.60-bugs.debian.org_2005_01_02
X-Spam-Level: 


--h31gzZEtNLTqOjlF
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

Package: hostname
Version: 2.13
Severity: minor
Tags: patch

Hello,

Here is a patch which makes hostname try an IPv6 lookup in case the IPv4
one fails. This is needed to make hostname work on IPv6-only hosts.

This is a quick minimal non-instrusive half-fix only. I'd like to
implement the following behaviour if you and/or upstream are instereted:
    - by default, use both IPv4 and IPv6 for finding addresses/aliases;
    - allow the user to restrict operation to a given address space by
      using some command-line flags (such as -4/-6).  This would allow
      scripts to trust hostname to give them IPv4 or IPv6 addresses
      only.

What do you think ?

-- 
Jeremie Koenig <[EMAIL PROTECTED]>

--h31gzZEtNLTqOjlF
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="hostname.diff"

diff -ru hostname-2.13.orig/hostname.c hostname-2.13/hostname.c
--- hostname-2.13.orig/hostname.c       2003-12-18 03:11:33.000000000 +0100
+++ hostname-2.13/hostname.c    2005-04-07 16:08:24.000000000 +0200
@@ -123,9 +123,13 @@
        register char *p,**alias;
        struct in_addr **ip;
        int flag = 0;   
+       char abuf[INET6_ADDRSTRLEN];
+
        if (opt_v)
                fprintf(stderr,NLS_CATGETS(catfd, hostnameSet, 
hostname_verb_res, "Resolving `%s' ...\n"),hname);
-       if (!(hp = gethostbyname(hname))) {
+
+       if (!(hp = gethostbyname(hname)) && !(hp = gethostbyname2(hname,
+                                       AF_INET6))) {
                herror(program_name);
                NLS_CATCLOSE(catfd)
                exit(1);
@@ -143,7 +147,7 @@
                ip=(struct in_addr **)hp->h_addr_list;
                while(ip[0])
                        fprintf(stderr,NLS_CATGETS(catfd, hostnameSet, 
hostname_verb_ipn, "Result: h_addr_list=`%s'\n"),
-                               inet_ntoa(**ip++));
+                               inet_ntop(hp->h_addrtype, *ip++, abuf, 
sizeof(abuf)));
        }
 
        if (!(p = strchr(hp->h_name, '.')) && (c == 'd')) return;
@@ -162,7 +166,8 @@
                        while (hp->h_addr_list[0]) {
                                if(flag)
                                        printf(" ");
-                               printf("%s ", inet_ntoa(*(struct in_addr *) * 
hp->h_addr_list++));
+                               printf("%s", inet_ntop(hp->h_addrtype,
+                                       *hp->h_addr_list++, abuf,sizeof(abuf)));
                                flag = 1;
                        }
                        printf("\n");

--h31gzZEtNLTqOjlF--

---------------------------------------
Received: (at 303579-close) by bugs.debian.org; 23 Aug 2005 07:19:56 +0000
>From [EMAIL PROTECTED] Tue Aug 23 00:19:55 2005
Return-path: <[EMAIL PROTECTED]>
Received: from katie by spohr.debian.org with local (Exim 3.36 1 (Debian))
        id 1E7T1s-0000TF-00; Tue, 23 Aug 2005 00:17:04 -0700
From: Graham Wilson <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
X-Katie: $Revision: 1.56 $
Subject: Bug#303579: fixed in hostname 2.90
Message-Id: <[EMAIL PROTECTED]>
Sender: Archive Administrator <[EMAIL PROTECTED]>
Date: Tue, 23 Aug 2005 00:17:04 -0700
Delivered-To: [EMAIL PROTECTED]
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-Level: 
X-Spam-Status: No, hits=-6.0 required=4.0 tests=BAYES_00,HAS_BUG_NUMBER 
        autolearn=no version=2.60-bugs.debian.org_2005_01_02
X-CrossAssassin-Score: 3

Source: hostname
Source-Version: 2.90

We believe that the bug you reported is fixed in the latest version of
hostname, which is due to be installed in the Debian FTP archive:

hostname_2.90.dsc
  to pool/main/h/hostname/hostname_2.90.dsc
hostname_2.90.tar.gz
  to pool/main/h/hostname/hostname_2.90.tar.gz
hostname_2.90_powerpc.deb
  to pool/main/h/hostname/hostname_2.90_powerpc.deb



A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [EMAIL PROTECTED],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Graham Wilson <[EMAIL PROTECTED]> (supplier of updated hostname package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [EMAIL PROTECTED])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Format: 1.7
Date: Tue, 23 Aug 2005 06:37:42 +0000
Source: hostname
Binary: hostname
Architecture: source powerpc
Version: 2.90
Distribution: unstable
Urgency: low
Maintainer: Graham Wilson <[EMAIL PROTECTED]>
Changed-By: Graham Wilson <[EMAIL PROTECTED]>
Description: 
 hostname   - utility to set/show the host name or domain name
Closes: 253957 290178 303579
Changes: 
 hostname (2.90) unstable; urgency=low
 .
   * Rewrite hostname to hopefully be a bit more organzied.
     - moved localhost() and localdomain() to hostname.c
     - code to set the host or domain name moved to set_name()
     - code to display the host or domain name moved to show_name()
     - clean up main()
     - i18n support removed, seems to be unused and outdated
     - verbose output removed
     - check for non-used arguments (closes: #253957)
     - remove the useless man directory from the source
     - remove unneeded header files
     - simplify the build system
 .
   * Set the debhelper compat level to 4.
   * Build depend on debhelper (>= 4.0).
   * Improve the copyright file. (closes: #290178)
   * Update standards version. No changes.
   * Adjust the synopsis to be in line with the Developer's Reference.
 .
   * A check_name function was added to check whether hostnames follow RFC
     1035 syntax.
 .
   * Use inet_ntop instead of inet_ntoa when printing addresses, in order to
     support IPv6 addresses. (closes: #303579)
Files: 
 6b453d2890ecc0cd275de0a03e2dda60 780 base required hostname_2.90.dsc
 4dfcf5ed85e3282686c334a19794b503 8584 base required hostname_2.90.tar.gz
 3bbd11133c6e86310180affc621acaa6 9952 base required hostname_2.90_powerpc.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)

iQEVAwUBQwrJui6fnYH5E4SWAQIQEQgAj/ZGb2HY3dpeiFr4DbPud2PWMs09a1vo
xxMgawmt+5UDRKKSxNEPU/a0n8MY7WT1SrfueaOXj6vs2K2Le8eN2q/uRu1m/aif
ILI+7BhlO/tZxrcskZq+DoXNZjqaClFekpQXyPyC4EnvXcHs1FkWR6kPBXH/wfVK
vtNLRXbQariKWLSsj9BfsTg+Xx94rn9fuAdgZehYRSDVJnUOAGQ1iMffbXJ4f01Z
+PD53BrceYi2zpJMgn3NJzRbSTFoo8FYMtIpeqNpSpn2H9fYB0siKFHu+2v7HU3d
LXyGSlV8itFYcajtpqrtqwmXDDx2Hi/LUzd6o+DTxBksOvoDqXIx/Q==
=cK6B
-----END PGP SIGNATURE-----


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to