lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <116794823ef8a1c68489e92b92c1f521@oktetlabs.ru>
Date:   Mon, 14 Mar 2022 15:44:37 +0300
From:   Kirill Zats <kirillz@...etlabs.ru>
To:     netdev@...r.kernel.org, Alexandra.Kossovsky@...etlabs.ru
Subject: PROBLEM: When MTU is changed on the main interface that has an IPVLAN
 interface, the change of MTU is announced via netlink on the main interface
 but not on the IPVLAN interface.

[1.] One line summary of the problem:
When MTU is changed on the main interface that has an IPVLAN interface, 
the change of MTU is announced via netlink on the main interface but not 
on the IPVLAN interface.

[2.] Full description of the problem/report:

The bug can be reproduced with a monitor written on libnl (see 
on_11733_libnl.c in the attachment). It listens to the changes of 
network configuration and
prints names of the interfaces where MTU is changed and the updated MTU 
values.

Steps to reproduce:

1. Initial state:

kirillz@...in:~$ ip li
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode 
DEFAULT group default qlen 1000
     link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: eno1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 7152 qdisc mq state UP 
mode DEFAULT group default qlen 1000
     link/ether 50:9a:4c:79:7c:c1 brd ff:ff:ff:ff:ff:ff
     altname enp3s0f0
3: eno2: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode 
DEFAULT group default qlen 1000
     link/ether 50:9a:4c:79:7c:c2 brd ff:ff:ff:ff:ff:ff
     altname enp3s0f1
4: enp2s0f0np0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN 
mode DEFAULT group default qlen 1000
     link/ether 00:0f:53:2b:9a:20 brd ff:ff:ff:ff:ff:ff
5: enp2s0f1np1: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN 
mode DEFAULT group default qlen 1000
     link/ether 00:0f:53:2b:9a:21 brd ff:ff:ff:ff:ff:ff
6: eno1.70@...1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 7152 qdisc 
noqueue state UP mode DEFAULT group default qlen 1000
     link/ether 50:9a:4c:79:7c:c1 brd ff:ff:ff:ff:ff:ff

2. Create IPVLAN on enp2s0f0np0

kirillz@...in:~$ sudo ip link add ipv1 link enp2s0f0np0 type ipvlan mode 
l2
kirillz@...in:~$ sudo ip link set dev ipv1 up
kirillz@...in:~$ ip li
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode 
DEFAULT group default qlen 1000
     link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: eno1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 7152 qdisc mq state UP 
mode DEFAULT group default qlen 1000
     link/ether 50:9a:4c:79:7c:c1 brd ff:ff:ff:ff:ff:ff
     altname enp3s0f0
3: eno2: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode 
DEFAULT group default qlen 1000
     link/ether 50:9a:4c:79:7c:c2 brd ff:ff:ff:ff:ff:ff
     altname enp3s0f1
4: enp2s0f0np0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN 
mode DEFAULT group default qlen 1000
     link/ether 00:0f:53:2b:9a:20 brd ff:ff:ff:ff:ff:ff
5: enp2s0f1np1: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN 
mode DEFAULT group default qlen 1000
     link/ether 00:0f:53:2b:9a:21 brd ff:ff:ff:ff:ff:ff
6: eno1.70@...1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 7152 qdisc 
noqueue state UP mode DEFAULT group default qlen 1000
     link/ether 50:9a:4c:79:7c:c1 brd ff:ff:ff:ff:ff:ff
7: ipv1@...2s0f0np0: <NO-CARRIER,BROADCAST,MULTICAST,UP,M-DOWN> mtu 1500 
qdisc noqueue state LOWERLAYERDOWN mode DEFAULT group default qlen 1000
     link/ether 00:0f:53:2b:9a:20 brd ff:ff:ff:ff:ff:ff

3. Build and run monitor (on_11733_libnl.c)

4. Change MTU on enp2s0f0np0:

kirillz@...in:~$ sudo ip link set dev enp2s0f0np0 mtu 8900
kirillz@...in:~$ ip li
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode 
DEFAULT group default qlen 1000
     link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: eno1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 7152 qdisc mq state UP 
mode DEFAULT group default qlen 1000
     link/ether 50:9a:4c:79:7c:c1 brd ff:ff:ff:ff:ff:ff
     altname enp3s0f0
3: eno2: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode 
DEFAULT group default qlen 1000
     link/ether 50:9a:4c:79:7c:c2 brd ff:ff:ff:ff:ff:ff
     altname enp3s0f1
4: enp2s0f0np0: <BROADCAST,MULTICAST> mtu 8900 qdisc noop state DOWN 
mode DEFAULT group default qlen 1000
     link/ether 00:0f:53:2b:9a:20 brd ff:ff:ff:ff:ff:ff
5: enp2s0f1np1: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN 
mode DEFAULT group default qlen 1000
     link/ether 00:0f:53:2b:9a:21 brd ff:ff:ff:ff:ff:ff
6: eno1.70@...1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 7152 qdisc 
noqueue state UP mode DEFAULT group default qlen 1000
     link/ether 50:9a:4c:79:7c:c1 brd ff:ff:ff:ff:ff:ff
7: ipv1@...2s0f0np0: <NO-CARRIER,BROADCAST,MULTICAST,UP,M-DOWN> mtu 8900 
qdisc noqueue state LOWERLAYERDOWN mode DEFAULT group default qlen 1000
     link/ether 00:0f:53:2b:9a:20 brd ff:ff:ff:ff:ff:ff

5. See output of the monitor.
     It reports receiving message for changing MTU on enp2s0f0np0 but not 
on ipv1@...2s0f0np0

kirillz@...in:~/ON-11733_mtu$ ./on_11733_libnl
create socket
read event
new msg. msg_type = 16
msg_handler: RTM_NEWLINK: ifi enp2s0f0np0
        ifname = enp2s0f0np0
        mtu = 8900

[3.] Keywords (i.e., modules, networking, kernel):
netdev
[4.] Kernel information
[4.1.] Kernel version (from /proc/version):

kirillz@...in:~/onload_dev/onload$ cat /proc/version
Linux version 5.16.12-200.fc35.x86_64 
(mockbuild@...rnel01.iad2.fedoraproject.org) (gcc (GCC) 11.2.1 20220127 
(Red Hat 11.2.1-9), GNU ld version 2.37-10.fc35) #1 SMP PREEMPT Wed Mar 
2 19:06:17 UTC 2022

The bug appeared on all other kernels that I used, e.g. 
5.4.0-100-generic.

[4.2.] Kernel .config file
See file kernel_5.16.12-200.fc35.x86_64_.config in the attacment.
[5.] Most recent kernel version which did not have the bug:
[7.] A small shell script or example program which triggers the
      problem (if possible)
      See files on_11733_libnl.c and Makefile in the attacment.
[8.] Environment
     See file env.txt in the attacment.
[8.1.] Software (add the output of the ver_linux script here)
     See file ver_linux_output.txt in the attacment.
[8.2.] Processor information (from /proc/cpuinfo):
     See file proc_cpuinfo.txt in the attacment.
[8.3.] Module information (from /proc/modules):
     See file proc_modules.txt in the attacment.
[8.4.] Loaded driver and hardware information (/proc/ioports, 
/proc/iomem)
     See files proc_ioports.txt and proc_mem.txt in the attacment.
[8.5.] PCI information ('lspci -vvv' as root)
     See file lspci.txt in the attacment.
[8.6.] SCSI information (from /proc/scsi/scsi)
     See file proc_scsi_scsi.txt in the attacment.
[8.7.] Other information that might be relevant to the problem
        (please look in /proc and include all information that you
        think to be relevant):
     See file proc_net_netstat.txt in the attacment.

Regards,
Kirill
Download attachment "on-11733_linux_bugreport.tar" of type "application/x-tar" (348160 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ