From: Mauro Carvalho Chehab <mchehab@kernel.org>
To: Hyunwoo Kim <imv4bel@gmail.com>
Cc: kernel@tuxforce.de, linux-media@vger.kernel.org,
linux-usb@vger.kernel.org, cai.huoqing@linux.dev, tiwai@suse.de
Subject: Re: [PATCH v3 0/4] Fix multiple race condition vulnerabilities in dvb-core and device driver
Date: Tue, 7 Mar 2023 13:41:31 +0100 [thread overview]
Message-ID: <20230307134131.3a005bdb@coco.lan> (raw)
In-Reply-To: <20221117045925.14297-1-imv4bel@gmail.com>
Em Wed, 16 Nov 2022 20:59:21 -0800
Hyunwoo Kim <imv4bel@gmail.com> escreveu:
> Dear,
>
> This patch set is a security patch for various race condition vulnerabilities that occur
> in 'dvb-core' and 'ttusb_dec', a dvb-based device driver.
>
>
> # 1. media: dvb-core: Fix use-after-free due to race condition occurring in dvb_frontend
> This is a security patch for a race condition that occurs in the dvb_frontend system of dvb-core.
>
> The race condition that occurs here will occur with _any_ device driver using dvb_frontend.
>
> The race conditions that occur in dvb_frontend are as follows
> (Description is based on drivers/media/usb/as102/as102_drv.c using dvb_frontend):
> ```
> cpu0 cpu1
> 1. open()
> dvb_frontend_open()
> dvb_frontend_get() // kref : 3
>
>
> 2. as102_usb_disconnect()
> as102_dvb_unregister()
> dvb_unregister_frontend()
> dvb_frontend_put() // kref : 2
> dvb_frontend_detach()
> dvb_frontend_put() // kref : 1
> 3. close()
> __fput()
> dvb_frontend_release()
> dvb_frontend_put() // kref : 0
> dvb_frontend_free()
> __dvb_frontend_free()
> dvb_free_device()
> kfree (dvbdev->fops);
> ...
> fops_put(file->f_op); // UAF!!
Hmm... you're mentioning ttusb_dec at the comment, but here you're showing
the race for as102, which is a different driver.
I'm confused.
Thanks,
Mauro
next prev parent reply other threads:[~2023-03-07 12:42 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-17 4:59 [PATCH v3 0/4] Fix multiple race condition vulnerabilities in dvb-core and device driver Hyunwoo Kim
2022-11-17 4:59 ` [PATCH v3 1/4] media: dvb-core: Fix use-after-free due to race condition occurring in dvb_frontend Hyunwoo Kim
2022-11-17 4:59 ` [PATCH v3 2/4] media: dvb-core: Fix use-after-free due to race condition occurring in dvb_net Hyunwoo Kim
2022-11-17 4:59 ` [PATCH v3 3/4] media: dvb-core: Fix use-after-free due to race condition occurring in dvb_register_device() Hyunwoo Kim
2022-11-17 4:59 ` [PATCH v3 4/4] media: ttusb-dec: Fix memory leak in ttusb_dec_exit_dvb() Hyunwoo Kim
2023-01-10 14:18 ` [PATCH v3 0/4] Fix multiple race condition vulnerabilities in dvb-core and device driver Takashi Iwai
2023-02-22 13:23 ` Lee Jones
2023-02-28 11:32 ` Lee Jones
2023-03-07 10:36 ` Lee Jones
2023-03-07 11:08 ` V4bel
2023-03-08 13:39 ` Lee Jones
2023-03-09 0:15 ` Mauro Carvalho Chehab
2023-03-09 17:17 ` Lee Jones
2023-05-13 18:09 ` Mauro Carvalho Chehab
2023-05-14 14:56 ` Mauro Carvalho Chehab
2023-03-07 12:41 ` Mauro Carvalho Chehab [this message]
[not found] ` <CADUEyCz=xuYjNQohgOi86vm4P4YyfO86AbM0cWdFrs1Y_6276g@mail.gmail.com>
2023-03-09 2:06 ` Hyunwoo Kim
2023-03-09 17:18 ` Lee Jones
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230307134131.3a005bdb@coco.lan \
--to=mchehab@kernel.org \
--cc=cai.huoqing@linux.dev \
--cc=imv4bel@gmail.com \
--cc=kernel@tuxforce.de \
--cc=linux-media@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=tiwai@suse.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.