[BZ #11438]
authorJeff Law <law@redhat.com>
Fri, 28 Sep 2012 16:15:05 +0000 (10:15 -0600)
committerJeff Law <law@redhat.com>
Fri, 28 Sep 2012 16:15:05 +0000 (10:15 -0600)
        * sysdeps/posix/getaddrinfo.c (default_scopes): Map RFC 1918
        * addresses
        to global scope.
        * posix/tst-rfc3484.c: Verify 10/8, 172.16/12 and 196.128/16
        addresses are in the same scope as 192.0.2/24.
        * posix/gai.conf: Document new scope table defaults.

ChangeLog
NEWS
posix/gai.conf
posix/tst-rfc3484.c
sysdeps/posix/getaddrinfo.c

index c277677f3b9fb533bf94ae5666eda44f2cf38fbc..27cf3a95030fb88cf86985e78785e08b76638f07 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2012-09-28  Dmitry V. Levin  <ldv@altlinux.org>
+
+       [BZ #11438]
+       * sysdeps/posix/getaddrinfo.c (default_scopes): Map RFC 1918 addresses
+       to global scope.
+       * posix/tst-rfc3484.c: Verify 10/8, 172.16/12 and 196.128/16
+       addresses are in the same scope as 192.0.2/24.
+       * posix/gai.conf: Document new scope table defaults.
+
 2012-09-28  Siddhesh Poyarekar  <siddhesh@redhat.com>
 
        [BZ #5298]
diff --git a/NEWS b/NEWS
index b8a01efe9bc6f63a507b24b3b42dab6d5e0a98a1..7b3f6314fbb0cfb39611f8730f35a0711ad5fbe2 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -10,12 +10,12 @@ Version 2.17
 * The following bugs are resolved with this release:
 
   1349, 3479, 5044, 5298, 5400, 6778, 6808, 9685, 9914, 10014, 10038,
-  11607, 13412, 13542, 13629, 13679, 13696, 13717, 13741, 13939, 13966,
-  14042, 14090, 14150, 14151, 14154, 14157, 14166, 14173, 14195, 14237,
-  14252, 14283, 14298, 14303, 14307, 14328, 14331, 14336, 14337, 14347,
-  14349, 14376, 14459, 14476, 14505, 14510, 14516, 14518, 14519, 14530,
-  14532, 14538, 14543, 14544, 14545, 14562, 14576, 14579, 14583, 14587,
-  14621.
+  11438, 11607, 13412, 13542, 13629, 13679, 13696, 13717, 13741, 13939,
+  13966, 14042, 14090, 14150, 14151, 14154, 14157, 14166, 14173, 14195,
+  14237, 14252, 14283, 14298, 14303, 14307, 14328, 14331, 14336, 14337,
+  14347, 14349, 14376, 14459, 14476, 14505, 14510, 14516, 14518, 14519,
+  14530, 14532, 14538, 14543, 14544, 14545, 14562, 14576, 14579, 14583,
+  14587, 14621.
 
 * Support for STT_GNU_IFUNC symbols added for s390 and s390x.
   Optimized versions of memcpy, memset, and memcmp added for System z10 and
index 195287e1c88f3d104e8876b21b9e3204d5eb7bb2..4616ed005b2e064175c88609b6d6022a6da4d5d8 100644 (file)
 
 #
 # scopev4  <mask>  <value>
-#    Add another rule to the RFC 3484 scope table for IPv4 addresses.
-#    By default the scope IDs described in section 3.2 in RFC 3484 are
+#    Add another rule to the RFC 6724 scope table for IPv4 addresses.
+#    By default the scope IDs described in section 3.2 in RFC 6724 are
 #    used.  Changing these defaults should hardly ever be necessary.
 #    The defaults are equivalent to:
 #
 #scopev4 ::ffff:169.254.0.0/112  2
 #scopev4 ::ffff:127.0.0.0/104    2
-#scopev4 ::ffff:10.0.0.0/104     5
-#scopev4 ::ffff:172.16.0.0/108   5
-#scopev4 ::ffff:192.168.0.0/112  5
-#scopev4 ::ffff:0.0.0.0/96       14
-#
-#    For sites which use site-local IPv4 addresses behind NAT there is
-#    the problem that even if IPv4 addresses are preferred they do not
-#    have the same scope and are therefore not sorted first.  To change
-#    this use only these rules:
-#
-#scopev4 ::ffff:169.254.0.0/112  2
-#scopev4 ::ffff:127.0.0.0/104    2
 #scopev4 ::ffff:0.0.0.0/96       14
index 29e1461e1181f2d49c29bcf8934cef8244d7230b..db3ae1b7bb86406aef99fc5b24c23a6b9ca3fed1 100644 (file)
@@ -71,6 +71,9 @@ service_user *__nss_hosts_database attribute_hidden;
 
 struct sockaddr_in addrs[] =
 {
+  { .sin_family = AF_INET, .sin_addr = { h (0x0aa85f19) } },
+  { .sin_family = AF_INET, .sin_addr = { h (0xac105f19) } },
+  { .sin_family = AF_INET, .sin_addr = { h (0xc0000219) } },
   { .sin_family = AF_INET, .sin_addr = { h (0xc0a86d1d) } },
   { .sin_family = AF_INET, .sin_addr = { h (0xc0a85d03) } },
   { .sin_family = AF_INET, .sin_addr = { h (0xc0a82c3d) } },
@@ -86,7 +89,7 @@ static size_t order[naddrs];
 
 static int expected[naddrs] =
   {
-    6, 1, 0, 3, 2, 4, 5
+    9, 4, 3, 6, 5, 7, 8, 2, 0, 1
   };
 
 
index 05883bd55f0f0f0c83eec2269631725e5e70d3e3..672571ef2396f120aa1b5bb9df3bb887884204d8 100644 (file)
@@ -1369,10 +1369,6 @@ static const struct scopeentry
     /* Link-local addresses: scope 2.  */
     { { { 169, 254, 0, 0 } }, htonl_c (0xffff0000), 2 },
     { { { 127, 0, 0, 0 } }, htonl_c (0xff000000), 2 },
-    /* Site-local addresses: scope 5.  */
-    { { { 10, 0, 0, 0 } }, htonl_c (0xff000000), 5 },
-    { { { 172, 16, 0, 0 } }, htonl_c (0xfff00000), 5 },
-    { { { 192, 168, 0, 0 } }, htonl_c (0xffff0000), 5 },
     /* Default: scope 14.  */
     { { { 0, 0, 0, 0 } }, htonl_c (0x00000000), 14 }
   };