bird/sysdep/bsd
Ondrej Zajicek (work) a39cd2cc0b BSD: Assume onlink flag on ifaces with only host addresses
The BSD kernel does not support the onlink flag and BIRD does not use
direct routes for next hop validation, instead depends on interface
address ranges. We would like to handle PtMP cases with only host
addresses configured, like:

  ifconfig wg0 192.168.0.10/32
  route add 192.168.0.4 -iface wg0
  route add 192.168.0.8 -iface wg0

To accept BIRD routes with onlink next-hop, like:

  route 192.168.42.0/24 via 192.168.0.4%wg0 onlink

BIRD would dismiss the route when receiving from the kernel, as the
next-hop 192.168.0.4 is not part of any interface subnet and onlink
flag is not kept by the BSD kernel.

The commit fixes this by assuming that for routes received from the
kernel, any next-hop is onlink on ifaces with only host addresses.

Thanks to Stefan Haller for the original patch.
2021-12-27 21:00:04 +01:00
..
krt-sock.c BSD: Assume onlink flag on ifaces with only host addresses 2021-12-27 21:00:04 +01:00
krt-sock.Y Config: Dropping CF_ADDTO. 2018-06-26 14:29:03 +02:00
krt-sys.h Nest: Added const to ea_show just to declare that this shouldn't really change anything 2020-05-01 15:19:12 +02:00
Makefile Unit Testing for BIRD 2016-11-09 16:36:34 +01:00
setkey.h Configuration strings are constant. 2020-04-09 15:37:14 +02:00
sysio.h Configuration strings are constant. 2020-04-09 15:37:14 +02:00