All of lore.kernel.org
 help / color / mirror / Atom feed
* nftables carefully open the related-flow: ct state related ct helper "ftp-21" ...
@ 2021-03-07 15:12 Stefan Hartmann
  2021-03-07 20:06 ` Frank Myhr
  0 siblings, 1 reply; 14+ messages in thread
From: Stefan Hartmann @ 2021-03-07 15:12 UTC (permalink / raw)
  To: netfilter

Hi,

I want to carefully open the related-flow and noticed that I cannot 
concatenate the two ct expressions:

		ct state related ct helper "HELPER" ... accept


Simple example with ftp-helper:
...
chain INPUT4 { vom VPN-Peer,
         type filter hook input priority 0; policy drop;


	ct state established counter accept
	
	# would be nice to match on state related AND applied helper
	ct state related ct helper "ftp-21" tcp dport {1024-65535} counter accept
	
	ct state related ct helper "ftp-21" counter log prefix "NFT: 
FILTER4/INPUT4: p. died :" group 0 drop
	
	# I want not care about other related traffic
	ct state related counter accept

	...


Simple Workaround, which could be unsecure in certain circumstances, eg 
using different helpers, sip-A, sip-B, sip-C:
	
	ct state established counter accept
	ct state related tcp dport {1024-65535} counter accept


Is the concatenation possible or have I to use another syntax, eg 
different chains?

Tested on nftables 0.9.8-3 on Debian Bullseye.


-- 
Thanks,
Stefan Hartmann

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2021-03-15 11:18 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-07 15:12 nftables carefully open the related-flow: ct state related ct helper "ftp-21" Stefan Hartmann
2021-03-07 20:06 ` Frank Myhr
2021-03-08  9:24   ` Stefan Hartmann
2021-03-08 12:48     ` Frank Myhr
2021-03-08 19:22       ` Stefan Hartmann
2021-03-08 19:59         ` Frank Myhr
2021-03-08 21:05         ` Florian Westphal
2021-03-09 16:13           ` Stefan Hartmann
2021-03-09 16:59             ` Frank Myhr
2021-03-09 17:24               ` Florian Westphal
2021-03-09 17:29                 ` Frank Myhr
2021-03-09 21:06                 ` Pablo Neira Ayuso
2021-03-10  0:13                   ` Frank Myhr
2021-03-15 11:18                   ` Frank Myhr

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.