mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/
synced 2026-11-17 19:14:47 +00:00
driver core: platform: Don't read past the end of "driver_override" buffer
commitbf563b01c2upstream. When printing the driver_override parameter when it is 4095 and 4094 bytes long, the printing code would access invalid memory because we need count+1 bytes for printing. Reject driver_override values of these lengths in driver_override_store(). This is in close analogy to commit4efe874aac("PCI: Don't read past the end of sysfs "driver_override" buffer") from Sasha Levin. Fixes:3d713e0e38("driver core: platform: add device binding path 'driver_override'") Signed-off-by: Nicolai Stange <nstange@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
85b56e5dc4
commit
fa3f94eaf0
1 changed files with 2 additions and 1 deletions
Loading…
Add table
Add a link
Reference in a new issue