Re: [PATCH] mISDN: make sure device name is NUL terminated

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
Date: Wed, 22 May 2019 11:45:13 +0300

> The user can change the device_name with the IMSETDEVNAME ioctl, but we
> need to ensure that the user's name is NUL terminated.  Otherwise it
> could result in a buffer overflow when we copy the name back to the user
> with IMGETDEVINFO ioctl.
> 
> I also changed two strcpy() calls which handle the name to strscpy().
> Hopefully, there aren't any other ways to create a too long name, but
> it's nice to do this as a kernel hardening measure.
> 
> Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>

Applied.



[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux