Shellfeed logo Shellfeed

CVE-2026-74404 · HIGH (CVSS 7.8)

Summary: crypto: ccp - Fix snp_filter_reserved_mem_regions() off-by-one

Details

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

crypto: ccp - Fix snp_filter_reserved_mem_regions() off-by-one

Sashiko notes:

> regarding the bounds check in snp_filter_reserved_mem_regions()
> called via walk_iomem_res_desc(): does the check
> if ((range_list->num_elements * 16 + 8) > PAGE_SIZE)
> allow an off-by-one heap buffer overflow?
>
> If range_list->num_elements is 255, 255 * 16 + 8 = 4088, which is <= 4096.
> Writing range->base (8 bytes) fills 4088-4095, but writing range->page_count
> (4 bytes) would write to 4096-4099, overflowing the kzalloc-allocated
> PAGE_SIZE buffer.

Fix this by accounting for the entry about to be written to, in addition to
the entries that are already allocated.

Severity

HIGH (CVSS 7.8) — vector CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Affected packages

  • GIT git.kernel.org/pub/scm/linux/kernel/git/stable/linux [1ca5614b84eed5904f65f143e0e7aaab0ac4c6b2 – 830c1f3e71989448652973375ef5e39b6ede47a3]
  • Linux Kernel [6.9.0 – 6.12.97] [6.13.0 – 6.18.40] [6.19.0 – 7.1.5]

References