Source-Changes-HG archive

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

[src/trunk]: src/sys Now that we disallow sending or receiving from invalid a...



details:   https://anonhg.NetBSD.org/src/rev/dbf4f5e0a360
branches:  trunk
changeset: 347994:dbf4f5e0a360
user:      roy <roy%NetBSD.org@localhost>
date:      Thu Sep 29 12:19:47 2016 +0000

description:
Now that we disallow sending or receiving from invalid addresses,
allow binding to tentative addresses.

diffstat:

 sys/netinet/in_pcb.c   |  6 +++---
 sys/netinet/raw_ip.c   |  6 +++---
 sys/netinet6/in6_pcb.c |  6 +++---
 sys/netinet6/raw_ip6.c |  6 +++---
 4 files changed, 12 insertions(+), 12 deletions(-)

diffs (108 lines):

diff -r 8a60c59e1740 -r dbf4f5e0a360 sys/netinet/in_pcb.c
--- a/sys/netinet/in_pcb.c      Thu Sep 29 11:38:43 2016 +0000
+++ b/sys/netinet/in_pcb.c      Thu Sep 29 12:19:47 2016 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: in_pcb.c,v 1.169 2016/08/26 23:12:06 roy Exp $ */
+/*     $NetBSD: in_pcb.c,v 1.170 2016/09/29 12:19:47 roy Exp $ */
 
 /*
  * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -93,7 +93,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: in_pcb.c,v 1.169 2016/08/26 23:12:06 roy Exp $");
+__KERNEL_RCSID(0, "$NetBSD: in_pcb.c,v 1.170 2016/09/29 12:19:47 roy Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_inet.h"
@@ -297,7 +297,7 @@
                }
                if (ia == NULL)
                        goto error;
-               if (ia->ia4_flags & IN_IFF_NOTREADY)
+               if (ia->ia4_flags & IN_IFF_DUPLICATED)
                        goto error;
        }
        pserialize_read_exit(s);
diff -r 8a60c59e1740 -r dbf4f5e0a360 sys/netinet/raw_ip.c
--- a/sys/netinet/raw_ip.c      Thu Sep 29 11:38:43 2016 +0000
+++ b/sys/netinet/raw_ip.c      Thu Sep 29 12:19:47 2016 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: raw_ip.c,v 1.160 2016/08/26 23:12:06 roy Exp $ */
+/*     $NetBSD: raw_ip.c,v 1.161 2016/09/29 12:19:47 roy Exp $ */
 
 /*
  * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -65,7 +65,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: raw_ip.c,v 1.160 2016/08/26 23:12:06 roy Exp $");
+__KERNEL_RCSID(0, "$NetBSD: raw_ip.c,v 1.161 2016/09/29 12:19:47 roy Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_inet.h"
@@ -581,7 +581,7 @@
                error = EADDRNOTAVAIL;
                goto release;
        }
-        if (ifa && (ifatoia(ifa))->ia4_flags & IN6_IFF_NOTREADY) {
+        if (ifa && (ifatoia(ifa))->ia4_flags & IN6_IFF_DUPLICATED) {
                pserialize_read_exit(ss);
                error = EADDRNOTAVAIL;
                goto release;
diff -r 8a60c59e1740 -r dbf4f5e0a360 sys/netinet6/in6_pcb.c
--- a/sys/netinet6/in6_pcb.c    Thu Sep 29 11:38:43 2016 +0000
+++ b/sys/netinet6/in6_pcb.c    Thu Sep 29 12:19:47 2016 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: in6_pcb.c,v 1.149 2016/08/26 19:53:07 roy Exp $        */
+/*     $NetBSD: in6_pcb.c,v 1.150 2016/09/29 12:19:47 roy Exp $        */
 /*     $KAME: in6_pcb.c,v 1.84 2001/02/08 18:02:08 itojun Exp $        */
 
 /*
@@ -62,7 +62,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: in6_pcb.c,v 1.149 2016/08/26 19:53:07 roy Exp $");
+__KERNEL_RCSID(0, "$NetBSD: in6_pcb.c,v 1.150 2016/09/29 12:19:47 roy Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_inet.h"
@@ -271,7 +271,7 @@
                 */
                if (ifa &&
                    ifatoia6(ifa)->ia6_flags &
-                   (IN6_IFF_ANYCAST | IN6_IFF_NOTREADY)) {
+                   (IN6_IFF_ANYCAST | IN6_IFF_DUPLICATED)) {
                        error = EADDRNOTAVAIL;
                        goto out;
                }
diff -r 8a60c59e1740 -r dbf4f5e0a360 sys/netinet6/raw_ip6.c
--- a/sys/netinet6/raw_ip6.c    Thu Sep 29 11:38:43 2016 +0000
+++ b/sys/netinet6/raw_ip6.c    Thu Sep 29 12:19:47 2016 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: raw_ip6.c,v 1.150 2016/08/26 19:53:07 roy Exp $        */
+/*     $NetBSD: raw_ip6.c,v 1.151 2016/09/29 12:19:47 roy Exp $        */
 /*     $KAME: raw_ip6.c,v 1.82 2001/07/23 18:57:56 jinmei Exp $        */
 
 /*
@@ -62,7 +62,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: raw_ip6.c,v 1.150 2016/08/26 19:53:07 roy Exp $");
+__KERNEL_RCSID(0, "$NetBSD: raw_ip6.c,v 1.151 2016/09/29 12:19:47 roy Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_ipsec.h"
@@ -700,7 +700,7 @@
                goto out;
        }
        if (ifa && (ifatoia6(ifa))->ia6_flags &
-           (IN6_IFF_ANYCAST | IN6_IFF_NOTREADY)) {
+           (IN6_IFF_ANYCAST | IN6_IFF_DUPLICATED)) {
                error = EADDRNOTAVAIL;
                goto out;
        }



Home | Main Index | Thread Index | Old Index