All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sergey Shtylyov <s.shtylyov@omp.ru>
To: Ulf Hansson <ulf.hansson@linaro.org>
Cc: <linux-mmc@vger.kernel.org>
Subject: Re: [PATCH v2] mmc: core: use sysfs_emit() in #define sdio_info_attr()
Date: Mon, 7 Feb 2022 23:08:10 +0300	[thread overview]
Message-ID: <7bb4e55e-a389-e132-a3c4-545b23c7342f@omp.ru> (raw)
In-Reply-To: <CAPDyKFpCH_0Hiq_FhmoUdgY0BXfnK0=jdB+zHQ8e16WKFNJfjA@mail.gmail.com>

Hello!

On 1/31/22 7:14 PM, Ulf Hansson wrote:

>> sprintf() (still used in #define sdio_info_attr()) is vulnerable to the
>> buffer overflow.  Use the new-fangled sysfs_emit() instead.
>>
>> While at it, add spaces around the minus sign...
>>
>> Found by Linux Verification Center (linuxtesting.org) with the SVACE static
>> analysis tool.
>>
>> Signed-off-by: Sergey Shtylyov <s.shtylyov@omp.ru>
> 
> Thanks for fixing this!
> 
> However, rather than applying these piece by piece, would you mind
> squashing these "sysfs_emit" fixes into one patch for the mmc core? It
> would be easier for me to handle - and it should still be an easy
> backport, I think.

   OK, just posted!
   Note that in some place I had to reindent the entire function (indented
with spaces) because checkpatch.pl was bitching...

> Kind regards
> Uffe

[...]

MBR, Sergey

      reply	other threads:[~2022-02-07 20:09 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-27 21:01 [PATCH v2] mmc: core: use sysfs_emit() in #define sdio_info_attr() Sergey Shtylyov
2022-01-31 16:14 ` Ulf Hansson
2022-02-07 20:08   ` Sergey Shtylyov [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=7bb4e55e-a389-e132-a3c4-545b23c7342f@omp.ru \
    --to=s.shtylyov@omp.ru \
    --cc=linux-mmc@vger.kernel.org \
    --cc=ulf.hansson@linaro.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 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.