Re: [PATCH] netfilter: conntrack_irc: fix port value truncation in parse_dcc()

From: Aamir Ahmed

Date: Mon Sep 07 2026 - 22:04:12 EST


On Mon, Sep 07, 2026 at 10:32:17AM +0200, Florian Westphal wrote:
> Your other patch also rejects port == 0.
> Maybe also check and refuse for tmp_port < 1024 here.

Makes sense - the expectation is source-wildcarded and the DCC port is
the client's own listener, so a privileged port there is not something
the helper should open. v2 will reject tmp_port < 1024 || > 65535 and
drop the now-redundant dcc_port == 0 test in help() (or I can put the
floor there instead, so the forged-DCC warning still fires - your
preference). I will describe it as a behaviour change with your
Suggested-by rather than part of the truncation fix.

While respinning I noticed simple_strtoul() narrows to 32 bits before
the range check on 32-bit, so v2 will use simple_strtoull().

> This patch can be handled via nf-next, I think.

Will resend as [PATCH nf-next v2], without the stable Cc.

Kind Regards

Aamir A.