summaryrefslogtreecommitdiffstats
path: root/ipv6nd.c
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2015-01-21 21:02:39 +0000
committerRoy Marples <roy@marples.name>2015-01-21 21:02:39 +0000
commit29211f2503ae42b03e49c9d5065872a82d247049 (patch)
tree02387012bc444be85dea68324074cade5209c832 /ipv6nd.c
parent2e5933998317622c35b5f56d4e2cb20a7ea7decd (diff)
downloaddhcpcd-29211f2503ae42b03e49c9d5065872a82d247049.tar.xz
Ignore RA's from ourself for very badly configured stations.
Diffstat (limited to 'ipv6nd.c')
-rw-r--r--ipv6nd.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/ipv6nd.c b/ipv6nd.c
index d296dda4..257ec78b 100644
--- a/ipv6nd.c
+++ b/ipv6nd.c
@@ -730,6 +730,12 @@ ipv6nd_handlera(struct ipv6_ctx *ctx, struct interface *ifp,
return;
}
+ if (ipv6_iffindaddr(ifp, &ctx->from.sin6_addr)) {
+ syslog(LOG_DEBUG, "%s: ignoring RA from ourself %s",
+ ifp->name, ctx->sfrom);
+ return;
+ }
+
TAILQ_FOREACH(rap, ctx->ra_routers, next) {
if (ifp == rap->iface &&
IN6_ARE_ADDR_EQUAL(&rap->from, &ctx->from.sin6_addr))