{"id":"CVE-2023-54143","state":"PUBLISHED","title":"media: mediatek: vcodec: fix resource leaks in vdec_msg_queue_init()","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nmedia: mediatek: vcodec: fix resource leaks in vdec_msg_queue_init()\n\nIf we encounter any error in the vdec_msg_queue_init() then we need\nto set \"msg_queue->wdma_addr.size = 0;\".  Normally, this is done\ninside the vdec_msg_queue_deinit() function.  However, if the\nfirst call to allocate &msg_queue->wdma_addr fails, then the\nvdec_msg_queue_deinit() function is a no-op.  For that situation, just\nset the size to zero explicitly and return.\n\nThere were two other error paths which did not clean up before returning.\nChange those error paths to goto mem_alloc_err.","publishedAt":"2025-12-24T13:06:56.869Z","updatedAt":"2026-05-11T19:56:19.068Z","severity":null,"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"b199fe46f35c57a415acd4d5295b0f4e35048c11","status":"affected","lessThan":"858322c409e0aba8f70810d23f35c482744f007c","versionType":"git"},{"version":"b199fe46f35c57a415acd4d5295b0f4e35048c11","status":"affected","lessThan":"b7dbc27301f560c3b915235c53383155b3512083","versionType":"git"},{"version":"b199fe46f35c57a415acd4d5295b0f4e35048c11","status":"affected","lessThan":"451dc187cadd47771e5d9434fe220fad7be84057","versionType":"git"},{"version":"b199fe46f35c57a415acd4d5295b0f4e35048c11","status":"affected","lessThan":"cf10b0bb503c974ba049d6f888b21178be20a962","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/media/platform/mediatek/vcodec/vdec_msg_queue.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"5.18","status":"affected"},{"version":"0","status":"unaffected","lessThan":"5.18","versionType":"semver"},{"version":"6.1.53","status":"unaffected","lessThanOrEqual":"6.1.*","versionType":"semver"},{"version":"6.4.16","status":"unaffected","lessThanOrEqual":"6.4.*","versionType":"semver"},{"version":"6.5.3","status":"unaffected","lessThanOrEqual":"6.5.*","versionType":"semver"},{"version":"6.6","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/media/platform/mediatek/vcodec/vdec_msg_queue.c"]}],"references":["https://git.kernel.org/stable/c/858322c409e0aba8f70810d23f35c482744f007c","https://git.kernel.org/stable/c/b7dbc27301f560c3b915235c53383155b3512083","https://git.kernel.org/stable/c/451dc187cadd47771e5d9434fe220fad7be84057","https://git.kernel.org/stable/c/cf10b0bb503c974ba049d6f888b21178be20a962"],"weaknesses":[],"ingestedAt":"2026-10-29T20:06:42.242Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2023/54xxx/CVE-2023-54143.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2023-54143","state":"PUBLISHED","datePublished":"2025-12-24T13:06:56.869Z","dateUpdated":"2026-05-11T19:56:19.068Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2025-12-24T13:02:52.523Z"},"containers":{"cna":{"title":"media: mediatek: vcodec: fix resource leaks in vdec_msg_queue_init()","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nmedia: mediatek: vcodec: fix resource leaks in vdec_msg_queue_init()\n\nIf we encounter any error in the vdec_msg_queue_init() then we need\nto set \"msg_queue->wdma_addr.size = 0;\".  Normally, this is done\ninside the vdec_msg_queue_deinit() function.  However, if the\nfirst call to allocate &msg_queue->wdma_addr fails, then the\nvdec_msg_queue_deinit() function is a no-op.  For that situation, just\nset the size to zero explicitly and return.\n\nThere were two other error paths which did not clean up before returning.\nChange those error paths to goto mem_alloc_err."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"b199fe46f35c57a415acd4d5295b0f4e35048c11","status":"affected","lessThan":"858322c409e0aba8f70810d23f35c482744f007c","versionType":"git"},{"version":"b199fe46f35c57a415acd4d5295b0f4e35048c11","status":"affected","lessThan":"b7dbc27301f560c3b915235c53383155b3512083","versionType":"git"},{"version":"b199fe46f35c57a415acd4d5295b0f4e35048c11","status":"affected","lessThan":"451dc187cadd47771e5d9434fe220fad7be84057","versionType":"git"},{"version":"b199fe46f35c57a415acd4d5295b0f4e35048c11","status":"affected","lessThan":"cf10b0bb503c974ba049d6f888b21178be20a962","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/media/platform/mediatek/vcodec/vdec_msg_queue.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"5.18","status":"affected"},{"version":"0","status":"unaffected","lessThan":"5.18","versionType":"semver"},{"version":"6.1.53","status":"unaffected","lessThanOrEqual":"6.1.*","versionType":"semver"},{"version":"6.4.16","status":"unaffected","lessThanOrEqual":"6.4.*","versionType":"semver"},{"version":"6.5.3","status":"unaffected","lessThanOrEqual":"6.5.*","versionType":"semver"},{"version":"6.6","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["drivers/media/platform/mediatek/vcodec/vdec_msg_queue.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/858322c409e0aba8f70810d23f35c482744f007c"},{"url":"https://git.kernel.org/stable/c/b7dbc27301f560c3b915235c53383155b3512083"},{"url":"https://git.kernel.org/stable/c/451dc187cadd47771e5d9434fe220fad7be84057"},{"url":"https://git.kernel.org/stable/c/cf10b0bb503c974ba049d6f888b21178be20a962"}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-05-11T19:56:19.068Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.18","versionEndExcluding":"6.1.53"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.18","versionEndExcluding":"6.4.16"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.18","versionEndExcluding":"6.5.3"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"5.18","versionEndExcluding":"6.6"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}