mirror of
https://github.com/opnsense/src.git
synced 2026-04-15 14:29:58 -04:00
Adding P2P addresses is complex in both ioctl and Netlink. In the ioctl interface, "broadcast" field is the same field as the "peer". In is possible to specify non-p2p address for the p2p interface in IPv6, but not in IPv4. In the Netlink interface, "address" field means "peer" address. As a result, a common notion for the Netlink users is to submit same address/peer for non-P2P interfaces. This change customises mapping the attribute on per-family basis. Specifically, for IPv4 - if the interface is P2P, assume "address" is p2p and "local" is the address. If the interfase is non-p2p, use "local" attribute as the address. If it's not set, use "address" attribute. for IPv6 - start with "local" attribute as the address. If it's not set, use use "address" attribute. If both are set and both are the same, assume non p2p, otherwise add as p2p. MFC after: 2 weeks Reported by: jkim |
||
|---|---|---|
| .. | ||
| route | ||
| netlink.h | ||
| netlink_ctl.h | ||
| netlink_debug.h | ||
| netlink_domain.c | ||
| netlink_generic.c | ||
| netlink_generic.h | ||
| netlink_generic_kpi.c | ||
| netlink_glue.c | ||
| netlink_io.c | ||
| netlink_linux.h | ||
| netlink_message_parser.c | ||
| netlink_message_parser.h | ||
| netlink_message_writer.c | ||
| netlink_message_writer.h | ||
| netlink_module.c | ||
| netlink_route.c | ||
| netlink_route.h | ||
| netlink_snl.h | ||
| netlink_snl_generic.h | ||
| netlink_snl_route.h | ||
| netlink_snl_route_compat.h | ||
| netlink_snl_route_parsers.h | ||
| netlink_var.h | ||