mirror of
https://github.com/torvalds/linux.git
synced 2025-11-12 22:49:37 +02:00
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: Kees Cook <keescook@chromium.org> Link: https://lore.kernel.org/r/20230522155306.2336889-1-azeemshaikh38@gmail.com |
||
|---|---|---|
| .. | ||
| Kconfig | ||
| Makefile | ||
| mtk_cec.c | ||
| mtk_cec.h | ||
| mtk_disp_aal.c | ||
| mtk_disp_ccorr.c | ||
| mtk_disp_color.c | ||
| mtk_disp_drv.h | ||
| mtk_disp_gamma.c | ||
| mtk_disp_merge.c | ||
| mtk_disp_ovl.c | ||
| mtk_disp_ovl_adaptor.c | ||
| mtk_disp_rdma.c | ||
| mtk_dp.c | ||
| mtk_dp_reg.h | ||
| mtk_dpi.c | ||
| mtk_dpi_regs.h | ||
| mtk_drm_crtc.c | ||
| mtk_drm_crtc.h | ||
| mtk_drm_ddp_comp.c | ||
| mtk_drm_ddp_comp.h | ||
| mtk_drm_drv.c | ||
| mtk_drm_drv.h | ||
| mtk_drm_gem.c | ||
| mtk_drm_gem.h | ||
| mtk_drm_plane.c | ||
| mtk_drm_plane.h | ||
| mtk_dsi.c | ||
| mtk_ethdr.c | ||
| mtk_ethdr.h | ||
| mtk_hdmi.c | ||
| mtk_hdmi.h | ||
| mtk_hdmi_ddc.c | ||
| mtk_hdmi_regs.h | ||
| mtk_mdp_rdma.c | ||
| mtk_mdp_rdma.h | ||