On Sat, Dec 08, 2018 at 09:48:52PM +0100, Cybertinus wrote:
> Hello everybody,
> 
> Today I was experimenting with a Bird setup. All the Bird machines are
> CentOS 7.6 VMs running in Virtualbox on my laptop. When I add an OSPF
> virtual link to hook up two area 0's together I get a segfault of Bird 1.6.4
> itself. All the links between the VMs are defined as "Internal Network"
> links. Each connection between routers got it's own internal network, so
> there should be no overlap between those connections.

Hello

Thanks for the thorough bugreport, the attached patch should fix the issue.

> Steps to reproduce:
> 1. Create a bird.conf with the following contents specified in the attached
> bird.conf
> 2. Start Bird
> 3. Add the following line to the area 1 config:
>        virtual link 2.2.2.2;
> 4. Run `birdc configure`
> 5. Observe the following error in your syslog:
> Dec  8 21:01:35 r3 kernel: bird[3469]: segfault at 32 ip 0000000000429fe0 sp
> 00007fff599d3350 error 4 in bird[400000+73

Technically it would crash during reconfiguration when vlink is already
defined, even if the reconfiguration changes nothing.

-- 
Elen sila lumenn' omentielvo

Ondrej 'Santiago' Zajicek (email: [email protected])
OpenPGP encrypted e-mails preferred (KeyID 0x11DEADC3, wwwkeys.pgp.net)
"To err is human -- to blame it on a computer is even more so."
diff --git a/proto/ospf/iface.c b/proto/ospf/iface.c
index 6e3a48b3..feff0f43 100644
--- a/proto/ospf/iface.c
+++ b/proto/ospf/iface.c
@@ -524,6 +524,10 @@ add_nbma_node(struct ospf_iface *ifa, struct nbma_node *src, int found)
 static int
 ospf_iface_stubby(struct ospf_iface_patt *ip, struct ifa *addr)
 {
+  /* vlink cannot be stub */
+  if (ip->type == OSPF_IT_VLINK)
+    return 0;
+
   /* a host address */
   if (addr->flags & IA_HOST)
     return 1;

Reply via email to