mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-10 22:10:17 +01:00
vpn: clear host part of IPv6 routes received from VPN plugin
Kernel would reject adding a route with a destination host part not all zero. NetworkManager generally coerces such routes and there are assertions in place to ensure that. We forgot to ensure that for certain IPv6 routes from VPN plugins. This can cause an assertion failure and wrong behavior. https://gitlab.freedesktop.org/NetworkManager/NetworkManager/-/issues/425 https://gitlab.freedesktop.org/NetworkManager/NetworkManager/-/merge_requests/482 (cherry picked from commitb437bb4a6e) (cherry picked from commitc7586e6388) (cherry picked from commit55c361453b)
This commit is contained in:
parent
0417a5b4d1
commit
75933cd6ff
1 changed files with 2 additions and 0 deletions
|
|
@ -1802,6 +1802,8 @@ nm_vpn_connection_ip6_config_get (NMVpnConnection *self, GVariant *dict)
|
|||
route.metric = route_metric;
|
||||
route.rt_source = NM_IP_CONFIG_SOURCE_VPN;
|
||||
|
||||
nm_utils_ip6_address_clear_host_address (&route.network, &route.network, route.plen);
|
||||
|
||||
/* Ignore host routes to the VPN gateway since NM adds one itself.
|
||||
* Since NM knows more about the routing situation than the VPN
|
||||
* server, we want to use the NM created route instead of whatever
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue