Commit Graph

3157 Commits

Author SHA1 Message Date
Yu Watanabe c27abcf4fb network: when Gateway=_dhcp4, set several properties based on lease if they are not explicitly specified
Before this commit, event when Gateway=_dhcp4 or _ra is set, the
route was configured with 'protocol static', and other properties
specified by RouteTable=, RouteMTU=, or etc, were ignored.

This commit makes set the route protocol based on the protocol the
gateway address is obtained, and apply other settings if it is not
explicitly specified in the [Route] section.
2020-10-15 07:06:23 +09:00
Yu Watanabe 5bb80a4603 network: determine a [Route] section will be used or not by gateway family instead of route family
By this commit, user can configure dynamic IPv6 Gateway with IPv4
destination.
2020-10-15 07:06:03 +09:00
Yu Watanabe c3d679c43f network: when Gateway=_dhcp, assume gateway family based on other settings 2020-10-15 07:05:58 +09:00
Yu Watanabe b8caa4ef34 network: rename Gateway=_dhcp6 -> Gateway=_ipv6ra 2020-10-15 07:04:02 +09:00
Yu Watanabe 1a3a6309a7 network: rename gateway_from_dhcp -> gateway_from_dhcp_or_ra
As for IPv6 case gateway is given by RA.
2020-10-15 06:58:53 +09:00
Yu Watanabe fd8f865c9f
Merge pull request #17342 from yuwata/network-dhcp-ipv4-acd-fixes
network: fixes several issues in IPv4 DAD for DHCP4
2020-10-14 23:12:41 +09:00
Zbigniew Jędrzejewski-Szmek 540e0bad3e
Merge pull request #17316 from yuwata/network-address-ipv4-peer-issue-17304
network: directly compare with in_addr element for IPv4 case
2020-10-14 15:02:14 +02:00
Yu Watanabe dfc637d0ff
Merge pull request #17341 from yuwata/sd-dhcp-client-fix-eexist-issue-16964
sd-dhcp: make sd_dhcp_client_set_request_option() not return -EEXIST
2020-10-14 18:55:39 +09:00
Yu Watanabe 0e569a439a network: start dynamic addressing clients like DHCP after setting netdevs
The function link_acquire_conf() may make the link state 'configuring'
when DHCP6 PD is enabled. Previously link_acquire_conf() was called
before link_enter_join_netdev(), and thus the assertion in the function
might be triggered.

Fixes #17329.
2020-10-14 10:52:02 +02:00
Yu Watanabe 5431227400 network: update MAC address in IPv4ACD client for DHCP4 2020-10-14 15:38:29 +09:00
Yu Watanabe a7df5cae54 network: also stop IPv4ACD client in link_stop_clients() 2020-10-14 15:38:29 +09:00
Yu Watanabe 66f507e1ba network: stop IPv4ACD client for DHCPv4 when lease is exprired 2020-10-14 15:38:29 +09:00
Yu Watanabe 10fa21c0dc network: move IPv4ACD client for DHCPv4 from Network to Link object
A .network file may matches multiple interfaces.
2020-10-14 15:38:29 +09:00
Yu Watanabe 8ff85383b4 network: voidify link_stop_clients() in link_enter_failed() 2020-10-14 15:38:29 +09:00
Yu Watanabe 4eb6a826b8 network: drop unused condition 2020-10-14 13:02:46 +09:00
Yu Watanabe b1476b5210 network: constify arguments 2020-10-13 20:30:38 +09:00
Yu Watanabe fe841414ef network: read peer address, label, broadcast from rtnl message
Then, Address objects in Network and Link can be easily compared by
address_equal().
2020-10-13 20:30:35 +09:00
Yu Watanabe 9b9c5fff16 network: directly compare with in_addr element for IPv4 case
When peer address is set, address_compare_func() (or address_equal())
does not work in link_is_static_address_configured(), as an Address object
stored in a Link does not contain peer addresses. So, we need to also
compare with in_addr element for IPv4 case.

Fixes #17304.
2020-10-13 20:30:16 +09:00
Frantisek Sumsal d46b79bbe0 tree-wide: drop if braces around single line expressions as well 2020-10-09 15:11:55 +02:00
Frantisek Sumsal d7a0f1f4f9 tree-wide: assorted coccinelle fixes 2020-10-09 15:02:23 +02:00
Zbigniew Jędrzejewski-Szmek 081b300976 networkd: add assert to appease coverity
The code was OK, but not obviously so. Let's add an assert to help a
human or nonhuman reader figure it out.

Coverity CID#1433224.
2020-10-09 08:14:54 +02:00
Yu Watanabe ceea6c1aff network: introduce IPV4_ADDRESS_FMT_STR macro
This also moves ADDRESS_FMT_VAL() macro to networkd-address.h, and
renames it to IPV4_ADDRESS_FMT_VAL().
2020-10-08 02:51:23 +09:00
Yu Watanabe d442bb3728 network: make Gateway= in [Route] section accept an empty string 2020-10-08 02:51:23 +09:00
Yu Watanabe d306d1d0ca network: introduce Gateway=_dhcp4 and _dhcp6, and deprecate "_dhcp"
Fixes #17249.
2020-10-08 02:51:23 +09:00
Yu Watanabe f9bb333832 network: manage multipath routes separately 2020-10-08 02:51:23 +09:00
Yu Watanabe 2fe1d557e5 sd-netlink: introduce rtattr_read_nexthop() 2020-10-08 02:51:23 +09:00
Yu Watanabe d6ad41e27d network: free Route object when route_remove() fails
When route_remove() succeeds, the Route object will be freed later by
manager_rtnl_process_route().
2020-10-08 02:51:23 +09:00
Yu Watanabe 423c249c2e network: constify arguments 2020-10-08 02:51:23 +09:00
Yu Watanabe 6dd5398137 network: support IPv4 route with IPv6 gateway 2020-10-08 00:06:19 +09:00
Yu Watanabe ad208fac73 network: also manage routes without RTA_OIF attribute 2020-10-07 15:22:10 +02:00
Yu Watanabe fd7701bf31 network: ignore Scope= for IPv6 routes as it will not be used 2020-10-07 15:22:10 +02:00
Yu Watanabe 8973df5c42 network: set default priority for IPv6 routes
See inet6_rtm_newroute() in kernel's net/ipv6/route.c.
2020-10-07 15:22:09 +02:00
Yu Watanabe 13ffa39f8e network: rename network_verify_xxx() -> network_drop_invalid_xxx()
As 'verify' implies a boolean result.
2020-10-07 03:22:03 +09:00
Yu Watanabe 494b6b43cb network: fix masquerade setting logic
Previously, address_establish() took Address object stored in Network
object. And address_release() took Address object stored in Link
object. Thus, address_release() always did nothing.
2020-10-07 03:13:26 +09:00
Yu Watanabe cd1caf30c0 network: always use RT_SCOPE_HOST for IPv4 loopback addresses
For IPv6 case, use RT_SCOPE_HOST only when scope is not explicitly specified.
2020-10-07 03:13:18 +09:00
Yu Watanabe d93d655c40 network: update MAC address in IPv4 ACD clients
When the MAC address of a link is updated, an address on the link may
be under checking address duplication. Or, (currently such code is not
implemented yet, but) address duplication check may be restarted later.
For that case, the IPv4 ACD clients must use the new updated MAC address.
2020-10-07 02:59:34 +09:00
Yu Watanabe 490ccbd5e5 network: configure IPv4 DAD per link address
Previously, IPv4 DAD is configured in each Address object stored in
Network object. If a .network file matches multipe links, then it causes
an assertion. To prevent it, now IPv4 DAD is configured in each Address
object belogs to Link object.
2020-10-07 02:57:58 +09:00
Yu Watanabe 693ec5ca83 network: constify one argument 2020-10-07 02:57:54 +09:00
Yu Watanabe cde1f0e8fc network: introduce address_copy() 2020-10-07 02:54:01 +09:00
Yu Watanabe eaff204f09 network: do not update Address::flags in address_configure() 2020-10-07 02:50:51 +09:00
Yu Watanabe f5ee7d74af network: fix indentation 2020-10-07 02:50:51 +09:00
Yu Watanabe 4cf8500067 network: use sd_event stored in Manager 2020-10-07 02:50:51 +09:00
Yu Watanabe 2ffd6d73f9 network: check feature is enabled in xxx_configure() 2020-10-07 02:50:51 +09:00
Yu Watanabe 51f5dfd8ba network: move link_enumerate_ipv6_tentative_addresses() 2020-10-07 02:50:51 +09:00
Yu Watanabe acc9fc2f51 network: drop unused function 2020-10-07 02:50:51 +09:00
Yu Watanabe 5e0534f1c1 network: move sysctl related functions to networkd-sysctl.c 2020-10-07 02:50:51 +09:00
Yu Watanabe be9363ccab network: introduce radv_update_mac() 2020-10-07 02:50:51 +09:00
Yu Watanabe eebba6dc24 network: introduce dhcp6_update_mac() 2020-10-07 02:50:51 +09:00
Yu Watanabe d947f7f977 network: introduce dhcp4_update_mac() 2020-10-07 02:50:50 +09:00
Yu Watanabe a3adb4a6a2 network: introduce ipv4ll_update_mac() 2020-10-07 02:50:50 +09:00
Yu Watanabe 5460bde5c5 network: introduce link_serialize_dhcp6_client() 2020-10-07 02:50:50 +09:00
Yu Watanabe ca21a19a2e network: introduce link_serialize_ipv4ll() 2020-10-07 02:50:50 +09:00
Yu Watanabe daad60d19e network: introduce link_deserialize_ipv4ll() 2020-10-07 02:50:50 +09:00
Yu Watanabe 571eeba909 network: introduce link_deserialize_dhcp4() 2020-10-07 02:50:50 +09:00
Yu Watanabe bbe694f91f network: introduce network_verify_sr_iov() 2020-10-07 02:50:50 +09:00
Yu Watanabe f3a3ff2762 network: move link_configure_sr_iov() 2020-10-07 02:50:50 +09:00
Yu Watanabe 209af9a67a network: introduce network_verify_traffic_control() 2020-10-07 02:50:50 +09:00
Yu Watanabe 200543791a network: move link_configure_traffic_control() 2020-10-07 02:50:50 +09:00
Yu Watanabe 34d7f2c99e network: merge link_set_bridge_vlan() and br_vlan_configure() 2020-10-07 02:50:50 +09:00
Yu Watanabe 256c75fd1f network: move DUID related functions 2020-10-07 02:50:50 +09:00
Yu Watanabe 086b8853d1 network: move link_radv_enabled() 2020-10-07 02:50:50 +09:00
Yu Watanabe 5ae0fb7fb7 network: move link_dhcp4_server_enabled() 2020-10-07 02:50:50 +09:00
Yu Watanabe 062c020fb6 network: move link_ipv6_accept_ra_enabled() 2020-10-07 02:50:50 +09:00
Yu Watanabe 6f7a17ff0c network: unify link_ipv{4,6}_forward_enabled() 2020-10-07 02:50:50 +09:00
Yu Watanabe 67c311abd3 network: unify link_dhcp{4,6}_enabled() 2020-10-07 02:50:50 +09:00
Yu Watanabe ac49887e8c network: move link_get_xxx_route_table() 2020-10-07 02:50:50 +09:00
Yu Watanabe bfbf150ee6 network: manage address pools by OrderedSet 2020-10-07 02:50:50 +09:00
Yu Watanabe 3fe721c674 network: drop unused argument 2020-10-07 02:50:50 +09:00
Yu Watanabe ed76f58521 network: move functions related to address pool 2020-10-07 02:50:50 +09:00
Yu Watanabe 093e35334d network: header cleanup 2020-10-07 02:50:50 +09:00
Yu Watanabe 67a58eb378 network: make several functions static 2020-10-07 02:50:50 +09:00
Yu Watanabe aa651e88de network: manage addresses from pool by Set 2020-10-07 02:50:50 +09:00
Yu Watanabe 9cd9fc8f44 network: drop list of static addresses
[Address] sections are managed by both LIST and Hashmap. Let's drop the
list and manage them by OrderedHashmap.
2020-10-07 02:50:50 +09:00
Yu Watanabe 7818f8589a network: make address_free() return NULL 2020-10-07 02:50:50 +09:00
Yu Watanabe 2488e4d934 network: introduce link_stop_ipv4_dad() 2020-10-07 02:50:50 +09:00
Yu Watanabe b87d6a8284 network: move link_configure_ipv4_dad() 2020-10-07 02:50:50 +09:00
Yu Watanabe da4d3a612d network: introduce link_deserialize_addresses() 2020-10-07 02:50:50 +09:00
Yu Watanabe 3b31e2b718 network: introduce link_serialize_addresses() 2020-10-07 02:50:50 +09:00
Yu Watanabe 32400c2ff0 network: introduce network_verify_addresses() 2020-10-07 02:50:50 +09:00
Yu Watanabe 9a0ad16b26 network: update log messages
And drop unnecessary log for in_addr_to_string(), as its result is used
only for the consequent logs.
2020-10-07 02:49:17 +09:00
Yu Watanabe e1fc2c4371 network: move manager_rtnl_process_address() 2020-10-07 02:44:43 +09:00
Yu Watanabe d7fbb9f50c network: introduce link_drop_addresses() 2020-10-07 02:44:43 +09:00
Yu Watanabe f8f2f880d4 network: introduce link_drop_foreign_addresses() 2020-10-07 02:44:43 +09:00
Yu Watanabe 682c65b04c network: introduce link_set_addresses() 2020-10-07 02:44:43 +09:00
Yu Watanabe e2263711ba network: cleanup networkd-route.h 2020-10-07 02:44:43 +09:00
Yu Watanabe 2a54a0446b network: drop list of static routes
[Route] sections are managed by both LIST and Hashmap. Let's drop the
list.
2020-10-07 02:44:43 +09:00
Yu Watanabe 833f3663a0 network: introduce hashmap_find_free_section_line() 2020-10-07 02:44:43 +09:00
Yu Watanabe 74154c2e28 network: make several functions static 2020-10-07 02:44:43 +09:00
Yu Watanabe d9940a3f8a network: introduce network_verify_routes() 2020-10-07 02:44:42 +09:00
Yu Watanabe 565194127a network: introduce link_serialize_routes() 2020-10-07 02:44:42 +09:00
Yu Watanabe 731ff05b32 network: introduce link_deserialize_routes() 2020-10-07 02:44:42 +09:00
Yu Watanabe 62f0ea5fae network: introduce link_drop_routes() 2020-10-07 02:44:42 +09:00
Yu Watanabe 779804dd60 network: introduce link_drop_foreign_routes() 2020-10-07 02:44:42 +09:00
Yu Watanabe 169948e9d2 network: make route_free() return NULL 2020-10-07 02:44:42 +09:00
Yu Watanabe 4468f01b67 network: move manager_rtnl_process_route() 2020-10-07 02:44:42 +09:00
Yu Watanabe 141318f777 network: move link_request_set_routes() 2020-10-07 02:44:42 +09:00
Yu Watanabe be023c670b network: make network_get_ipv6_dns() always set return value on success 2020-10-07 02:44:42 +09:00
Yu Watanabe a8d4a21091 network: fix indentation 2020-10-07 02:44:42 +09:00
Yu Watanabe b5ce40472c network: cleanup networkd-radv.h 2020-10-07 02:44:42 +09:00
Yu Watanabe 1a7deb2fcf network: introduce network_verify_prefix() and network_verify_route_prefix() 2020-10-07 02:44:42 +09:00
Yu Watanabe d30081c24e network: also check route prefixes are configured 2020-10-07 02:44:42 +09:00
Yu Watanabe ecb0e85ea9 network: drop redundant list of prefixes and route prefixes 2020-10-07 02:44:42 +09:00
Yu Watanabe 064dfb05f0 network: make prefix_free() and route_prefix_free() return NULL 2020-10-07 02:44:42 +09:00
Yu Watanabe 87851e0feb network: warn if IPv6ProxyNDPAddress= is set and IPv6ProxyNDP= is disabled 2020-10-07 02:44:42 +09:00
Yu Watanabe fd773a11d8 network: propagate errors in ipv6_proxy_ndp_set()
And ignore IPv6ProxyNDPAddress= settings if proxy_ndp is zero.
2020-10-07 02:44:42 +09:00
Yu Watanabe 5823a48993 network: drop networkd-ipv6-proxy-ndp.h from networkd-network.h 2020-10-07 02:44:42 +09:00
Yu Watanabe c16b58217a network: rename ipv6_proxy_ndp_addresses_configure() -> link_set_ipv6_proxy_ndp_addresses() 2020-10-07 02:44:42 +09:00
Yu Watanabe d349f5026e network: drop struct IPv6ProxyNDPAddress
Its only important value is in6_addr. So, let's just use struct in6_addr
and drop IPv6ProxyNDPAddress.
2020-10-07 02:44:42 +09:00
Yu Watanabe a8c82f90e7 network: move functions 2020-10-07 02:44:42 +09:00
Yu Watanabe dbf6319691 network: cleanup networkd-mdb.h 2020-10-07 02:44:42 +09:00
Yu Watanabe ee4522ce86 network: introduce network_verify_mdb_entries() 2020-10-07 02:44:42 +09:00
Yu Watanabe 03c9738e1d network: drop list of bridge MDB entries
[BridgeMDB] sections are managed by LIST and Hashmap, and they contins
the completely same information. Let's drop the list.
2020-10-07 02:44:42 +09:00
Yu Watanabe 8c06da1cd1 network: move mdb_entry_free() and friends 2020-10-07 02:44:42 +09:00
Yu Watanabe ee446d57b8 network: cleanup networkd-fdb.h 2020-10-07 02:44:42 +09:00
Yu Watanabe 75ffb011b0 network: drop unused fdb_ntf_flags_to_string() 2020-10-07 02:44:42 +09:00
Yu Watanabe e6ad630d77 network: introduce network_verify_fdb_entries() 2020-10-07 02:44:42 +09:00
Yu Watanabe 5bb4542b0c network: move link_set_bridge_fdb() 2020-10-07 02:44:42 +09:00
Yu Watanabe 62ed9442bf network: drop list of bridge FDB entries
[BridgeFDB] sections are managed by both LIST and Hashmap, and they
contains the completely same information. Let's drop the list.
2020-10-07 02:44:42 +09:00
Yu Watanabe df3a18f87f network: make fdb_entry_free() return NULL 2020-10-07 02:44:42 +09:00
Yu Watanabe fb486c9082 network: cleanup networkd-address-label.h 2020-10-07 02:44:42 +09:00
Yu Watanabe fe2bc17ca7 network: introduce link_set_address_labels() 2020-10-07 02:44:42 +09:00
Yu Watanabe ab316813ea network: introduce network_verify_address_labels() 2020-10-07 02:44:42 +09:00
Yu Watanabe cae418a306 network: make address_label_free() return NULL 2020-10-07 02:44:42 +09:00
Yu Watanabe d6a2a0f9a7 network: drop list of static address labels
[IPv6AddressLabel] sections are managed by both LIST and Hashmap.
Let's drop list, as they store the completely same information.
2020-10-07 02:44:42 +09:00
Yu Watanabe 64753f354d network: make neighbor_free() return NULL 2020-10-07 02:44:42 +09:00
Yu Watanabe 78ada14f25 network: introduce network_verify_neighbors() 2020-10-07 02:44:42 +09:00
Yu Watanabe 5904833659 network: introduce neighbor_drop_{,foreign_}neighbors() 2020-10-07 02:44:42 +09:00
Yu Watanabe 1939ebeb89 network: cleanup headers in networkd-neighbor.[ch] 2020-10-07 02:44:42 +09:00
Yu Watanabe 9be0b3abc2 network: drop unused arguments 2020-10-07 02:44:42 +09:00
Yu Watanabe 0d6e933eac network: make several functions static 2020-10-07 02:44:42 +09:00
Yu Watanabe 19f8cffce1 network: make neighbor_{add,get}() takes Neighbor object 2020-10-07 02:44:42 +09:00
Yu Watanabe b0ba6938df network: drop list of static neighbors
[Neighbor] sections are managed by both LIST and Hashmap.
Let's drop list, as they store the completely same information.
2020-10-07 02:44:42 +09:00
Yu Watanabe eab052d2b3 network: move manager_rtnl_process_neighbor() to networkd-neighbor.c 2020-10-07 02:44:42 +09:00
Yu Watanabe 58f1fe9af9 network: move link_request_set_neighbors() to networkd-neighbor.c 2020-10-07 02:44:42 +09:00
Yu Watanabe fceee7cc7e network: move functions 2020-10-07 02:44:42 +09:00
Yu Watanabe 0992f9fb0e network: introduce network_verify_nexthops() 2020-10-07 02:44:42 +09:00
Yu Watanabe f96f4ebc85 network: use netlink_message_read_in_addr_union() 2020-10-07 02:44:42 +09:00
Yu Watanabe 47a277f18b network: use log_link_xxx() at more places 2020-10-07 02:39:51 +09:00
Yu Watanabe 8c11221879 network: drop NextHop::oif and always use link ifindex 2020-10-07 02:39:51 +09:00
Yu Watanabe cf5a228f7b network: slightly shorten nexthop_compare_func() 2020-10-07 02:39:51 +09:00
Yu Watanabe 75156ccbdc network: cleanup headers included in networkd-nexthop.h 2020-10-07 02:39:51 +09:00
Yu Watanabe b82663ddee network: drop list of static nexthops
[NextHop] sections are managed by both LIST and Hashmap.
Let's drop list, as they store the completely same information.
2020-10-07 02:39:51 +09:00
Yu Watanabe 8d7b137a82 network: drop unused nexthop_remove() and nexthop_equal() 2020-10-07 02:39:51 +09:00
Yu Watanabe 4736035aaa network: make several functions static 2020-10-07 02:39:51 +09:00
Yu Watanabe 454c87b5d5 network: move manager_rtnl_process_nexthop() to networkd-nexthop.c 2020-10-07 02:39:51 +09:00
Yu Watanabe c133770a6b network: move link_request_set_nexthop() to networkd-nexthop.c 2020-10-07 02:39:51 +09:00
Yu Watanabe 446aaaf35f network: introduce helper function to enumerate information using netlink 2020-10-07 02:39:13 +09:00
Yu Watanabe d08ed5a1fd network: specify all known attributes when removing routing policy rules
Otherwise, routing_policy_rule_remove() may removes unintended rule.
2020-10-07 02:36:29 +09:00
Yu Watanabe 5a82104bf3 network: add missing "else" 2020-10-07 02:36:29 +09:00
Yu Watanabe 6f3337277f network: drop unused element 2020-10-07 02:36:29 +09:00
Yu Watanabe 50a3682f1e network: introduce network_verify_routing_policy_rules() 2020-10-07 02:36:29 +09:00
Yu Watanabe f1828a222a network: make routing_policy_rule_new() static 2020-10-07 02:36:29 +09:00
Yu Watanabe 51a0dc4a15 network: move manager_rtnl_process_rule() to networkd-routing-policy-rule.[ch] 2020-10-07 02:36:29 +09:00
Yu Watanabe 8dfed23d92 network: use typesafe macro netlink_add_match() 2020-10-07 02:36:29 +09:00
Yu Watanabe 0d7d377b80 network: move log_message_warning_errno() to networkd-util.h 2020-10-07 02:36:29 +09:00
Yu Watanabe ca183bf8fd network: drop list of static routing policy rules
[RoutingPolicyRule] sections are managed by both LIST and Hashmap.
Let's drop list.
2020-10-07 02:36:29 +09:00
Yu Watanabe 02e9f4e536 network: do not duplicate rule if Family=both 2020-10-07 02:36:29 +09:00
Yu Watanabe b0815fa499 network: make routing_policy_rule_free() returns NULL 2020-10-07 02:36:29 +09:00
Yu Watanabe 816ef8d1da network: add more logs on loading routing policy rules failure
And reduce scope of variables.
2020-10-07 02:36:24 +09:00
Yu Watanabe eb3445ce93 network: reduce scope of variables 2020-10-06 00:51:01 +09:00
Yu Watanabe ddc9df3183 network: drop routing_policy_rule_make_local()
Its error handling was bogus...
2020-10-06 00:51:01 +09:00
Yu Watanabe 7532b88808 network: make several functions static 2020-10-06 00:51:01 +09:00
Yu Watanabe c0ec474675 network: move link_request_set_routing_policy() 2020-10-06 00:51:01 +09:00
Yu Watanabe fef160b5ab network: limit InitialCongestionWindow= and InitialAdvertisedReceiveWindow= value
Strivtly speaking, this breaks backward compatibility. But setting
too large value into them, then their networking easily breaks.
Note that typically 100 for them is event too large. So, ommiting the
values equal or higher than 1024, and dropping support of k, M, and G
suffixes is OK for normal appropriate use cases.

See discussion in #16643.
2020-09-29 13:55:17 +09:00
Zbigniew Jędrzejewski-Szmek 05d418fed9
Merge pull request #17085 from yuwata/network-configure-mdb-entries-on-bridge-master
network: allow to configure mdb entries on bridge master
2020-09-18 13:06:44 +02:00
Yu Watanabe 1034044260
Merge pull request #15050 from ssahani/fq-pie
network: tc: add support for FQ-PIE packet scheduler
2020-09-18 03:50:02 +09:00
Yu Watanabe dc0e90d2e0
Merge pull request #16929 from ssahani/network-bare-udp
network: introduce Bare UDP Tunnelling
2020-09-17 20:34:15 +09:00
Yu Watanabe 1797240104 network: old kernel may not support to configure bridge MDB entries on bridge master 2020-09-17 18:15:22 +09:00
Yu Watanabe a55100e66c network: allow to configure bridge MDB entries on bridge master 2020-09-17 18:12:40 +09:00
Yu Watanabe fdeecf7bba network: tc: refuse to set 0 for FlowQueuePIE.PacketLimit= 2020-09-17 17:16:49 +09:00
Susant Sahani 8f6b6d7091 network: TC - introduce fq pie
see https://patchwork.ozlabs.org/patch/1233253/
2020-09-17 17:12:07 +09:00
Susant Sahani a9b8450bd4 network: Allow vxlan to be created without .network file 2020-09-17 15:49:36 +09:00
Yu Watanabe b0486c732a network: refuse to configure IPv4LL for bareudp netdev 2020-09-17 15:18:18 +09:00
Susant Sahani e6980c7270 network: Introduce bare UDP 2020-09-17 15:05:58 +09:00
Yu Watanabe 8e412d64ce network: add debug message for configuring MDB entries 2020-09-17 00:04:22 +09:00
Yu Watanabe 1f24158971 network: configure bridge MDB entries after bridge has carrier 2020-09-17 00:04:22 +09:00
Yu Watanabe 46205ffcdf network: drop [BridgeMDB] entries if Bridge= is not set 2020-09-17 00:04:22 +09:00
Yu Watanabe 03ae449015 network: check MulticastGroupAddress= is neither a local multicast address nor all nodes address 2020-09-17 00:04:22 +09:00
Yu Watanabe 5fb16c7c77 network: drop unnecessary headers 2020-09-17 00:04:22 +09:00
Yu Watanabe 6c9ebb7a90 network: move functions in networkd-mdb.c 2020-09-17 00:04:22 +09:00
Yu Watanabe 41bed67613
Merge pull request #16998 from zonque/networkd/mdb
network: add support for setting MDB entries
2020-09-15 16:30:39 +09:00
Frantisek Sumsal 69e3234db7 tree-wide: fix typos found by codespell
Reported by Fossies.org
2020-09-14 15:32:37 +02:00
Yu Watanabe 85b6a8110d network: do not add prefix to RA if radv is not configured
Fixes #17017.
2020-09-11 19:28:46 +02:00
Daniel Mack 3db468ea87 network: add support for setting MDB entries
Multicast snooping enabled bridges maintain a database for multicast
port memberships to decide which mulicast packet is supposed to
egress on which port.

This patch teaches networkd to add entries to this database manually
by adding `[BridgeMDB]` sections to `.network` configuration files.
2020-09-10 18:55:15 +02:00
Lennart Poettering 6ae05c9b14
Merge pull request #16947 from keszybz/socket-parsing-rework
Socket parsing rework
2020-09-10 16:47:37 +02:00
Zbigniew Jędrzejewski-Szmek f29d38b7d4
Merge pull request #17003 from yuwata/conf-parser-downgrade-log-level
tree-wide: downgrade log level in conf-parsers
2020-09-10 15:43:29 +02:00
Yu Watanabe 17d2b2e4ef network: replace FRA_IFNAME -> FRA_IIFNAME
No functional change, as FRA_IFNAME is an alias of FRA_IIFNAME.
2020-09-10 18:57:07 +09:00
Yu Watanabe 2102d33cfb network: also process RTM_NEWRULE or RTM_DELRULE message which does not contain src and dst addresses
Fixes #16784.
2020-09-10 18:57:07 +09:00
Yu Watanabe bd1000b4a0 network: fix the default mask for FirewallMark=
And always send FRA_FWMASK if FirewallMark= is set.

C.f. b8964ed9fa

Partially fixes #16784.
2020-09-10 18:56:18 +09:00
Yu Watanabe c2d6fcb147 network: do not assign return value if the parse_fwmark_fwmask() fails
This also removes redundant logs, and makes input string not copied if
it does not contain '/'.
2020-09-10 18:19:03 +09:00
Yu Watanabe d85b0d69f1 network: add debug log for removing routing policy rules 2020-09-10 18:19:03 +09:00
Yu Watanabe 755dbda355 network: also logs priority of routing policy rules 2020-09-10 18:18:59 +09:00
Yu Watanabe b6c7c4a87b network: update log message for rtnl messages 2020-09-10 18:14:24 +09:00
Yu Watanabe e3489e96b3 network: slightly update log message 2020-09-10 13:59:04 +09:00
Yu Watanabe 2ca601d8cb network do not ignore OOM error in config_parse_macsec_key_id() 2020-09-10 13:59:04 +09:00
Yu Watanabe 696c0832e2 network: use _cleanup_ attribute at one more place 2020-09-10 13:59:04 +09:00
Yu Watanabe a8a50f4fb7 network: do not ignore OOM error in wireguard_decode_key_and_warn() 2020-09-10 13:59:04 +09:00
Yu Watanabe 02241e4339 network: unify config_parse_wireguard_public_key() and config_parse_wireguard_preshared_key() 2020-09-10 13:57:39 +09:00
Zbigniew Jędrzejewski-Szmek 2313524aa0 basic: convert ifname_valid_full() to take flags and allow numeric interfaces 2020-09-10 00:46:44 +02:00
Lennart Poettering e5f1b999eb network: don't fail on various config parse errors
We typically don't fail on config parse errors (to maximize compat),
let's not do this in these cases either.
2020-09-09 23:43:16 +02:00