Page MenuHomeFreeBSD

pf: call dummynet directly from the ethernet code
ClosedPublic

Authored by kp on May 19 2022, 5:00 PM.
Tags
None
Referenced Files
Unknown Object (File)
Nov 11 2024, 5:25 AM
Unknown Object (File)
Oct 26 2024, 2:52 AM
Unknown Object (File)
Oct 25 2024, 12:31 AM
Unknown Object (File)
Sep 24 2024, 5:32 PM
Unknown Object (File)
Sep 23 2024, 6:55 PM
Unknown Object (File)
Sep 20 2024, 6:29 PM
Unknown Object (File)
Sep 20 2024, 7:56 AM
Unknown Object (File)
Sep 16 2024, 10:29 AM

Details

Summary

Until recently dummynet in ethernet rules did not send packets directly
to dummynet but instead marked them and left the interactions with
dummynet to the layer 3 pf code.
This worked fine for incoming packets (where we process ethernet rules
before layer 3 rules), but not for outbound packets (where the order of
operations is the reverse).

Dummynet does support handling layer 2 traffic, so send the packets
directly to dummynet.

The main limitation now is that pf does not inspect layer 4 (i.e.
TCP/UDP) so we don't have protocol information or port numbers. Dummynet
potentially uses this to separate traffic flows, which will not work for
ethernet dummynet rules. However, pipes (i.e. adding latency or
restricting bandwidth) will work exactly as expected.

Sponsored by: Rubicon Communications, LLC ("Netgate")

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable