Re: [PATCH] dma-buf: Replace strlcpy() with strscpy()

2023-11-20 Thread Christian König
Am 17.11.23 um 19:50 schrieb T.J. Mercier: On Thu, Nov 16, 2023 at 11:14 AM Kees Cook wrote: strlcpy() reads the entire source buffer first. This read may exceed the destination size limit. This is both inefficient and can lead to linear read overflows if a source string is not NUL-terminated[1

Re: [PATCH] dma-buf: Replace strlcpy() with strscpy()

2023-11-17 Thread T.J. Mercier
On Thu, Nov 16, 2023 at 11:14 AM Kees Cook wrote: > > strlcpy() reads the entire source buffer first. This read may exceed > the destination size limit. This is both inefficient and can lead > to linear read overflows if a source string is not NUL-terminated[1]. > Additionally, it returns the size