Susant Sahani
35f6a5cb44
network: DHCPv6 - Add support set arbitary request options
2020-05-17 11:18:29 +02:00
Lennart Poettering
a0b191b705
condition: add ConditionEnvironment=
...
Prompted by the discussions in #15180 .
This is a bit more complex than I hoped, since for PID 1 we need to pass
in the synethetic environment block in we generate on demand.
2020-05-15 16:05:33 +02:00
Dan Streetman
589397a277
network: change UseGateway= default to UseRoutes= setting
...
Anyone previously using the UseRoutes=false parameter expected their
dhcp4-provided gateway route to be ignored, as well. However, with
the introduction of the UseGateway= parameter, this is no longer true.
In order to keep backwards compatibility, this sets the UseGateway=
default value to whatever UseRoutes= has been set to.
2020-04-21 16:56:48 -04:00
Susant Sahani
e9a8c550c1
LLDP: Add support to transmit MUD URL
2020-04-08 00:20:54 +02:00
Zbigniew Jędrzejewski-Szmek
c51c6f2f57
Merge pull request #15252 from ssahani/dhcpv6-mud
...
DHCPv6: Add support to send MUD URL
2020-04-02 10:23:15 +02:00
Susant Sahani
3175a8c21b
network: DHCPv6 Add support to send MUD URL
2020-04-01 17:01:12 +02:00
Susant Sahani
7b8d23a9bb
network: DHCPv4 - introduce The Manufacturer Usage Description (MUD)
2020-03-30 20:27:48 +02:00
Lennart Poettering
1f4faf21e8
Merge pull request #15197 from ssahani/smtp-dhcp
...
DHCP4: Add support to emit and receive SMTP servers.
2020-03-30 18:58:26 +02:00
Susant Sahani
f6269fe7bb
network: DHCP - add support to emit and receive SMTP server information
2020-03-29 22:59:11 +02:00
Zbigniew Jędrzejewski-Szmek
b0c8219260
network: move NETWORK_DIRS to path-lookup.h
...
In preparation for future changes...
2020-03-27 20:12:45 +01:00
David Wood
7354900ddd
network: Fix split in `SendOption=` on client and server
...
When specifying `DHCPv4.SendOption=`, it is used by systemd-networkd to
set the value of that option within the DHCP request that is sent out.
This differs to setting `DHCPServer.SendOption=`, which will place all
the options together as suboptions into the vendor-specific information
(code 43) option.
This commit adds two new config options, `DHCPv4.SendVendorOption=` and
`DHCPServer.SendVendorOption=`. These both have the behaviour of the old
`DHCPServer.SendOption=` flag, and set the value of the suboption in the
vendor-specific information option.
The behaviour of `DHCPServer.SendOption=` is then changed to reflect
that of `DHCPv4.SendOption=`. It will set the value of the corresponding
option in the DHCP request.
2020-03-19 09:08:40 +01:00
Yu Watanabe
b453122789
network: add a flag to ignore gateway provided by DHCP server
...
Closes #15117 .
2020-03-16 19:34:43 +09:00
Susant Sahani
7f22402007
network: TC - introduce HHF
...
Please see https://lwn.net/Articles/577208/
2020-03-12 15:39:12 +09:00
Susant Sahani
1a95964bfa
network: TC - introduce pfifo_fast
...
pfifo_fast - three-band first in, first out queue
Please see https://linux.die.net/man/8/tc-pfifo_fast
2020-03-12 15:38:18 +09:00
Susant Sahani
053a2ddbb2
network: TC - introduce pfifo_head_drop
...
This adds the required changes to gain access to
the head drop classfull queuing discipline named
pfifo_head_drop.
2020-03-12 15:37:17 +09:00
Susant Sahani
c853f594d4
network: TC - introduce BFIFO
...
bfifo - Byte limited First In, First Out queue
2020-03-12 15:35:51 +09:00
Yu Watanabe
ad365c5de7
network: tc: introduce DRR class
2020-03-12 15:35:51 +09:00
Susant Sahani
f5fc04417e
network: TC - introduce DRR
...
Introduce the Deficit Round Robin Scheduler is a classful queuing discipline as
a more flexible replacement for Stochastic Fairness Queuing.
http://man7.org/linux/man-pages/man8/tc-drr.8.html
2020-03-12 15:35:51 +09:00
Susant Sahani
bde4ae88c8
network: tc- introduce PIE
...
Proportional Integral controller-Enhanced (PIE) is a control
theoretic active queue management scheme. It is based on the
proportional integral controller but aims to control delay.
http://man7.org/linux/man-pages/man8/tc-pie.8.html
2020-03-12 13:58:35 +09:00
Yu Watanabe
a834cb5247
Merge pull request #15036 from yuwata/can-termination-mod
...
network: add CAN Termination tristate option
2020-03-07 19:11:03 +09:00
Matt Ranostay
52aa38f14a
network: add CAN Termination tristate option
2020-03-07 02:00:02 +09:00
Yu Watanabe
bba1f90ff5
Merge pull request #14890 from yuwata/network-tc-next
...
network: tc-next
2020-03-07 01:44:15 +09:00
Yu Watanabe
d739fddeb5
network: add setting to support RA without DHCPv6 client
...
Closes #13991 .
2020-03-07 01:39:26 +09:00
Yu Watanabe
ef62949a23
network: make Type=ether match based on iftype
...
This makes Type= can match the type shown in networkctl.
Closes #14952 .
2020-03-02 08:52:18 +01:00
Susant Sahani
ad8352f4ff
network: tc: introduce cake
...
CAKE (Common Applications Kept Enhanced)
Please see http://man7.org/linux/man-pages/man8/tc-cake.8.html
2020-03-02 15:59:37 +09:00
Susant Sahani
982998b087
network: TC introduce sfb - Stochastic Fair Blue
...
Please see https://www.systutorials.com/docs/linux/man/8-tc-sfb/
2020-03-02 15:48:24 +09:00
Susant Sahani
609e8340bb
network: TC introduce GRED, Generic Random Early Detection
...
http://tldp.org/en/Traffic-Control-HOWTO/ar01s06.html
2020-03-02 15:48:24 +09:00
Susant Sahani
a74760653c
network: TC introduce PFIFO
2020-03-02 15:48:00 +09:00
Yu Watanabe
19f86a6351
network: tc: support HTB class
2020-03-02 15:46:28 +09:00
Yu Watanabe
34658df256
network: introduce TrafficControlKind to prepare for supporting tc class
2020-03-02 15:46:28 +09:00
Yu Watanabe
b934ac3d6e
network: tc: support Hierarchy Token Bucket (HTB)
2020-03-02 15:46:28 +09:00
Yu Watanabe
9b749c11e2
network: tc: support teql
...
Closes #14792 .
2020-02-07 17:41:49 +09:00
Yu Watanabe
2ed5f6d5de
network: introduce new [QDisc] section to support Parent=ingress
...
Follow-up for 18de0969c5
.
2020-02-07 13:48:54 +09:00
Zbigniew Jędrzejewski-Szmek
5bbcff2a1d
Merge pull request #14415 from ssahani/prefixstable-rfc-7217-new
...
network: Allow to specify multiple IPv6Token for SLAAC
2020-02-05 17:05:33 +01:00
Zbigniew Jędrzejewski-Szmek
239bf9409d
Merge pull request #14536 from DaanDeMeyer/wait-online-max-operstate
...
wait-online: add maximum operational state option
2020-02-05 10:16:29 +01:00
Susant Sahani
5f506a5560
network: Allow to specify multiple IPv6Token for SLAAC
...
Provide names to choose between different auto-generation types:
2.1 "eui64" for EUI-64 of RFC 4291
2.2 "prefixstable" for RFC 7217
```
[Match]
Name=veth99
[Network]
DHCP=no
IPv6AcceptRA=yes
IPv6Token=prefixstable:2001:888:0db8:1::
```
2020-02-05 17:44:42 +09:00
Yu Watanabe
f2f1b52c6f
Merge pull request #14767 from yuwata/network-split-qdisc-section
...
network: split TrafficControlQueueingDiscipline section into small pieces
2020-02-05 13:35:25 +09:00
Zbigniew Jędrzejewski-Szmek
ca58d00c68
network: FairQueueTrafficPolicing→FairQueueing
...
This never made into a release, so we can change the name with impunity.
Suggested by Davide Pesavento.
I opted to add the "ing" ending. "Fair queuing" is the name of the general
concept and algorithm, and "Fair queue" is mostly used for the implementation
name.
2020-02-04 17:37:16 +01:00
Zbigniew Jędrzejewski-Szmek
60ed2dcfc7
network: TokenBufferFilter→TokenBucketFilter
...
This never made into a release, so we can change the name with impunity.
Noticed by Davide Pesavento.
2020-02-04 17:28:15 +01:00
Yu Watanabe
18de0969c5
network: split TrafficControlQueueingDiscipline section into small pieces
...
Closes #14763 .
2020-02-04 21:45:39 +09:00
Zbigniew Jędrzejewski-Szmek
dade734917
network,udev: refuse .link and .network settings with no matches
...
Two releases ago we started warning about this, and I think it is now to turn
this into a hard error. People get bitten by this every once in a while, and
there doesn't see to be any legitimate use case where the same .link or
.network files should be applied to _all_ interfaces, since in particular that
configuration would apply both to lo and any other interfaces. And if for
whatever reason that is actually desired, OriginalName=* or Name=* can be
easily added to silence the warning and achieve the effect.
(The case described in #12098 is particularly nasty: 'echo -n >foo.network'
creates a mask file, 'echo >foo.network' creates a "match all" file.)
Fixes #717 , #12098 for realz now.
2020-02-04 08:45:52 +01:00
Daan De Meyer
75cd4a5d92
wait-online: Add maximum operational state option
2020-01-18 18:17:22 +01:00
Yu Watanabe
4bb7cc8287
network, udev: introduce PermanentMACAddress= setting in [Match] section
...
Closes #13983 .
2020-01-08 17:54:54 +09:00
Susant Sahani
0f3ff4eae2
network: DHCP4 introduce send decline
2019-12-21 00:26:44 +09:00
Yu Watanabe
572b21d96c
network: make Name= in [Match] support alternative names of interfaces
2019-12-16 10:55:56 +09:00
Yu Watanabe
edc54f2f75
network: rename QDiscs to QDisc
2019-12-04 20:57:01 +09:00
Yu Watanabe
8efb93f02d
network: ignore sections which have both NetworkEmulator and TokenBufferFilter settings
2019-12-04 20:55:55 +09:00
Yu Watanabe
0e96961d62
network: unify config_parse_dhcp_server_option_data() and config_parse_dhcp_send_option()
2019-11-18 23:39:03 +09:00
Yu Watanabe
461dbb2fa9
dhcp: remove struct sd_dhcp_raw_option
...
sd_dhcp_raw_option and sd_dhcp_option are essentially equivalent.
2019-11-18 23:37:22 +09:00
Yu Watanabe
95081e08d7
network: split struct Prefix into Prefix and RoutePrefix
2019-11-05 22:31:20 +09:00
Yu Watanabe
9be6ae775f
network: fix memleak
2019-11-05 09:41:03 +09:00
Yu Watanabe
acb71754e1
network: use fix invalid free function
...
Fixes #13938 .
2019-11-05 09:40:55 +09:00
Susant Sahani
564ca98484
networkd: dhcp server Support Vendor specific 43
...
Implementes https://tools.ietf.org/html/rfc2132
```
[DHCPServer]
SendRawOption=26:uint32:1400
SendRawOption=23:uint8:10
```
Frame 448: 350 bytes on wire (2800 bits), 350 bytes captured (2800 bits) on interface 0
Linux cooked capture
Internet Protocol Version 4, Src: 192.168.5.1, Dst: 192.168.5.11
User Datagram Protocol, Src Port: 67, Dst Port: 68
Dynamic Host Configuration Protocol (ACK)
Message type: Boot Reply (2)
Hardware type: Ethernet (0x01)
Hardware address length: 6
Hops: 0
Transaction ID: 0x71f8de9d
Seconds elapsed: 0
Bootp flags: 0x0000 (Unicast)
Client IP address: 0.0.0.0
Your (client) IP address: 192.168.5.11
Next server IP address: 0.0.0.0
Relay agent IP address: 0.0.0.0
Client MAC address: 1e:04:f8:b8:2f:d4 (1e:04:f8:b8:2f:d4)
Client hardware address padding: 00000000000000000000
Server host name not given
Boot file name not given
Magic cookie: DHCP
Option: (53) DHCP Message Type (ACK)
Length: 1
DHCP: ACK (5)
Option: (51) IP Address Lease Time
Length: 4
IP Address Lease Time: (3600s) 1 hour
Option: (1) Subnet Mask (255.255.255.0)
Length: 4
Subnet Mask: 255.255.255.0
Option: (3) Router
Length: 4
Router: 192.168.5.1
Option: (6) Domain Name Server
Length: 4
Domain Name Server: 192.168.5.1
Option: (42) Network Time Protocol Servers
Length: 4
Network Time Protocol Server: 192.168.5.1
Option: (101) TCode
Length: 13
TZ TCode: Europe/Berlin
Option: (43) Vendor-Specific Information
Length: 9
Value: 1701311a0431343030
Option: (54) DHCP Server Identifier (192.168.5.1)
Length: 4
DHCP Server Identifier: 192.168.5.1
Option: (255) End
Option End: 255
```
2019-10-31 09:03:43 +09:00
Susant Sahani
0f5bd7fe24
network: introduce TrafficControl
...
Add network delay to a interface
2019-10-30 09:33:51 +09:00
Yu Watanabe
78404d22cc
network: support matching based on wifi interfece type
2019-10-25 16:43:18 +09:00
Yu Watanabe
7f06b3e1b9
network: add Reload() dbus method
2019-10-24 14:18:09 +09:00
Zbigniew Jędrzejewski-Szmek
510c4bb31f
Merge pull request #13142 from yuwata/network-wifi-ssid-support-nl80211
...
network: wifi ssid support with nl80211
2019-10-23 14:51:23 +02:00
Zbigniew Jędrzejewski-Szmek
c8966bffdd
Merge pull request #13663 from ssahani/dhcp-send-option-data
...
network: DHCPv4 client- add support to send arbitary option and data
2019-10-16 11:31:22 +02:00
Yu Watanabe
277ba8d1ab
network: add support matching based on BSSID=
2019-10-15 01:59:56 +09:00
Yu Watanabe
8d968fdd99
network: support matching based on wifi SSID
2019-10-15 01:59:06 +09:00
Susant Sahani
cb29c15605
network: DHCPv4 client: add support to send arbitary option and data
2019-10-15 00:14:02 +09:00
Yu Watanabe
4abcdaa08c
network: update comment as DHCP is deprecated now
2019-10-14 21:33:22 +09:00
Susant Sahani
c16c780804
network: introduce ip nexthop routing
...
Used to manipulate entries in the kernel's nexthop tables.
Example:
```
[NextHop]
Id=3
Gateway=192.168.5.1
```
2019-10-14 21:32:48 +09:00
Zbigniew Jędrzejewski-Szmek
5f3b5f190f
networkd: change SendRelease default to true
...
Now that we don't drop DHCP config on restart, this seems appropriate.
2019-10-02 14:01:42 +02:00
Zbigniew Jędrzejewski-Szmek
800603524a
networkd: drop DHCPv4 config on stop, keep on restart, by default
...
This partially reverts 95355a281c
.
It seems that other parts of link_stop_clients() should be skipped
when restarting, but I don't know enough about those other clients to have
an opinion if it is better to stop&start them on restart or not.
Anyway, that can be done in later patches now that the support for restarts
is there.
Fixes #13625 .
2019-10-02 14:01:42 +02:00
Siddharth Chandrasekara
afe42aef39
dhcp4: make IPServiceType configurable
...
IPServiceType set to CS6 (network control) causes problems on some old
network setups that continue to interpret the field as IP TOS.
Make DHCP work on such networks by allowing this field to be set to
CS4 (Realtime) instead, as this maps to IPTOS_LOWDELAY.
Signed-off-by: Siddharth Chandrasekaran <csiddharth@vmware.com>
2019-09-26 11:39:46 +09:00
Yu Watanabe
714a199e48
network: add one more section validty check
...
Follow-up for 203d4df573
.
2019-09-21 20:17:15 +09:00
Chris Down
de307e199b
networkd: Fix SIP double-free
...
This is already strv_freed right above
2019-09-20 15:15:04 +02:00
Susant Sahani
299d578f7f
network: DHCP server Add support to transmit SIP server
...
1. DHCP server trasmit
2. Client parses and saves in leases
Implements http://www.rfc-editor.org/rfc/rfc3361.txt
```
Frame 134: 348 bytes on wire (2784 bits), 348 bytes captured (2784 bits) on interface 0
Ethernet II, Src: 42:65:85:d6:4e:32 (42:65:85:d6:4e:32), Dst: 1e:04:f8:b8:2f:d4 (1e:04:f8:b8:2f:d4)
Internet Protocol Version 4, Src: 192.168.5.1, Dst: 192.168.5.11
User Datagram Protocol, Src Port: 67, Dst Port: 68
Dynamic Host Configuration Protocol (ACK)
Message type: Boot Reply (2)
Hardware type: Ethernet (0x01)
Hardware address length: 6
Hops: 0
Transaction ID: 0x7cc87cb4
Seconds elapsed: 0
Bootp flags: 0x0000 (Unicast)
Client IP address: 0.0.0.0
Your (client) IP address: 192.168.5.11
Next server IP address: 0.0.0.0
Relay agent IP address: 0.0.0.0
Client MAC address: 1e:04:f8:b8:2f:d4 (1e:04:f8:b8:2f:d4)
Client hardware address padding: 00000000000000000000
Server host name not given
Boot file name not given
Magic cookie: DHCP
Option: (53) DHCP Message Type (ACK)
Length: 1
DHCP: ACK (5)
Option: (51) IP Address Lease Time
Length: 4
IP Address Lease Time: (3600s) 1 hour
Option: (1) Subnet Mask (255.255.255.0)
Length: 4
Subnet Mask: 255.255.255.0
Option: (3) Router
Length: 4
Router: 192.168.5.1
Option: (6) Domain Name Server
Length: 4
Domain Name Server: 192.168.5.1
Option: (42) Network Time Protocol Servers
Length: 4
Network Time Protocol Server: 192.168.1.1
Option: (120) SIP Servers <=====here
Length: 9
SIP Server Encoding: IPv4 Address (1)
SIP Server Address: 192.168.1.1
SIP Server Address: 192.168.5.2
Option: (101) TCode
Length: 13
TZ TCode: Europe/Berlin
Option: (54) DHCP Server Identifier (192.168.5.1)
Length: 4
DHCP Server Identifier: 192.168.5.1
Option: (255) End
Option End: 255
```
```
cat /run/systemd/netif/state ✔ ⚡ 3148 16:40:51
OPER_STATE=routable
CARRIER_STATE=carrier
ADDRESS_STATE=routable
DNS=192.168.94.2 192.168.5.1
NTP=192.168.5.1
SIP=192.168.1.1 192.168.5.2
```
aa
2019-09-20 21:22:23 +09:00
Susant Sahani
5bc945bec4
network dhcp4: Add support send request options in a generic manner
2019-09-20 21:05:48 +09:00
Susant Sahani
203d4df573
network: Add support to advertie ipv6 route
...
Implements https://tools.ietf.org/html/rfc4191
cat veth99.network
```
[Match]
Name=veth99
[Network]
DHCP=no
IPv6PrefixDelegation=yes
Address=2001:db8:0:1::1/64
[IPv6Prefix]
Prefix=2001:db8:0:1::4/64
[IPv6RoutePrefix]
Route=2001:db0:fff::/48
```
Wireshark
```
Frame 481: 142 bytes on wire (1136 bits), 142 bytes captured (1136 bits) on interface 0
Ethernet II, Src: 1e:04:f8:b8:2f:d4 (1e:04:f8:b8:2f:d4), Dst: IPv6mcast_01 (33:33:00:00:00:01)
Internet Protocol Version 6, Src: fe80::1c04:f8ff:feb8:2fd4, Dst: ff02::1
Internet Control Message Protocol v6
Type: Router Advertisement (134)
Code: 0
Checksum: 0xec77 [correct]
[Checksum Status: Good]
Cur hop limit: 0
Flags: 0x00, Prf (Default Router Preference): Medium
Router lifetime (s): 0
Reachable time (ms): 0
Retrans timer (ms): 0
ICMPv6 Option (Source link-layer address : 1e:04:f8:b8:2f:d4)
Type: Source link-layer address (1)
Length: 1 (8 bytes)
Link-layer address: 1e:04:f8:b8:2f:d4 (1e:04:f8:b8:2f:d4)
ICMPv6 Option (MTU : 1500)
Type: MTU (5)
Length: 1 (8 bytes)
Reserved
MTU: 1500
ICMPv6 Option (Prefix information : 2001:db8:0:1::4/64)
Type: Prefix information (3)
Length: 4 (32 bytes)
Prefix Length: 64
Flag: 0xc0, On-link flag(L), Autonomous address-configuration flag(A)
Valid Lifetime: 2592000
Preferred Lifetime: 604800
Reserved
Prefix: 2001:db8:0:1::4
ICMPv6 Option (Route Information : Medium 2001:db0:fff::/48)
Type: Route Information (24)
Length: 3 (24 bytes)
Prefix Length: 48
Flag: 0x00, Route Preference: Medium
...0 0... = Route Preference: Medium (0)
000. .000 = Reserved: 0
Route Lifetime: 604800
Prefix: 2001:db0:fff::
```
2019-09-17 12:09:59 +02:00
Zbigniew Jędrzejewski-Szmek
3af900718e
Merge pull request #13405 from yuwata/network-ipv6-privacy-extensions-cleanup
...
Network ipv6 privacy extensions cleanup
2019-09-13 18:03:29 +02:00
Yu Watanabe
be7110826e
network: do not abort execution when a config file cannot be loaded
...
Closes #13516 .
2019-09-11 21:15:22 +09:00
Yu Watanabe
44013aa4f5
network: add more warnings in network_verify()
2019-08-27 23:53:46 +09:00
Yu Watanabe
adfeee49c5
network: enable ipv6 when the network has static ipv6 configurations
2019-08-27 23:53:46 +09:00
Yu Watanabe
b146ad71cc
network: use DEFINE_STRING_TABLE_LOOKUP_WITH_BOOLEAN() macro at one more place
2019-08-26 16:19:02 +09:00
Yu Watanabe
2d79289525
network: rename AddressFamilyBoolean -> AddressFamily
...
We usually do not call an extended boolean as XxxBoolean.
2019-08-16 22:02:17 +09:00
Yu Watanabe
0aabccc87d
network: refuse the case To= and From= are in different address family
2019-08-16 22:01:17 +09:00
Yu Watanabe
044d4b4067
network: drop invalid [Neighbor] section earlier
2019-07-11 22:22:29 +09:00
Lennart Poettering
7e82b4059b
Merge pull request #13006 from yuwata/network-split-dhcp-12917
...
networkd: DHCPv6 - separate DHCPv6 options from DHCPv4 options
2019-07-11 10:28:03 +02:00
1848
98d20a17a9
Added support for xfrm interfaces
2019-07-10 23:02:19 +09:00
Susant Sahani
caa8ca4286
networkd: DHCPv6 - separate DHCPv6 options from DHCPv4 options
...
Closes https://github.com/systemd/systemd/issues/12917
2019-07-10 16:59:29 +09:00
Zbigniew Jędrzejewski-Szmek
8fabb625ac
Merge pull request #12912 from yuwata/network-move-functions
...
network: move functions
2019-07-02 09:46:38 +02:00
Yu Watanabe
44005bfb4e
network,udev: add Property= setting in [Match] section
...
Closes #5665 .
2019-07-01 01:24:42 +09:00
Yu Watanabe
b38de0e9cc
network,udev: make net_match_config() take sd_device
2019-07-01 01:24:42 +09:00
Yu Watanabe
8fcf1d6180
network: move DHCP server related functions to networkd-dhcp-server.c
2019-06-30 04:46:27 +09:00
Yu Watanabe
ca5ad760a5
network: move conf parsers and function prototypes
2019-06-30 04:45:56 +09:00
Yu Watanabe
95355a281c
network: add KeepConfiguration=dhcp-on-stop
...
The option prevents to drop lease address on stop.
By setting this, we can safely restart networkd.
2019-06-06 22:50:29 +09:00
Susant Sahani
7da377ef16
networkd: add support to keep configuration
2019-06-06 22:50:29 +09:00
Susant Sahani
e520ce6440
networkd: Ability to selectively ignore IPv6 prefixes supplied via router advertisement
...
Closes https://github.com/systemd/systemd/issues/10647
2019-05-19 22:23:06 +09:00
Yu Watanabe
cdd22d5129
network: set_put() here does not returns -EEXIST
2019-05-18 12:46:02 +09:00
Yu Watanabe
a32a00831c
Merge pull request #12574 from yuwata/network-mtu-issue-12552
...
network: do not always bump MTU with additional 4bytes
2019-05-16 08:25:48 +02:00
Yu Watanabe
933c70a0a4
network: honor MTUBytes= setting
...
Closes #12552 .
2019-05-16 11:47:41 +09:00
Susant Sahani
69c317a07f
networkd: introduce netdev ipvtap
...
This patch adds netdev ipvtap that is based on the
IP-VLAN network interface, called ipvtap. An ipvtap device can be created
in the same way as an ipvlan device, using 'kind ipvtap', and then accessed
using the tap user space interface.
2019-05-16 09:48:53 +09:00
Yu Watanabe
5d5003ab35
network: add DefaultRouteOnDevice= setting in [Network] section
...
When enabled, then default route bound to the interface will be created.
This is useful when adding routes on point-to-point interfaces.
Closes #788 .
2019-05-15 12:44:30 +09:00
Yu Watanabe
8e2cb51ce0
network: move MulticastRouter to netdev/bridge.[ch]
2019-05-11 06:24:04 +09:00
Yu Watanabe
7f8539504c
network: move sd_lldp related functions to networkd-lldp-rx.c
2019-05-11 06:14:39 +09:00
Yu Watanabe
5af7bc6f4c
Merge pull request #12480 from ssahani/proxy-arp
...
network: bridge add support to configure proxy ARP/WIFI
2019-05-10 15:30:41 +02:00
Susant Sahani
727b573418
networkd: Add support for blacklisting servers
...
closes #6260
fuzzer: Add DHCP support for blacklisting servers
2019-05-10 15:29:55 +02:00
Susant Sahani
0fadb2a46f
network: add support to configure proxy ARP/WIFI
2019-05-09 15:03:04 +09:00
Yu Watanabe
9aa5d8ba84
network: include glibc headers before including kernel headers
2019-05-09 03:21:31 +02:00
Yu Watanabe
004aadcacd
network: replace inet_pton() with in_addr_from_string()
2019-05-09 01:44:31 +02:00
Susant Sahani
1087623bac
networkd: Add support to configure proxy ARP and proxy ARP Wifi
2019-05-09 01:44:26 +02:00
Zbigniew Jędrzejewski-Szmek
717e8eda77
Merge pull request #12475 from yuwata/network-fix-12452
...
network: add network_ref/_unref() and make Link object take a reference of Network object
2019-05-07 20:03:22 +02:00
Susant Sahani
715cedfbf0
networkd: Allow DHCP4 client to set the number to attempt to reconfigure.
...
Otherwise current value is 6 and after 6 it will give up.
2019-05-07 17:12:04 +02:00
Yu Watanabe
715d398e61
network: drop list fields in Network object
2019-05-07 16:55:19 +02:00
Yu Watanabe
c9c908a60d
network: make Link objects take references of Network objects
2019-05-07 16:55:19 +02:00
Yu Watanabe
35ac3b7664
network: introduce reference counter for Network object
2019-05-07 16:55:19 +02:00
Yu Watanabe
810ae0dc95
network: warn about Network.IPv4LL= is deprecated
2019-05-04 16:46:02 +02:00
Yu Watanabe
29e81083bd
network: disable fallback IPv4ll address assignment when DHCPv4 is disabled
2019-05-04 16:46:02 +02:00
Ben Boeckel
5238e95759
codespell: fix spelling errors
2019-04-29 16:47:18 +02:00
Yu Watanabe
84ea567eb4
udev,network: warn when .link or .network file has no [Match] section
...
Closes #12098 .
2019-04-25 08:41:10 +02:00
Susant Sahani
81962db798
network: Introduce MACsec
...
Media Access Control Security (MACsec) is an 802.1AE IEEE
industry-standard security technology that provides secure
communication for all traffic on Ethernet links.
MACsec provides point-to-point security on Ethernet links between
directly connected nodes and is capable of identifying and preventing
most security threats, including denial of service, intrusion,
man-in-the-middle, masquerading, passive wiretapping, and playback attacks.
Closes #5754
2019-04-12 10:12:41 +09:00
Yu Watanabe
01234e1fe7
tree-wide: drop several missing_*.h and import relevant headers from kernel-5.0
2019-04-11 19:00:37 +02:00
Yu Watanabe
9282f75bf4
network: make erspan netdev can be specified in Network.Tunnel=
2019-03-30 03:52:25 +09:00
Yu Watanabe
c4f58deab5
network,udev: split static condition tests from net_match_config()
2019-03-21 23:37:39 +09:00
Susant Sahani
3a56e697c8
networkd: Introduce l2tp tunnel
...
This works allows networkd to configure l2tp tunnel.
See http://man7.org/linux/man-pages/man8/ip-l2tp.8.html
2019-03-14 10:57:41 +09:00
Tobias Jungel
7f15b71460
networkd: Add bridge port capabilities
...
This PR adds the configuration switches for multicast flooding, neighbor
suppression and learning of a bridge port.
2019-03-13 16:27:22 +01:00
Lennart Poettering
96c45cc697
Merge pull request #11861 from yuwata/network-verify-2
...
network: config parser updates and wireguard refactoring
2019-03-13 10:15:27 +01:00
Yu Watanabe
4ac77d63e9
network: make RequiredForOnline= also take operational state
...
This will be used by systemd-networkd-wait-online.
2019-03-13 14:29:03 +09:00
Yu Watanabe
96db641250
test: make network_verify() public and use it in test-networkd-conf
2019-03-13 11:59:18 +09:00
Yu Watanabe
fcbf4cb727
network: drop sections contain invalid settings in network_verify()
...
If e.g., an [Address] section has an invalid setting, then
previously assigned settings in the section is freed, and
only later settings are stored. That may cause partially broken
section stored in Network object.
This makes if an invalid setting is found, then set 'invalid' flag
instead of freeing it. And invalid sections are dropped later by
network_verify().
2019-03-13 11:59:18 +09:00
Yu Watanabe
fa7cd7117f
network: add IPv4LL route right after .network file is parsed
...
Previously, the route is added when the .network config is assigned
to a Link. So, if multiple links match the .network file, the route
entry becomes duplicated in the corresponding Network object.
2019-03-13 11:59:18 +09:00
Yu Watanabe
48315d3dca
network: move NetworkConfigSection and related functions to networkd-util.[ch]
2019-03-13 11:59:18 +09:00
Yu Watanabe
95dba43542
network: use ltype to determine netdev kind in config_parse_stacked_netdev()
2019-03-13 11:59:18 +09:00
Clemens Gruber
c423be28a0
network: introduce TripleSampling= option in CAN section
...
When enabled, three samples are used to determine the value of a
received bit by majority rule.
This patch adds support for the TripleSampling= option in the [CAN]
section of .network files.
2019-03-11 17:15:47 +01:00
Yu Watanabe
4912ab7774
network: enable GatewayOnLink= if Gateway= without static address configured
...
And warn about that.
But this only done if GatewayOnLink= is not specified. When it is
explicitly disabled, then the flag will not be set.
2019-02-28 10:34:21 +09:00
Yu Watanabe
4bec2f237b
network: relax the .network file check
...
Previously, if a .networ file contains invalid [Address] or [Route]
section, then the file is completely dropped. This makes networkd
just drops invalid sections.
2019-02-28 10:01:56 +09:00
Lennart Poettering
200fb167a2
Merge pull request #11844 from keszybz/networkd-fuzzer-fixes
...
Networkd fuzzer fixes
2019-02-27 17:45:55 +01:00
Zbigniew Jędrzejewski-Szmek
4b151b7132
Merge pull request #11807 from yuwata/test-vlan-mtu
...
network: increase MTU if VLAN= or MACVLAN= requests higher value
2019-02-27 17:15:29 +01:00
Zbigniew Jędrzejewski-Szmek
c448459d56
networkd: refuse more than 128 NTP servers
...
This test case is a bit silly, but it shows that our code is unprepared to
handle so many network servers, with quadratic complexity in various places.
I don't think there are any valid reasons to have hundres of NTP servers
configured, so let's just emit a warning and cut the list short.
https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=13354
2019-02-27 14:52:33 +01:00
Zbigniew Jędrzejewski-Szmek
83ec459276
networkd: fix memleak when the same NetDev is specified twice
...
hashmap_put() returns 0 if the (key, value) pair is already present in the
hashmap, and -EEXIST if the key exists, but the value is different.
https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=13433
2019-02-27 14:31:28 +01:00
Zbigniew Jędrzejewski-Szmek
3772cfde03
network: wrap some long lines
2019-02-27 13:35:19 +01:00
Yu Watanabe
80be3de31f
network: fix error code in log
2019-02-27 16:48:19 +09:00
Yu Watanabe
40288ecea1
network: bump mtu if stacked vlan or macvlan requests larger size
...
Closes #5972 .
2019-02-27 10:04:56 +09:00
Yu Watanabe
102bc043bb
network: assign Network::manager when it is listed to the manager object.
...
Now Network::manager is not necessary during parsing configs.
C.f. 838b2f7a30
.
2019-02-26 10:06:27 +09:00
Yu Watanabe
cebe12571d
network: make resolving NetDev names delayed and moved to network_verify()
...
And before resolving NetDev names, check conditions in .network,
and if they do not match the system environment, drop the network
unit earlier.
Fixes #4211 .
2019-02-26 10:06:23 +09:00
Yu Watanabe
8f1918016f
network: disable LinkLocalAddressing= and IPv6AcceptRA= on bridge slaves by default
...
If they are not explicitly configured, then let's disable these
functionality on bridge slaves.
2019-02-25 09:34:14 +09:00
Zbigniew Jędrzejewski-Szmek
5e2a51d588
networkd: use OrderedSets instead of strvs to store lists of domains
...
We were already using OrderedSets in the manager object, but strvs in the
configuration parsing code. Using sets gives us better scaling when many
domains are used.
In oss-fuzz #13059 the attached reproducer takes approximately 30.5 s to be
parsed. Converting to sets makes this go down to 10s. This is not _vastly_
faster, but using sets seems like a nicer approach anyway. In particular, we
avoid the quadratic de-unification operation after each addition.
2019-02-21 12:04:27 +01:00
Zbigniew Jędrzejewski-Szmek
ab24039ff9
networkd: wrap long log lines
2019-02-20 21:30:06 +01:00
Yu Watanabe
0321cea7b7
network: introduce network_verify()
...
Some settings cannot set simultaneously. Let's warn and drop
incompatible settings.
Currently, it is not comprehensive. But this may be a good first step.
2019-02-20 06:12:54 +09:00
Yu Watanabe
41f62accad
network: warn about deprecated value in DHCP=
2019-02-20 06:12:53 +09:00
Lennart Poettering
bde06abd4f
Merge pull request #10408 from keszybz/analyze-cat-presets
...
systemd-analyze cat-presets
2019-02-18 16:02:45 +01:00
Lennart Poettering
9c5675af76
Merge pull request #11729 from yuwata/fix-11721
...
sd-device: also store properties read from udev database to sd_device::properties_db
2019-02-18 16:02:26 +01:00
Lennart Poettering
702451b038
Merge pull request #11698 from yuwata/fix-network-route-table
...
network: honor specified route table
2019-02-18 12:58:32 +01:00
Zbigniew Jędrzejewski-Szmek
dc0d407851
udev,network: use standard paths for .network and .link files
...
This centralizes the configuration to one header file.
/usr/local/lib is now included in the search list, and documentation is
updated accordingly.
2019-02-18 10:29:33 +01:00
Yu Watanabe
4f4daf418f
udev,network: drop unused parent_driver argument from net_match_config()
...
The argument has never been used.
2019-02-17 00:47:49 +09:00
Lennart Poettering
84e4b0b893
Merge pull request #11716 from ssahani/drop-autoconf-address
...
networkd: ipv6ra allow to ignore addresses
2019-02-15 12:17:46 +01:00
Yu Watanabe
d5fa333960
network: introduce Network::ipv6_accept_ra_route_table_set flag
...
It will be used in later commit.
2019-02-15 10:58:22 +09:00
Susant Sahani
062c2eea3a
networkd: ipv6ra allow to ignore addresses
...
Allows to ignore prefixes.
```
UseAutonomousPrefix=
UseOnLinkPrefix=
```
closes #9582
2019-02-14 21:05:17 +05:30