[exim-cvs] cvs commit: exim/exim-doc/doc-txt ChangeLog exim…

トップ ページ
このメッセージを削除
このメッセージに返信
著者: Philip Hazel
日付:  
To: exim-cvs
題目: [exim-cvs] cvs commit: exim/exim-doc/doc-txt ChangeLog exim/exim-src/src host.c
ph10 2005/11/21 12:04:23 GMT

  Modified files:
    exim-doc/doc-txt     ChangeLog 
    exim-src/src         host.c 
  Log:
  Mend comparison bug for canonical vs non-canonical IPv6 addresses.


  Revision  Changes    Path
  1.267     +10 -0     exim/exim-doc/doc-txt/ChangeLog
  1.18      +1 -4      exim/exim-src/src/host.c


  Index: ChangeLog
  ===================================================================
  RCS file: /home/cvs/exim/exim-doc/doc-txt/ChangeLog,v
  retrieving revision 1.266
  retrieving revision 1.267
  diff -u -r1.266 -r1.267
  --- ChangeLog    21 Nov 2005 10:24:02 -0000    1.266
  +++ ChangeLog    21 Nov 2005 12:04:23 -0000    1.267
  @@ -1,4 +1,4 @@
  -$Cambridge: exim/exim-doc/doc-txt/ChangeLog,v 1.266 2005/11/21 10:24:02 ph10 Exp $
  +$Cambridge: exim/exim-doc/doc-txt/ChangeLog,v 1.267 2005/11/21 12:04:23 ph10 Exp $


Change log file for Exim from version 4.21
-------------------------------------------
@@ -150,6 +150,16 @@

   PH/18 Exim was not recognizing the "net-" search type prefix in match_ip lists
         (Bugzilla #53).
  +
  +PH/19 Exim expands the IPv6 address given to -bh to its full non-abbreviated
  +      canonical form (as documented). However, after a host name lookup from
  +      the IP address, check_host() was doing a simple string comparison with
  +      addresses acquired from the DNS when checking that the found name did
  +      have the original IP as one of its addresses. Since any found IPv6
  +      addresses are likely to be in abbreviated form, the comparison could
  +      fail. Luckily, there already exists a function for doing the comparison
  +      by converting both addresses to binary, so now that is used instead of
  +      the text comparison.



Exim version 4.54

  Index: host.c
  ===================================================================
  RCS file: /home/cvs/exim/exim-src/src/host.c,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -r1.17 -r1.18
  --- host.c    11 Nov 2005 10:02:04 -0000    1.17
  +++ host.c    21 Nov 2005 12:04:23 -0000    1.18
  @@ -1,4 +1,4 @@
  -/* $Cambridge: exim/exim-src/src/host.c,v 1.17 2005/11/11 10:02:04 ph10 Exp $ */
  +/* $Cambridge: exim/exim-src/src/host.c,v 1.18 2005/11/21 12:04:23 ph10 Exp $ */


   /*************************************************
   *     Exim - an Internet mail transport agent    *
  @@ -1836,13 +1836,10 @@
     if ((rc = host_find_byname(&h, NULL, NULL, FALSE)) == HOST_FOUND)
       {
       host_item *hh;
  -    uschar *address_ipv4 = (Ustrncmp(sender_host_address, "::ffff:", 7) == 0)?
  -      sender_host_address + 7 : sender_host_address;
       HDEBUG(D_host_lookup) debug_printf("checking addresses for %s\n", hname);
       for (hh = &h; hh != NULL; hh = hh->next)
         {
  -      if ((Ustrcmp(hh->address, (Ustrchr(hh->address, ':') == NULL)?
  -          address_ipv4 : sender_host_address)) == 0)
  +      if (host_is_in_net(hh->address, sender_host_address, 0))
           {
           HDEBUG(D_host_lookup) debug_printf("  %s OK\n", hh->address);
           ok = TRUE;