Re: [PATCH] powerpc/eeh: NUL-terminate force recovery input
From: Madhavan Srinivasan
Date: Tue Nov 17 2026 - 20:45:48 EST
On Thu, 29 Oct 2026 13:29:48 +0800, Jiale Yao wrote:
> eeh_force_recover_write() can fill its entire stack buffer from userspace
> and then pass the unterminated data to strncmp() and sscanf(). This can
> make the string helpers read beyond the buffer.
>
> Reserve the last byte and initialize the buffer so every accepted input is
> NUL-terminated. Propagate copy errors before parsing as well.
>
> [...]
Applied to powerpc/fixes.
[1/1] powerpc/eeh: NUL-terminate force recovery input
https://git.kernel.org/powerpc/c/f294ebd827e7a2b831b1eef4aaf437f07b2c235e
cheers