On Sun, Dec 19, 2010 at 09:55:24AM +0100, Matthias Schiffer wrote:
Hi, the attached patch adds support for using link-local v6 addresses for BGP peerings by adding an interface attribute to the BGP protocol. It has been succesfully tested in a Bird<->Quagga configuration on Linux, and with Bird<->Bird using Linux<->Linux and Linux<->FreeBSD.
I know the BGP RFCs (especially 2545) are a bit unclear if this should be allowed, but RFC 4659 suggests it should, and also describes how to set the NEXT_HOP attribute when no global addresses are used.
Anyways, I'd love to see this patch included in Bird. It shouldn't make any difference when you don't use the interface attribute, so it won't have bad influence on people not using this feature, and it makes Bird an alternative to Quagga when you need link-local peering support. :-)
Thanks, i will merge that.
diff --git a/sysdep/bsd/krt-sock.c b/sysdep/bsd/krt-sock.c index 53b30ca..fc73be8 100644 --- a/sysdep/bsd/krt-sock.c +++ b/sysdep/bsd/krt-sock.c @@ -541,7 +541,7 @@ krt_read_addr(struct ks_msg *msg) _I0(ifa.ip) = 0xfe800000; #endif
- if (iface->flags & IF_MULTIACCESS) + if ((iface->flags & IF_MULTIACCESS) || ipa_has_link_scope(ifa.ip)) { ifa.prefix = ipa_and(ifa.ip, ipa_mkmask(masklen));
What is exactly that? Link-local addresses are broken (in BIRD) on non-multiaccess devices on *BSD? -- Elen sila lumenn' omentielvo Ondrej 'SanTiago' Zajicek (email: santiago@crfreenet.org) OpenPGP encrypted e-mails preferred (KeyID 0x11DEADC3, wwwkeys.pgp.net) "To err is human -- to blame it on a computer is even more so."