summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClaudio Jeker <claudio@cvs.openbsd.org>2005-05-09 13:53:30 +0000
committerClaudio Jeker <claudio@cvs.openbsd.org>2005-05-09 13:53:30 +0000
commit4d97868c96a906b573a7c39f1c2a8c2a9d69505d (patch)
treee1cbaea91309c970ed55b76229a9418ba6f4b822
parentfa284804b8aaf9a710e6ae988fd22a81699c791e (diff)
Force all as-external routes to point to the router announcing them by
setting the forward address to 0.0.0.0. This is needed as we currently fail to check if the real nexthop is covered by an ospf route -- uncovered routes are ignored by the other routers. OK norby@ tested and requested by Philip Olsson
-rw-r--r--usr.sbin/ospfd/rde.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/usr.sbin/ospfd/rde.c b/usr.sbin/ospfd/rde.c
index 91f3f28e7e2..6efaf0dfafb 100644
--- a/usr.sbin/ospfd/rde.c
+++ b/usr.sbin/ospfd/rde.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rde.c,v 1.14 2005/05/08 19:58:51 claudio Exp $ */
+/* $OpenBSD: rde.c,v 1.15 2005/05/09 13:53:29 claudio Exp $ */
/*
* Copyright (c) 2004, 2005 Claudio Jeker <claudio@openbsd.org>
@@ -998,11 +998,11 @@ orig_asext_lsa(struct kroute *kr, u_int16_t age)
/*
* nexthop -- on connected routes we are the nexthop,
* on all other cases we announce the true nexthop.
+ * XXX this is wrong as the true nexthop may be outside
+ * of the ospf cloud and so unreachable. For now we force
+ * all traffic to be directed to us.
*/
- if (kr->flags & F_CONNECTED)
- lsa->data.asext.fw_addr = 0;
- else
- lsa->data.asext.fw_addr = kr->nexthop.s_addr;
+ lsa->data.asext.fw_addr = 0;
lsa->data.asext.metric = htonl(/* LSA_ASEXT_E_FLAG | */ 100);
/* XXX until now there is no metric */