mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-07-17 15:26:01 +00:00
vrrpd: only bind to link locals for v6 adverts
Was missing a check to make sure that the v6 address we select as the source IP for advertisements was a link local address Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
This commit is contained in:
parent
6e93585e6f
commit
22e4b6a73d
@ -851,8 +851,13 @@ static int vrrp_bind_to_primary_connected(struct vrrp_router *r)
|
||||
struct listnode *ln;
|
||||
struct connected *c = NULL;
|
||||
for (ALL_LIST_ELEMENTS_RO(ifp->connected, ln, c))
|
||||
if (c->address->family == r->family)
|
||||
if (c->address->family == r->family) {
|
||||
if (r->family == AF_INET6
|
||||
&& IN6_IS_ADDR_LINKLOCAL(&c->address->u.prefix6))
|
||||
break;
|
||||
else if (r->family == AF_INET)
|
||||
break;
|
||||
}
|
||||
|
||||
if (c == NULL) {
|
||||
zlog_err(VRRP_LOGPFX VRRP_LOGPFX_VRID
|
||||
|
Loading…
Reference in New Issue
Block a user