linux-stable/drivers/isdn
Dan Carpenter f13d6b305a mISDN: make sure device name is NUL terminated
[ Upstream commit ccfb62f27b ]

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@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2019-06-22 08:17:22 +02:00
..
capi isdn: fix kernel-infoleak in capi_unlocked_ioctl 2019-01-09 16:16:40 +01:00
divert
gigaset isdn/gigaset: fix NULL-deref at probe 2017-03-26 13:05:58 +02:00
hardware mISDN: hfcpci: Test both vendor & device ID for Digium HFC4S 2019-04-03 06:24:14 +02:00
hisax isdn: hisax: hfc_pci: Fix a possible concurrency use-after-free bug in HFCPCI_l1hw() 2019-02-12 19:44:58 +01:00
hysdn treewide: replace dev->trans_start update with helper 2016-05-04 14:16:49 -04:00
i4l isdn: isdn_tty: fix build warning of strncpy 2019-03-13 14:04:52 -07:00
isdnloop drivers: isdn: isdnloop: isdnloop.c: Remove parenthesis around return values, as specified in CodingStyle. 2015-02-05 15:40:23 -08:00
mISDN mISDN: make sure device name is NUL terminated 2019-06-22 08:17:22 +02:00
Kconfig
Makefile isdn: i4l: move active-isdn drivers to staging 2016-03-05 15:00:38 -08:00