{"id":"CVE-2023-52790","state":"PUBLISHED","title":"swiotlb: fix out-of-bounds TLB allocations with CONFIG_SWIOTLB_DYNAMIC","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nswiotlb: fix out-of-bounds TLB allocations with CONFIG_SWIOTLB_DYNAMIC\n\nLimit the free list length to the size of the IO TLB. Transient pool can be\nsmaller than IO_TLB_SEGSIZE, but the free list is initialized with the\nassumption that the total number of slots is a multiple of IO_TLB_SEGSIZE.\nAs a result, swiotlb_area_find_slots() may allocate slots past the end of\na transient IO TLB buffer.","publishedAt":"2024-05-21T15:31:06.319Z","updatedAt":"2026-08-05T09:11:25.655Z","severity":{"score":8.8,"label":"High","version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H","source":"Linux"},"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"79636caad3618e2b38457f6e298c9b31ba82b489","status":"affected","lessThan":"ce7612496a4ba6068bc68aa1fa9d947dadb4ad9b","versionType":"git"},{"version":"79636caad3618e2b38457f6e298c9b31ba82b489","status":"affected","lessThan":"53c87e846e335e3c18044c397cc35178163d7827","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["kernel/dma/swiotlb.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.6","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.6","versionType":"semver"},{"version":"6.6.3","status":"unaffected","lessThanOrEqual":"6.6.*","versionType":"semver"},{"version":"6.7","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["kernel/dma/swiotlb.c"]}],"references":["https://git.kernel.org/stable/c/ce7612496a4ba6068bc68aa1fa9d947dadb4ad9b","https://git.kernel.org/stable/c/53c87e846e335e3c18044c397cc35178163d7827"],"weaknesses":[],"ingestedAt":"2026-10-29T20:06:33.064Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2023/52xxx/CVE-2023-52790.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2023-52790","state":"PUBLISHED","datePublished":"2024-05-21T15:31:06.319Z","dateUpdated":"2026-08-05T09:11:25.655Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2024-05-21T15:19:24.241Z"},"containers":{"cna":{"title":"swiotlb: fix out-of-bounds TLB allocations with CONFIG_SWIOTLB_DYNAMIC","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nswiotlb: fix out-of-bounds TLB allocations with CONFIG_SWIOTLB_DYNAMIC\n\nLimit the free list length to the size of the IO TLB. Transient pool can be\nsmaller than IO_TLB_SEGSIZE, but the free list is initialized with the\nassumption that the total number of slots is a multiple of IO_TLB_SEGSIZE.\nAs a result, swiotlb_area_find_slots() may allocate slots past the end of\na transient IO TLB buffer."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"79636caad3618e2b38457f6e298c9b31ba82b489","status":"affected","lessThan":"ce7612496a4ba6068bc68aa1fa9d947dadb4ad9b","versionType":"git"},{"version":"79636caad3618e2b38457f6e298c9b31ba82b489","status":"affected","lessThan":"53c87e846e335e3c18044c397cc35178163d7827","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["kernel/dma/swiotlb.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.6","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.6","versionType":"semver"},{"version":"6.6.3","status":"unaffected","lessThanOrEqual":"6.6.*","versionType":"semver"},{"version":"6.7","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["kernel/dma/swiotlb.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/ce7612496a4ba6068bc68aa1fa9d947dadb4ad9b"},{"url":"https://git.kernel.org/stable/c/53c87e846e335e3c18044c397cc35178163d7827"}],"metrics":[{"cvssV3_1":{"version":"3.1","vectorString":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H","baseScore":8.8,"baseSeverity":"HIGH"},"scenarios":[{"lang":"en","value":"AV:L - The vulnerable code is in the kernel DMA/swiotlb allocator, reached when drivers call dma_map/swiotlb_tbl_map_single for I/O (including NIC RX/TX on untrusted PCI devices), which requires local ability to stimulate device DMA rather than a network-bound protocol parser.\nAC:L - Once CONFIG_SWIOTLB_DYNAMIC is enabled and SWIOTLB is under pressure, the reporter showed TCP/IP workloads on an untrusted VF reliably create transient pools and hit the unaligned >=PAGE_SIZE path that overruns the buffer; the attacker can induce that load.\nPR:L - An unprivileged local user can trigger DMA mapping through ordinary network or storage I/O that causes drivers to bounce via swiotlb; no root or CAP_* beyond normal user access is required.\nUI:N - Exploitation does not require a victim to perform any action such as mounting a filesystem or opening a crafted file; generating I/O is sufficient.\nS:C - On the iommu_dma_map_page path for untrusted PCI devices, an overrun bounce address is passed to iommu_map, mapping physical pages outside the SWIOTLB pool into the device IOVA space and bypassing the IOMMU/DMA isolation boundary.\nC:H - Out-of-bounds slot metadata writes and bounce/DMA access past the transient pool expose adjacent kernel or host physical memory, yielding a high-impact disclosure primitive.\nI:H - The bug is a confirmed out-of-bounds write (CWE-787) into slots[] and past the TLB buffer, and device DMA to wrongly IOMMU-mapped pages enables arbitrary modification of adjacent memory and control-flow corruption.\nA:H - Overrunning the transient pool corrupts kernel memory and can crash or hang the system, as seen when the mis-sized bounce buffer is used for DMA and CPU-side bounce/memset."}]}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-08-05T09:11:25.655Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.6","versionEndExcluding":"6.6.3"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.6","versionEndExcluding":"6.7"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}},"adp":[{"title":"CISA ADP Vulnrichment","metrics":[{"other":{"type":"ssvc","content":{"id":"CVE-2023-52790","role":"CISA Coordinator","options":[{"Exploitation":"none"},{"Automatable":"no"},{"Technical Impact":"partial"}],"version":"2.0.3","timestamp":"2024-05-22T19:32:04.825201Z"}}}],"providerMetadata":{"shortName":"CISA-ADP","orgId":"134c704f-9b21-4f2e-91b3-4a467353bcc0","dateUpdated":"2024-06-04T17:23:14.167Z"}},{"title":"CVE Program Container","references":[{"url":"https://git.kernel.org/stable/c/ce7612496a4ba6068bc68aa1fa9d947dadb4ad9b","tags":["x_transferred"]},{"url":"https://git.kernel.org/stable/c/53c87e846e335e3c18044c397cc35178163d7827","tags":["x_transferred"]}],"providerMetadata":{"shortName":"CVE","orgId":"af854a3a-2127-422b-91ae-364da2661108","dateUpdated":"2024-08-02T23:11:36.050Z"}}]}}}