summaryrefslogtreecommitdiff
path: root/src/network/networkd-dhcp-common.c
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #25166 from yuwata/network-router-preferenceLuca Boccassi2022-10-311-8/+65
|\ | | | | network: adjust route metric based on router preference
| * network: adjust route priority based on preferenceYu Watanabe2022-10-281-8/+65
| | | | | | | | | | | | | | | | Even if different preference is specified, the kernel merges multiple routes with the same preference. This is problematic when a network has multiple routers. Fixes #25138.
* | network: make RouteTable= also accept route table nameYu Watanabe2022-10-281-1/+2
|/
* tree-wide: use ASSERT_PTR moreDavid Tardon2022-09-131-30/+13
|
* network: replace usage of sd_bus_call_method_async() to ↵williamsumendap2022-08-131-4/+3
| | | | bus_call_method_async() (#24290)
* network: dhcp4: disable DHCPv4 client on interfaces with non-supported typesYu Watanabe2022-07-141-0/+4
| | | | Replaces f42d41cc5f9cd8cac538a1c30fda04d346b5bae2.
* Revert "network: configure DHCP clients after MAC address is assigned"Yu Watanabe2022-07-141-7/+0
| | | | | | | | | This reverts commit f42d41cc5f9cd8cac538a1c30fda04d346b5bae2. DHCPv6 client does not require MAC address. DHCPv4 client will be handled in a different way in a later commit. Partially fixes #23546.
* Fix "link-local" language inconsistenciesSebastian Pucilowski2022-03-311-1/+1
| | | | | | "Link-local" and "link local" are used throughout man pages and program output, with the former used far more than the latter. This commit makes it consistent throughout the project.
* network: coding style fixesYu Watanabe2022-02-091-6/+6
|
* network: configure DHCP clients after MAC address is assignedYu Watanabe2022-01-311-0/+7
| | | | Prompted by #20090.
* network: dhcp-pd: rename [DHCPv6PrefixDelegation] -> [DHCPPrefixDelegation]Yu Watanabe2021-12-071-3/+3
| | | | | | | This just changes the names of settings, variables, functions, files, and so on. No functionality is changed. Preparation for supporting 6rd.
* network: dhcp6pd: always use main route table for unreachable routeYu Watanabe2021-12-071-34/+4
| | | | This mostly reverts e47bcb7d0b2cb07c5c594e374baeb061bb7f88ba.
* network: dhcp6pd: fix copy-and-paste errorYu Watanabe2021-12-061-1/+1
|
* network: dhcp6: introduce UplinkInterface= for DHCP6 prefix delegationYu Watanabe2021-10-261-1/+13
|
* network: move config_parse_uplink() to networkd-dhcp-common.[ch]Yu Watanabe2021-10-261-0/+66
|
* tree-wide: mark set-but-not-used variables as unused to make LLVM happyFrantisek Sumsal2021-09-151-2/+4
| | | | | | | | | | | | | | LLVM 13 introduced `-Wunused-but-set-variable` diagnostic flag, which trips over some intentionally set-but-not-used variables or variables attached to cleanup handlers with side effects (`_cleanup_umask_`, `_cleanup_(notify_on_cleanup)`, `_cleanup_(restore_sigsetp)`, etc.): ``` ../src/basic/process-util.c:1257:46: error: variable 'saved_ssp' set but not used [-Werror,-Wunused-but-set-variable] _cleanup_(restore_sigsetp) sigset_t *saved_ssp = NULL; ^ 1 error generated. ```
* network: replace config_parse_address_filter() with ↵Yu Watanabe2021-09-141-66/+0
| | | | config_parse_in_addr_prefixes()
* in-addr-prefix-util: introduce several utilities for address prefixYu Watanabe2021-09-141-1/+1
|
* network: do not use RouteTable= in [DHCPv4] section for DHCPv6 routesYu Watanabe2021-09-141-3/+68
| | | | | We forgot to add RouteTable= in [DHCPv6] section when we split [DHCP] into two.
* network: use ltype to distinguish DHCPv4 and DHCPv6Yu Watanabe2021-09-141-13/+45
|
* network: dhcp4,ndisc: make addresses in Allow/DenyList= optionally take ↵Yu Watanabe2021-08-231-0/+90
| | | | | | prefix length Closes #20505.
* network: rebreak conf parser argumentsYu Watanabe2021-08-161-10/+11
|
* network: DHCP[46] -> DHCPv[46] in log messagesYu Watanabe2021-08-101-6/+6
|
* network: use request queue to configure DHCP{4,6} clientsYu Watanabe2021-08-101-72/+19
| | | | | | | Previously, when UUID is requested for DUID, then the clients are configured in callback of bus methods. But now, 'request queue' was implemented, so we can use it to wait until the product UUID is obtained.
* network: do not request UUID frequently on failureYu Watanabe2021-08-101-0/+2
| | | | | If many interfaces request UUID, and networkd cannot get it for some reasons, then previously we call the DBus method so frequently.
* network: downgrade log level in dhcp6_configure()Yu Watanabe2021-08-101-1/+1
| | | | And make the callers warn about failures.
* network: downgrade log level in dhcp4_configure()Yu Watanabe2021-08-101-1/+1
| | | | And make the callers warn about failures.
* network: do not process requests which conditionalized with link flags while ↵Yu Watanabe2021-06-091-0/+3
| | | | | | | | the flags are updating E.g. nexthop requires IFF_UP flag, but the currently stored flag may be outdated if we called link_down(). This makes such requests pending if at least one of the flags are updating.
* network: dhcp: constify link_get_duid()Yu Watanabe2021-04-211-11/+13
|
* network: dhcp: introduce duid_needs_product_uuid() helper functionYu Watanabe2021-04-211-1/+7
|
* network: configure non-dhcp configs earlier even DUID-UUID is used by DHCP ↵Yu Watanabe2021-04-211-83/+43
| | | | | | | | | | clients Previously, if DUID-UUID is used, all configurations are configured after networkd gets product uuid of machine. This makes only DHCP clients are delayed, and other configs are configured earlier.
* network: make IAID and DUID for DHCPv6 configurable explicitlyYu Watanabe2021-04-211-56/+209
| | | | Closes #18996.
* network: move dhcp related conf parsers to networkd-dhcp-common.cYu Watanabe2021-04-211-0/+146
|
* network: move RouteMetric= from [DHCPv6] to [IPv6AcceptRA]Yu Watanabe2021-04-211-5/+5
| | | | As the value is used in the routes in RA.
* network: move and rename network_apply_anonymize_if_set()Yu Watanabe2021-04-141-0/+2
|
* networkd: simplify sd_bus_is_ready() checksZbigniew Jędrzejewski-Szmek2021-04-081-1/+1
| | | | | | Also add "system" in the messages, because we set the internal value, and are just skipping the setting of the external value, so the message could be confusing without that clarification.
* network: also introduce UseDomains= for [DHCPv6] sectionYu Watanabe2021-03-141-3/+43
| | | | | When we split [DHCP] section into [DHCPv4] and [DHCPv6], UseDomains= setting was forgot to be introduced in [DHCPv6] section.
* network: use userdata instead data in conf parsersYu Watanabe2021-03-141-6/+6
| | | | These takes no offset, so should not change any behavior.
* network: DHCP option- use correct byteorderSusant Sahani2021-02-171-2/+8
|
* network: dhcp: use string tableYu Watanabe2021-02-121-10/+3
|
* tree-wide: use error codes in xxx_from_string()Yu Watanabe2021-02-121-1/+1
|
* man: use ellipses for ranges in range descriptionsZbigniew Jędrzejewski-Szmek2021-01-291-2/+2
| | | | … and in few other places ;)
* network: tighten variable scope used in loop (#18277)Susant Sahani2021-01-171-2/+1
|
* network: merge config_parse_dhcp_user_class() and _vendor_class()Yu Watanabe2021-01-131-52/+2
|
* network: refuse zero length dhcp user classYu Watanabe2021-01-131-5/+5
|
* network: use bus_error_message()Yu Watanabe2020-12-021-5/+8
|
* network: use IN_SET() macroYu Watanabe2020-11-301-5/+3
| | | | Follow-up for 1d370b2c182505ff8033fccbebcc56621d305220.
* networkd/dhcp6: allow layer3 devices without MACJörg Thalheim2020-11-231-0/+7
| | | | | | | | | | | | | | | | | | | Devices with multicast but without mac addresses i.e. tun devices are not getting setuped correctly: $ ip tuntap add mode tun dev tun0 $ ip addr show tun0 16: tun0: <NO-CARRIER,POINTOPOINT,MULTICAST,NOARP,UP> mtu 1500 qdisc fq_codel state DOWN group default qlen 500 link/none $ cat /etc/systemd/network/tun0.network [Match] Name = tun0 [Network] Address=192.168.1.1/32 $ ./systemd-networkd tun0: DHCP6 CLIENT: Failed to set identifier: Invalid argument tun0: Failed
* license: LGPL-2.1+ -> LGPL-2.1-or-laterYu Watanabe2020-11-091-1/+1
|
* network: introduce network_adjust_dhcp()Yu Watanabe2020-10-151-5/+25
|