]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
ND6 and DHCPv6 should only work on active interfaces.
authorRoy Marples <roy@marples.name>
Thu, 17 Dec 2015 09:08:09 +0000 (09:08 +0000)
committerRoy Marples <roy@marples.name>
Thu, 17 Dec 2015 09:08:09 +0000 (09:08 +0000)
dhcp6.c
ipv6nd.c

diff --git a/dhcp6.c b/dhcp6.c
index eef7e4b4120918c7c3ea7b428e9291a24ce70809..633925d714ccc0959c81f607c2d8e8976569927d 100644 (file)
--- a/dhcp6.c
+++ b/dhcp6.c
@@ -2692,7 +2692,9 @@ dhcp6_handledata(void *arg)
        }
 
        TAILQ_FOREACH(ifp, dctx->ifaces, next) {
-               if (ifp->index == (unsigned int)pkt.ipi6_ifindex)
+               if (ifp->active &&
+                   ifp->index == (unsigned int)pkt.ipi6_ifindex &&
+                   ifp->options->options & DHCPCD_DHCP6)
                        break;
        }
        if (ifp == NULL) {
index 8ff487c87630ab2de8d305f9559c0bf59a21a702..3282267b69446a406153beabe878b59b0c573011 100644 (file)
--- a/ipv6nd.c
+++ b/ipv6nd.c
@@ -1614,7 +1614,8 @@ ipv6nd_handledata(void *arg)
        }
 
        TAILQ_FOREACH(ifp, dctx->ifaces, next) {
-               if (ifp->index == (unsigned int)pkt.ipi6_ifindex) {
+               if (ifp->active &&
+                   ifp->index == (unsigned int)pkt.ipi6_ifindex) {
                        if (!(ifp->options->options & DHCPCD_IPV6))
                                return;
                        break;