Page MenuHomeFreeBSD

icmp: improve INVARIANTS check
ClosedPublic

Authored by tuexen on Dec 9 2024, 4:41 PM.
Tags
None
Referenced Files
F115729820: D48001.id147860.diff
Sun, Apr 27, 7:42 PM
F115675629: D48001.id147737.diff
Sat, Apr 26, 11:27 PM
Unknown Object (File)
Sat, Apr 26, 2:51 AM
Unknown Object (File)
Wed, Apr 23, 7:33 PM
Unknown Object (File)
Tue, Apr 22, 5:10 PM
Unknown Object (File)
Mon, Apr 21, 10:51 AM
Unknown Object (File)
Sun, Apr 20, 6:25 PM
Unknown Object (File)
Sun, Apr 20, 6:19 PM
Subscribers

Details

Summary

Actually check the conditions, which are enforced by the error checking code instead of a condition which is

  • checking a number to be non-negative instead of positive
  • depending on a random number

Diff Detail

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

Event Timeline

tuexen requested review of this revision.Dec 9 2024, 4:41 PM
This revision is now accepted and ready to land.Dec 9 2024, 7:54 PM

Additional comment:

% sysctl -d net.inet.icmp.icmplim_jitter
net.inet.icmp.icmplim_jitter: Random icmplim jitter adjustment limit

May document this net.inet.icmp.icmplim_jitter in ICMP(4).

glebius requested changes to this revision.Dec 10 2024, 7:05 PM

Thanks! Please apply same changes to netinet6/icmp6.c

This revision now requires changes to proceed.Dec 10 2024, 7:05 PM

Consistently handle ICMPv4 and ICMPv6 as suggested by Gleb.

Thanks! Please apply same changes to netinet6/icmp6.c

Done. Thanks.

In D48001#1094461, @cc wrote:

Additional comment:

% sysctl -d net.inet.icmp.icmplim_jitter
net.inet.icmp.icmplim_jitter: Random icmplim jitter adjustment limit

May document this net.inet.icmp.icmplim_jitter in ICMP(4).

Improved man page in D48025.

This revision is now accepted and ready to land.Dec 12 2024, 1:56 PM
This revision was automatically updated to reflect the committed changes.