summaryrefslogtreecommitdiff
path: root/scripts/patch-kernel
diff options
context:
space:
mode:
authorAzeem Shaikh <azeemshaikh38@gmail.com>2023-05-17 17:49:10 +0300
committerTejun Heo <tj@kernel.org>2023-05-22 22:05:57 +0300
commitc33080cdc0cab7e72c5e4841cb7533d18a3130dc (patch)
tree81287d9edee01139f5e98545e83afcb4ecf837be /scripts/patch-kernel
parent658888050998d0f0f7d8eca0c4dbb304bfa408bb (diff)
downloadlinux-c33080cdc0cab7e72c5e4841cb7533d18a3130dc.tar.xz
cgroup: 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 [1]. In an effort to remove strlcpy() completely [2], 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> Reviewed-by: Kees Cook <keescook@chromium.org> Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'scripts/patch-kernel')
0 files changed, 0 insertions, 0 deletions