Subject: Re: [PATCH nf] netfilter: xt_RATEEST: reject non-null terminated string from userspace

From: Florian Westphal <[email-masked]>
Date: Tue, 22 Dec 2020 23:50:10 +0100

Linus Torvalds <[email-masked]> wrote:
> On Tue, Dec 22, 2020 at 2:24 PM Florian Westphal <[email-masked]> wrote:
> >
> > strlcpy assumes src is a c-string. Check info->name before its used.
> 
> If strlcpy is the only problem, then the fix is to use strscpy(),
> which doesn't have the design mistake that strlcpy has.

It would silence the reproducer, but the checkentry function calls
__xt_rateest_lookup which may 'strcmp(..., maybe_not_zero_terminated)'.