summaryrefslogtreecommitdiff
path: root/sbin
diff options
context:
space:
mode:
authorFlorian Obser <florian@cvs.openbsd.org>2018-04-23 13:49:05 +0000
committerFlorian Obser <florian@cvs.openbsd.org>2018-04-23 13:49:05 +0000
commitb62b930c1224dc65501e25e694cfff04259448c2 (patch)
treecba90fa9f6713cab788304c8c92c67d86081417d /sbin
parent98bfe98e23cf77217c840f9b4d662c56823a3c85 (diff)
While privacy addresses do just expire and never get renewed we need
to solicit a router advertisment shortly before their pltime runs out so that we generate a new one. Reported by naddy@. OK benno@
Diffstat (limited to 'sbin')
-rw-r--r--sbin/slaacd/engine.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/sbin/slaacd/engine.c b/sbin/slaacd/engine.c
index 734f1820f52..184b349f650 100644
--- a/sbin/slaacd/engine.c
+++ b/sbin/slaacd/engine.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: engine.c,v 1.23 2018/03/13 13:57:07 florian Exp $ */
+/* $OpenBSD: engine.c,v 1.24 2018/04/23 13:49:04 florian Exp $ */
/*
* Copyright (c) 2017 Florian Obser <florian@openbsd.org>
@@ -2087,12 +2087,16 @@ address_proposal_timeout(int fd, short events, void *arg)
log_debug("%s: removing address proposal", __func__);
break;
}
- if (addr_proposal->privacy)
- break; /* just let it expire */
engine_imsg_compose_frontend(IMSG_CTL_SEND_SOLICITATION,
0, &addr_proposal->if_index,
sizeof(addr_proposal->if_index));
+
+ if (addr_proposal->privacy) {
+ addr_proposal->next_timeout = 0;
+ break; /* just let it expire */
+ }
+
tv.tv_sec = addr_proposal->next_timeout;
tv.tv_usec = arc4random_uniform(1000000);
addr_proposal->next_timeout *= 2;