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: <db33871a-26ad-44f2-8e4b-046aa34f6477@kernel.org>
Date: Mon, 20 Oct 2025 09:01:08 +0200
From: Krzysztof Kozlowski <krzk@...nel.org>
To: Thorsten Blum <thorsten.blum@...ux.dev>, Huisong Li <lihuisong@...wei.com>
Cc: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>,
 linux-kernel@...r.kernel.org
Subject: Re: [PATCH] w1: therm: Replace deprecated strcpy with strscpy in
 alarms_store

On 17/10/2025 19:00, Thorsten Blum wrote:
> strcpy() is deprecated because it can overflow when the destination
> buffer is not large enough for the source string. Replace it with

It cannot overflow. Look at the code - memory is allocated for the size.

> strscpy(), which avoids overflows and guarantees NUL-termination.

Maybe NUL-termination is missing, could be.

Anyway please write commit msg describing this exact code, not a generic
one for work replacing strcpy(). Your generic commit msg is just not
applicable here.

And even there, just look at the code - why exactly cannot it be
simplified into ksrtdup?



Best regards,
Krzysztof

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ