lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAJZ5v0jOzpZSHPdTp2Qzh-oQP7aa=LtgXr2k6W3DevBV0Zw5uA@mail.gmail.com>
Date:   Wed, 3 Aug 2022 19:30:44 +0200
From:   "Rafael J. Wysocki" <rafael@...nel.org>
To:     Daniel Lezcano <daniel.lezcano@...aro.org>
Cc:     "Rafael J. Wysocki" <rafael@...nel.org>,
        Florian Fainelli <f.fainelli@...il.com>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        Markus Mayer <mmayer@...adcom.com>,
        Amit Kucheria <amitk@...nel.org>,
        Zhang Rui <rui.zhang@...el.com>,
        Jacob Pan <jacob.jun.pan@...ux.intel.com>,
        "open list:THERMAL" <linux-pm@...r.kernel.org>
Subject: Re: [PATCH] tools/thermal: Fix possible path truncations

On Wed, Aug 3, 2022 at 7:19 PM Daniel Lezcano <daniel.lezcano@...aro.org> wrote:
>
> On 03/08/2022 19:07, Rafael J. Wysocki wrote:
> > On Mon, Jul 25, 2022 at 7:38 PM Florian Fainelli <f.fainelli@...il.com> wrote:
> >>
> >> A build with -D_FORTIFY_SOURCE=2 enabled will produce the following warnings:
> >>
> >> sysfs.c:63:30: warning: '%s' directive output may be truncated writing up to 255 bytes into a region of size between 0 and 255 [-Wformat-truncation=]
> >>    snprintf(filepath, 256, "%s/%s", path, filename);
> >>                                ^~
> >> Bump up the buffer to PATH_MAX which is the limit and account for all of
> >> the possible NUL and separators that could lead to exceeding the
> >> allocated buffer sizes.
> >>
> >> Fixes: 94f69966faf8 ("tools/thermal: Introduce tmon, a tool for thermal subsystem")
> >> Signed-off-by: Florian Fainelli <f.fainelli@...il.com>
> >
> > Daniel, are you going to pick up this one or should I?
>
> Yes, you can pick it

Done.

> > There is also a tmon patch from Florian that seems to be pending.
> > Should I take care of it?
>
> I'm not sure which patch you are referring but if it is the pthread
> compilation issue, it should be already applied for v5.20-rc1 from the
> thermal pull request
>
> https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/diff/tools/thermal/tmon/tmon.h?id=c1dbe9a1c86da098a29dcdca1a67b65e2de7ec3a

Yes, it was this one.

OK, we're good.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ