kernel-netlink: Respect kernel routing priorities for IKE routes
authorMartin Willi <martin@revosec.ch>
Thu, 15 Jan 2015 14:05:42 +0000 (15:05 +0100)
committerMartin Willi <martin@revosec.ch>
Tue, 3 Mar 2015 12:42:41 +0000 (13:42 +0100)
commit6b57790270fb07c579315c70ecce34f8ad9a4d63
treef3a57502ea8e5c1cf6b08b3be0020acd11ff4873
parent4dc72f5e575aba18bf8ddfbb6574e07474bc3948
kernel-netlink: Respect kernel routing priorities for IKE routes

If a system uses routing metrics, we should honor them when doing (manual)
routing lookups for IKE. When enumerating routes, the kernel reports priorities
with the RTA_PRIORITY attribute, not RTA_METRICS. We prefer routes with a
lower priority value, and fall back to longest prefix match priorities if
the priority value is equal.
src/libhydra/plugins/kernel_netlink/kernel_netlink_net.c