{"id":"CVE-2022-49951","aliases":["CVE-2022-49951"],"related":[],"kind":"vulnerability","state":"published","title":"firmware_loader: Fix use-after-free during unregister","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\nfirmware_loader: Fix use-after-free during unregister\n\nIn the following code within firmware_upload_unregister(), the call to\ndevice_unregister() could result in the dev_release function freeing the\nfw_upload_priv structure before it is dereferenced for the call to\nmodule_put(). This bug was found by the kernel test robot using\nCONFIG_KASAN while running the firmware selftests.\n\n  device_unregister(&fw_sysfs->dev);\n  module_put(fw_upload_priv->module);\n\nThe problem is fixed by copying fw_upload_priv->module to a local variable\nfor use when calling device_unregister().","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\nfirmware_loader: Fix use-after-free during unregister\n\nIn the following code within firmware_upload_unregister(), the call to\ndevice_unregister() could result in the dev_release function freeing the\nfw_upload_priv structure before it is dereferenced for the call to\nmodule_put(). This bug was found by the kernel test robot using\nCONFIG_KASAN while running the firmware selftests.\n\n  device_unregister(&fw_sysfs->dev);\n  module_put(fw_upload_priv->module);\n\nThe problem is fixed by copying fw_upload_priv->module to a local variable\nfor use when calling device_unregister().","source":"cvelist"},{"lang":"es","text":"En el kernel de Linux, se ha resuelto la siguiente vulnerabilidad: firmware_loader: Se corrige el error \"use-after-free\" durante la anulación del registro. En el siguiente código, dentro de firmware_upload_unregister(), la llamada a device_unregister() podría provocar que la función dev_release libere la estructura fw_upload_priv antes de que se desreferenciara para la llamada a module_put(). Este error fue detectado por el robot de pruebas del kernel mediante CONFIG_KASAN al ejecutar las autopruebas del firmware. device_unregister(&amp;fw_sysfs-&gt;dev); module_put(fw_upload_priv-&gt;module); El problema se corrige copiando fw_upload_priv-&gt;module a una variable local para su uso al llamar a device_unregister().","source":"nvd"}],"published":"2025-06-18T11:00:14.694Z","modified":"2026-06-17T05:19:36.473Z","severity":{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"},"severities":[{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"}],"cwes":["CWE-416"],"affected":[{"ranges":[{"type":"git","introduced":"97730bbb242cde22b7140acd202ffd88823886c9","fixed":"d380d40930a674c520a5b55f3be1eb17dc634ebc","status":"affected"},{"type":"git","introduced":"97730bbb242cde22b7140acd202ffd88823886c9","fixed":"8b40c38e37492b5bdf8e95b46b5cca9517a9957a","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"5.19","status":"affected"},{"type":"semver","introduced":"0","fixed":"5.19","status":"unaffected"},{"type":"semver","introduced":"5.19.8","lastAffected":"5.19.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"6.0","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"status":"affected","introduced":"5.19","fixed":"5.19.8"},{"status":"affected","version":"6.0"},{"status":"affected","version":"6.0"},{"status":"affected","version":"6.0"}],"vendor":"linux","product":"linux_kernel","cpe":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://git.kernel.org/stable/c/d380d40930a674c520a5b55f3be1eb17dc634ebc","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/8b40c38e37492b5bdf8e95b46b5cca9517a9957a","tags":["patch"],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2022-49951","url":"https://www.cve.org/CVERecord?id=CVE-2022-49951","licence":"CVE Terms of Use","modified":"2026-05-11T19:09:49.839Z"},{"source":"nvd","name":"NVD","id":"CVE-2022-49951","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-49951","licence":"Public domain","modified":"2026-06-17T05:19:36.473Z"}],"updatedAt":"2026-11-25T22:58:20.978Z","epss":{"score":0.00258,"percentile":0.18609,"date":"2026-12-01T12:00:22.000Z"}}