mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: Kees Cook <kees@kernel.org>
Cc: linux-kernel@vger.kernel.org, linux-wireless@vger.kernel.org,
	 linux-hardening@vger.kernel.org
Subject: Re: [PATCH] wifi: mac80211: Replace strncpy() with strscpy_pad() in drv_switch_vif_chanctx tracepoint
Date: Mon, 23 Mar 2026 18:34:38 +0100	[thread overview]
Message-ID: <cc6ca8d987b69277f084bdca4df56660d04cba6a.camel@sipsolutions.net> (raw)
In-Reply-To: <2cc7113dfe94622c1e8e482948f26d9268ef2538.camel@sipsolutions.net>

On Mon, 2026-03-23 at 18:32 +0100, Johannes Berg wrote:
> On Mon, 2026-03-23 at 10:20 -0700, Kees Cook wrote:
> > ring buffer. Since ring buffer entries are not zeroed on allocation,
> > 
> > No behavioral change: since interface names are always at most 15
> > characters plus a NUL terminator, strscpy_pad() with size IFNAMSIZ (16)
> > produces identical output to the original strncpy().
> 
> This doesn't add up - if it's not zero-filled on allocation, then it
> *is* a (desired) behaviour change?

Err, no, never mind, it's str*n*cpy() now...

johannes

      reply	other threads:[~2026-03-23 17:34 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-23 17:20 Kees Cook
2026-03-23 17:32 ` Johannes Berg
2026-03-23 17:34   ` Johannes Berg [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=cc6ca8d987b69277f084bdca4df56660d04cba6a.camel@sipsolutions.net \
    --to=johannes@sipsolutions.net \
    --cc=kees@kernel.org \
    --cc=linux-hardening@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®