OpenCloudOS-Kernel/fs/befs
Azeem Shaikh 7391928025 befs: Replace all non-returning strlcpy with strscpy
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.
In an effort to remove strlcpy() completely, replace
strlcpy() here with strscpy().
No return values were used, so direct replacement is safe.

[1] https://www.kernel.org/doc/html/latest/process/deprecated.html#strlcpy
[2] https://github.com/KSPP/linux/issues/89

Signed-off-by: Azeem Shaikh <azeemshaikh38@gmail.com>
Signed-off-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/20230509014136.2095900-1-azeemshaikh38@gmail.com
2023-05-30 16:42:00 -07:00
..
ChangeLog fix a series of Documentation/ broken file name references 2018-06-15 18:10:01 -03:00
Kconfig treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
Makefile treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
befs.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
befs_fs_types.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
btree.c befs: Replace all non-returning strlcpy with strscpy 2023-05-30 16:42:00 -07:00
btree.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
datastream.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
datastream.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
debug.c isystem: ship and use stdarg.h 2021-08-19 09:02:55 +09:00
endian.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
inode.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
inode.h befs: remove trailing whitespaces 2016-12-22 11:25:23 +00:00
io.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
io.h befs: remove trailing whitespaces 2016-12-22 11:25:23 +00:00
linuxvfs.c befs: Replace all non-returning strlcpy with strscpy 2023-05-30 16:42:00 -07:00
super.c befs: fix style issues in super.c 2016-10-08 10:01:34 +01:00
super.h befs: fix style issues in header files 2016-12-22 11:25:22 +00:00