From 85237f202d46d55c1bffe0c5b1aa3ddc0f1dce4d Mon Sep 17 00:00:00 2001 From: Oliver Neukum Date: Tue, 21 Aug 2007 07:10:42 +0200 Subject: USB: fix DoS in pwc USB video driver the pwc driver has a disconnect method that waits for user space to close the device. This opens up an opportunity for a DoS attack, blocking the USB subsystem and making khubd's task busy wait in kernel space. This patch shifts freeing resources to close if an opened device is disconnected. Signed-off-by: Oliver Neukum CC: stable Signed-off-by: Greg Kroah-Hartman --- drivers/media/video/pwc/pwc.h | 1 + 1 file changed, 1 insertion(+) (limited to 'drivers/media/video/pwc/pwc.h') diff --git a/drivers/media/video/pwc/pwc.h b/drivers/media/video/pwc/pwc.h index 910a04f5392..8e8e5b27e77 100644 --- a/drivers/media/video/pwc/pwc.h +++ b/drivers/media/video/pwc/pwc.h @@ -193,6 +193,7 @@ struct pwc_device char vsnapshot; /* snapshot mode */ char vsync; /* used by isoc handler */ char vmirror; /* for ToUCaM series */ + char unplugged; int cmd_len; unsigned char cmd_buf[13]; -- cgit v1.2.3-70-g09d2