CVE-2024-49874

Source
https://nvd.nist.gov/vuln/detail/CVE-2024-49874
Import Source
https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2024-49874.json
JSON Data
https://api.test.osv.dev/v1/vulns/CVE-2024-49874
Downstream
Related
Published
2024-10-21T18:01:14.762Z
Modified
2025-11-28T02:34:25.451676Z
Summary
i3c: master: svc: Fix use after free vulnerability in svc_i3c_master Driver Due to Race Condition
Details

In the Linux kernel, the following vulnerability has been resolved:

i3c: master: svc: Fix use after free vulnerability in svci3cmaster Driver Due to Race Condition

In the svci3cmasterprobe function, &master->hjwork is bound with svci3cmasterhjwork, &master->ibiwork is bound with svci3cmasteribiwork. And svci3cmasteribiwork can start the hjwork, svci3cmasterirqhandler can start the ibi_work.

If we remove the module which will call svci3cmasterremove to make cleanup, it will free master->base through i3cmaster_unregister while the work mentioned above will be used. The sequence of operations that may lead to a UAF bug is as follows:

CPU0 CPU1

                                | svc_i3c_master_hj_work

svci3cmasterremove | i3cmasterunregister(&master->base)| deviceunregister(&master->dev) | devicerelease | //free master->base | | i3cmasterdodaa(&master->base) | //use master->base

Fix it by ensuring that the work is canceled before proceeding with the cleanup in svci3cmaster_remove.

Database specific
{
    "cna_assigner": "Linux",
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/49xxx/CVE-2024-49874.json"
}
References

Affected packages

Git / git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

Affected ranges

Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
87e0f28eda36c7843523aa8dd0c5dab3331e9718
Fixed
56bddf543d4d7ddeff3f87b554ddacfdf086bffe
Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
0f74f8b6675cc36d689abb4d9b3d75ab4049b7d7
Fixed
4ac637122930cc4ab7e2c22e364cf3aaf96b05b1
Fixed
4318998892bf8fe99f97bea18c37ae7b685af75a
Fixed
27b55724d3f781dd6e635e89dc6e2fd78fa81a00
Fixed
61850725779709369c7e907ae8c7c75dc7cec4f3

Linux / Kernel

Package

Name
Kernel

Affected ranges

Type
ECOSYSTEM
Events
Introduced
6.4.0
Fixed
6.6.55
Type
ECOSYSTEM
Events
Introduced
6.7.0
Fixed
6.10.14
Type
ECOSYSTEM
Events
Introduced
6.11.0
Fixed
6.11.3