Page MenuHomeFreeBSD

Don't call tcp_lro_rx() unless hardware verified TCP/UDP csum
ClosedPublic

Authored by shurd on Dec 20 2017, 7:55 PM.
Tags
None
Referenced Files
Unknown Object (File)
Dec 20 2023, 4:28 AM
Unknown Object (File)
Dec 13 2023, 2:56 PM
Unknown Object (File)
Sep 26 2023, 7:24 PM
Unknown Object (File)
Aug 10 2023, 3:20 AM
Unknown Object (File)
Jul 29 2023, 9:50 AM
Unknown Object (File)
Jul 29 2023, 9:46 AM
Unknown Object (File)
Jul 29 2023, 9:45 AM
Unknown Object (File)
Jul 29 2023, 9:43 AM
Subscribers

Details

Summary

It seems that tcp_lro_rx() doesn't verify TCP checksums, so
if there are bad checksums in the packets caused by invalid data, the
invalid data will pass through without errors.

This was noticed with the igb driver and a specific internet host:
fetch http://www.mpfr.org/mpfr-current/mpfr-3.1.6.tar.xz -o test.bin && sha256 test.bin
Would result in a different value sometimes.

This ends up making LRO require RXCSUM to be enabled, and RXCSUM to
support TCP and UDP checksums.

Test Plan

Verify mpfr.org fetch works, run tests with corrupt packet data

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

This was noted in the FreeBSD Cluster as well. https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=224346 Ensure this Bug is added to the commit.

stlgtm

This revision is now accepted and ready to land.Dec 20 2017, 9:04 PM
This revision was automatically updated to reflect the committed changes.