Skip to content

Conversation

@brada4
Copy link

@brada4 brada4 commented Apr 27, 2025

Use earliest hook after conntrack (-200) to drop invalid packets

As a consequence they are not processed by conntrack at all once identified

Add diagnostic counters, hopefully hinting users in direction of net.netfilter.nf_conntrack_log_invalid=255

Obsoletes: 19a8caf
Reverts: 19a8caf

Signed-off-by: Andris PE neandris@gmail.com

Use earliest hook after conntrack (-200) to drop invalid packets

As a consequence they are not processed by conntrack at all once
identified

Add diagnostic counters, hopefully hinting users in direction of
net.netfilter.nf_conntrack_log_invalid=255

Obsoletes: 19a8caf
Reverts: 19a8caf

Signed-off-by: Andris PE <neandris@gmail.com>
@brada4
Copy link
Author

brada4 commented Apr 27, 2025

second 3rd of #22
Blocks guarding offload with ct state, ie last part of those.

Careful rebasing on top of #56 - iif "lo" should follow established, related accept

Ref: https://wiki.nftables.org/wiki-nftables/index.php/Netfilter_hooks

Ideally this could be 4 hooks at points where ct is entered pre/out -200 and left post/in +32k. But hooks cost CPU esp on low end platforms.

@brada4
Copy link
Author

brada4 commented Apr 27, 2025

Ahh yes, loopback excluded to emulate fw3 workings, no harm in users running nmap -O against loopback (which is quite efficient ct invalid generator on its own)

@brada4
Copy link
Author

brada4 commented May 18, 2025

Please consider brada4@aec0dc5 superseding pr #22 completely.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant