Re: [PATCH] dm ioctl: replace deprecated strncpy with strscpy_pad

2023-10-24 Thread Kees Cook
On Mon, 25 Sep 2023 06:54:51 +, Justin Stitt wrote: > `strncpy` is deprecated for use on NUL-terminated destination strings > [1] and as such we should prefer more robust and less ambiguous string > interfaces. > > We expect `spec->target_type` to be NUL-terminated based on its use with > a

Re: [PATCH] dm ioctl: replace deprecated strncpy with strscpy_pad

2023-09-25 Thread Kees Cook
On Mon, Sep 25, 2023 at 06:54:51AM +, Justin Stitt wrote: > `strncpy` is deprecated for use on NUL-terminated destination strings > [1] and as such we should prefer more robust and less ambiguous string > interfaces. > > We expect `spec->target_type` to be NUL-terminated based on its use with

[PATCH] dm ioctl: replace deprecated strncpy with strscpy_pad

2023-09-25 Thread Justin Stitt
`strncpy` is deprecated for use on NUL-terminated destination strings [1] and as such we should prefer more robust and less ambiguous string interfaces. We expect `spec->target_type` to be NUL-terminated based on its use with a format string after `dm_table_add_target()` is called | r =