{"id":"CVE-2022-50329","state":"PUBLISHED","title":"block, bfq: fix uaf for bfqq in bfq_exit_icq_bfqq","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nblock, bfq: fix uaf for bfqq in bfq_exit_icq_bfqq\n\nCommit 64dc8c732f5c (\"block, bfq: fix possible uaf for 'bfqq->bic'\")\nwill access 'bic->bfqq' in bic_set_bfqq(), however, bfq_exit_icq_bfqq()\ncan free bfqq first, and then call bic_set_bfqq(), which will cause uaf.\n\nFix the problem by moving bfq_exit_bfqq() behind bic_set_bfqq().","publishedAt":"2025-09-15T14:49:32.123Z","updatedAt":"2026-10-15T21:31:20.243Z","severity":{"score":7.8,"label":"High","version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","source":"Linux"},"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"5533742c7cb1bc9b1f0bf401cc397d44a3a9e07a","status":"affected","lessThan":"1425f1bb5df5239021fd09ebc2a5e8070e705d36","versionType":"git"},{"version":"094f3d9314d67691cb21ba091c1b528f6e3c4893","status":"affected","lessThan":"7949b0df3dd9f4817ed4a4e989fa9ee81df6205f","versionType":"git"},{"version":"b22fd72bfebda3956efc4431b60ddfc0a51e03e0","status":"affected","lessThan":"cfe5b38c37720313eff0dec5517442c7ab3c9a20","versionType":"git"},{"version":"761564d93c8265f65543acf0a576b32d66bfa26a","status":"affected","lessThan":"1ed959fef5b1c6f1a7a3fbea543698c30ebd6678","versionType":"git"},{"version":"64dc8c732f5c2b406cc752e6aaa1bd5471159cab","status":"affected","lessThan":"246cf66e300b76099b5dbd3fdd39e9a5dbc53f02","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["block/bfq-iosched.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"5.15.86","status":"affected","lessThan":"5.15.87","versionType":"semver"},{"version":"6.0.16","status":"affected","lessThan":"6.0.17","versionType":"semver"},{"version":"6.1.2","status":"affected","lessThan":"6.1.3","versionType":"semver"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["block/bfq-iosched.c"]}],"references":["https://git.kernel.org/stable/c/1425f1bb5df5239021fd09ebc2a5e8070e705d36","https://git.kernel.org/stable/c/7949b0df3dd9f4817ed4a4e989fa9ee81df6205f","https://git.kernel.org/stable/c/cfe5b38c37720313eff0dec5517442c7ab3c9a20","https://git.kernel.org/stable/c/1ed959fef5b1c6f1a7a3fbea543698c30ebd6678","https://git.kernel.org/stable/c/246cf66e300b76099b5dbd3fdd39e9a5dbc53f02"],"weaknesses":[],"ingestedAt":"2026-10-29T20:05:26.763Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2022/50xxx/CVE-2022-50329.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2022-50329","state":"PUBLISHED","datePublished":"2025-09-15T14:49:32.123Z","dateUpdated":"2026-10-15T21:31:20.243Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2025-09-15T14:18:36.815Z"},"containers":{"cna":{"title":"block, bfq: fix uaf for bfqq in bfq_exit_icq_bfqq","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nblock, bfq: fix uaf for bfqq in bfq_exit_icq_bfqq\n\nCommit 64dc8c732f5c (\"block, bfq: fix possible uaf for 'bfqq->bic'\")\nwill access 'bic->bfqq' in bic_set_bfqq(), however, bfq_exit_icq_bfqq()\ncan free bfqq first, and then call bic_set_bfqq(), which will cause uaf.\n\nFix the problem by moving bfq_exit_bfqq() behind bic_set_bfqq()."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"5533742c7cb1bc9b1f0bf401cc397d44a3a9e07a","status":"affected","lessThan":"1425f1bb5df5239021fd09ebc2a5e8070e705d36","versionType":"git"},{"version":"094f3d9314d67691cb21ba091c1b528f6e3c4893","status":"affected","lessThan":"7949b0df3dd9f4817ed4a4e989fa9ee81df6205f","versionType":"git"},{"version":"b22fd72bfebda3956efc4431b60ddfc0a51e03e0","status":"affected","lessThan":"cfe5b38c37720313eff0dec5517442c7ab3c9a20","versionType":"git"},{"version":"761564d93c8265f65543acf0a576b32d66bfa26a","status":"affected","lessThan":"1ed959fef5b1c6f1a7a3fbea543698c30ebd6678","versionType":"git"},{"version":"64dc8c732f5c2b406cc752e6aaa1bd5471159cab","status":"affected","lessThan":"246cf66e300b76099b5dbd3fdd39e9a5dbc53f02","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["block/bfq-iosched.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"5.15.86","status":"affected","lessThan":"5.15.87","versionType":"semver"},{"version":"6.0.16","status":"affected","lessThan":"6.0.17","versionType":"semver"},{"version":"6.1.2","status":"affected","lessThan":"6.1.3","versionType":"semver"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["block/bfq-iosched.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/1425f1bb5df5239021fd09ebc2a5e8070e705d36"},{"url":"https://git.kernel.org/stable/c/7949b0df3dd9f4817ed4a4e989fa9ee81df6205f"},{"url":"https://git.kernel.org/stable/c/cfe5b38c37720313eff0dec5517442c7ab3c9a20"},{"url":"https://git.kernel.org/stable/c/1ed959fef5b1c6f1a7a3fbea543698c30ebd6678"},{"url":"https://git.kernel.org/stable/c/246cf66e300b76099b5dbd3fdd39e9a5dbc53f02"}],"metrics":[{"cvssV3_1":{"version":"3.1","vectorString":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","baseScore":7.8,"baseSeverity":"HIGH"},"scenarios":[{"lang":"en","value":"AV:L - The vulnerable path runs in bfq_exit_icq during exit_io_context after local block I/O on a BFQ-managed device; it is reached via process exit/syscalls, not network or physical input.\nAC:L - An unprivileged attacker fully controls triggering by performing I/O then exiting so the process ref drops and bfq_put_queue frees bfqq before bic_set_bfqq; BFQ is commonly enabled (e.g. Android/desktops), so success does not depend on conditions outside attacker control.\nPR:L - Any unprivileged local user can open/write files on a BFQ-backed filesystem and exit; no capabilities or root are required along the exit_io_context → bfq_exit_icq path.\nUI:N - Exploitation needs only the attacker's own I/O and process exit; no victim action is required.\nS:U - This is a standard in-kernel heap UAF enabling privilege escalation within the same kernel security authority, not a VM/IOMMU/sandbox boundary cross.\nC:H - Use-after-free of struct bfq_queue lets an attacker reclaim and control the freed object, enabling arbitrary kernel memory disclosure primitives.\nI:H - bic_set_bfqq writes old_bfqq->bic on the freed object; with heap spray this yields a write primitive suitable for control-flow hijacking or arbitrary kernel modification.\nA:H - The UAF can oops/panic the kernel on access to freed bfqq memory even without full exploitation, so availability impact is high."}]}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-08-05T08:58:13.157Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.15.86","versionEndExcluding":"5.15.87"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.0.16","versionEndExcluding":"6.0.17"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.1.2","versionEndExcluding":"6.1.3"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}},"adp":[{"title":"CISA ADP Vulnrichment","metrics":[{"other":{"type":"ssvc","content":{"id":"CVE-2022-50329","role":"CISA Coordinator","options":[{"Exploitation":"none"},{"Automatable":"no"},{"Technical Impact":"total"}],"version":"2.0.3","timestamp":"2026-10-15T21:31:01.622731Z"}}}],"providerMetadata":{"shortName":"CISA-ADP","orgId":"134c704f-9b21-4f2e-91b3-4a467353bcc0","dateUpdated":"2026-10-15T21:31:20.243Z"}}]}}}