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>] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 11 Feb 2020 20:48:52 +0100
From:   Heiner Kallweit <hkallweit1@...il.com>
To:     Eric Dumazet <edumazet@...gle.com>,
        Alexander Duyck <alexander.h.duyck@...ux.intel.com>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>
Subject: Question related to GSO6 checksum magic

Few network drivers like Intel e1000e or r8169 have the following in the
GSO6 tx path:

ipv6_hdr(skb)->payload_len = 0;
tcp_hdr(skb)->check = ~csum_ipv6_magic(&ipv6_hdr(skb)->saddr,
				       &ipv6_hdr(skb)->daddr,
				       0, IPPROTO_TCP, 0);
(partially also w/o the payload_len assignment)

This sounds like we should factor it out to a helper.
The code however leaves few questions to me, but I'm not familiar enough
with the net core low-level details to answer them:

- This code is used in a number of drivers, so is it something that
  should be moved to the core? If yes, where would it belong to?

- Is clearing payload_len needed? IOW, can it be a problem if drivers
  miss this?

Thanks, Heiner

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ