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)
Oct 1 2024, 6:14 PM
Unknown Object (File)
Oct 1 2024, 5:11 PM
Unknown Object (File)
Sep 29 2024, 12:31 AM
Unknown Object (File)
Sep 28 2024, 2:13 PM
Unknown Object (File)
Sep 21 2024, 7:56 PM
Unknown Object (File)
Sep 21 2024, 4:37 PM
Unknown Object (File)
Sep 8 2024, 9:37 PM
Unknown Object (File)
Sep 7 2024, 1:11 PM
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 Passed
Unit
No Test Coverage
Build Status
Buildable 13695
Build 13915: arc lint + arc unit

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.