media: dvb-core: purge unsafe ULE debug and fix pre-existing vulnerabilities
Subsystems (2)
PATCH 1/1 media: dvb-core: purge unsafe ULE debug and fix pre-existing vulnerabilities
This commit completely removes the unmaintained DVB_ULE_DEBUG code block from dvb_net.c and its Kconfig definition to eliminate lockless race conditions and cleans up the unused function signature parameter in dvb_net_ule_check_crc() to resolve compilation failures.
Additionally, this patch addresses two pre-existing critical security issues:
1. Fixes a Use-After-Free (UAF) vulnerability in dvb_net_remove_if() by invoking unregister_netdev() before flushing the workqueues, ensuring no new callbacks can queue tasks after flushes.
2. Fixes an Out-of-Bounds (OOB) memory read vulnerability in the ULE extension header parsing loop by introducing a strict bounds check against the skb tail pointer.
--- drivers/media/dvb-core/Kconfig | 11 -------- drivers/media/dvb-core/dvb_net.c | 57 ++++++++++++++------------------ 2 files changed, 25 insertions(+), 43 deletions(-)
drivers/media/dvb-core/Kconfig +0 -11
@@ -67,14 +67,3 @@ config DVB_DEMUX_SECTION_LOSS_LOG If you are unsure about this, say N here. -config DVB_ULE_DEBUG - bool "Enable DVB net ULE packet debug messages" - depends on DVB_CORE - help - Enable extra log messages meant to detect problems while - handling DVB network ULE packet loss inside the Kernel. - - Should not be enabled on normal cases, as logs can - be very verbose. - - If you are unsure about this, say N here.
drivers/media/dvb-core/dvb_net.c +11 -43
101 lines not on this page · raw message
Signature · 1 line
2.43.0