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: <CAJZ5v0jbNX91hYdGaO4CgZOoLSfDaF9f3XGk1wWHA6ivV+Vjtw@mail.gmail.com>
Date:   Thu, 21 Sep 2023 20:57:42 +0200
From:   "Rafael J. Wysocki" <rafael@...nel.org>
To:     Kees Cook <keescook@...omium.org>,
        Justin Stitt <justinstitt@...gle.com>
Cc:     "Rafael J. Wysocki" <rafael@...nel.org>,
        Len Brown <lenb@...nel.org>, linux-acpi@...r.kernel.org,
        linux-kernel@...r.kernel.org, linux-hardening@...r.kernel.org
Subject: Re: [PATCH] ACPI: OSI: refactor deprecated strncpy

On Fri, Sep 15, 2023 at 5:16 AM Kees Cook <keescook@...omium.org> wrote:
>
> On Mon, Sep 11, 2023 at 08:36:44PM +0000, Justin Stitt wrote:
> > `strncpy` is deprecated for use on NUL-terminated destination strings [1].
> >
> > We know `osi->string` is a NUL-terminated string due to its eventual use
> > in `acpi_install_interface()` and `acpi_remove_interface()` which expect
> > a `acpi_string` which has been specifically typedef'd as:
> > |  typedef char *acpi_string; /* Null terminated ASCII string */
> >
> > ... and which also has other string functions used on it like `strlen`.
> > Furthermore, padding is not needed in this instance either.
>
> Following the callers, I agree, this doesn't need %NUL padding -- it's
> always processed as a regular C string.
>
> Reviewed-by: Kees Cook <keescook@...omium.org>

Applied as 6.7 material, thanks!

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ