# CVE-2026-31590: KVM: SEV: Drop WARN on large size for KVM\_MEMORY\_ENCRYPT\_REG\_REGION

- Priority: **Routine**
- Reason: Not severe (CVSS 5.5, local access); no exploitation reported by the 5 checked sources
- Next step: Fix in the normal cadence
- Status: published
- Published: 2026-04-24 · Modified: 2026-11-06
- Aliases: UBUNTU-CVE-2026-31590, DEBIAN-CVE-2026-31590, CGA-4622-xj7h-8cr4, CGA-57g3-377h-8x72, CGA-6wp7-rv5p-xrqp, CGA-792w-pp3g-pmxv, CGA-cjmg-33vv-9673, CGA-vf44-m3q5-hwjf, CGA-vm9g-4wv5-46p4, CGA-wmjh-258q-rjg5, CGA-xm65-2fhw-2pfc
- Record: https://cvemate.com/vulnerability/CVE-2026-31590 · JSON: https://cvemate.com/vulnerability/CVE-2026-31590/json

## Description

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

KVM: SEV: Drop WARN on large size for KVM_MEMORY_ENCRYPT_REG_REGION

Drop the WARN in sev_pin_memory() on npages overflowing an int, as the
WARN is comically trivially to trigger from userspace, e.g. by doing:

  struct kvm_enc_region range = {
          .addr = 0,
          .size = -1ul,
  };

  __vm_ioctl(vm, KVM_MEMORY_ENCRYPT_REG_REGION, &range);

Note, the checks in sev_mem_enc_register_region() that presumably exist to
verify the incoming address+size are completely worthless, as both "addr"
and "size" are u64s and SEV is 64-bit only, i.e. they _can't_ be greater
than ULONG_MAX.  That wart will be cleaned up in the near future.

	if (range->addr > ULONG_MAX || range->size > ULONG_MAX)
		return -EINVAL;

Opportunistically add a comment to explain why the code calculates the
number of pages the "hard" way, e.g. instead of just shifting @ulen.
```

## Signals

- CVSS: 5.5 medium (v3.1, NVD) CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H
- EPSS: 0.131%, percentile 2.833%, as of 2026-12-05
- Known exploited (KEV): CISA not listed, ENISA not listed, CIRCL not listed
- Ransomware use: none recorded
- Public exploits: 0

## Affected (first 20 of 159)

- chainguard linux-aws-6.12 (Chainguard): \< 6.12.85-r0
- chainguard linux-aws-6.18 (Chainguard): \< 6.18.31-r0
- chainguard linux-azure-6.18 (Chainguard): \< 6.18.31-r0
- chainguard linux-gcp-6.18 (Chainguard): \< 6.18.31-r0
- chainguard linux-qemu-6.12 (Chainguard): \< 6.12.85-r0
- chainguard linux-qemu-6.18 (Chainguard): \< 6.18.31-r0
- chainguard linux-qemu-6.18-bootc-boot-installed (Chainguard): \< 6.18.31-r0
- chainguard linux-vmware-6.12 (Chainguard): \< 6.12.85-r0
- chainguard linux-vmware-6.18 (Chainguard): \< 6.18.31-r0
- debian linux (Debian): \< 6.1.176-1 \| \< 6.12.85-1 \| \< 6.19.14-1
- ubuntu linux (Ubuntu): \< 5.15.0-186.196 \| \< 6.8.0-136.136 \| All versions (No fix recorded) \| \< 7.0.0-27.27
- ubuntu linux-allwinner-5.19 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws (Ubuntu): \< 5.15.0-1112.119 \| \< 6.8.0-1061.64 \| All versions (No fix recorded) \| \< 7.0.0-1008.8
- ubuntu linux-aws-5.0 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-5.11 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-5.13 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-5.15 (Ubuntu): \< 5.15.0-1112.119~20.04.1
- ubuntu linux-aws-5.19 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-5.3 (Ubuntu): All versions (No fix recorded)
- ubuntu linux-aws-5.8 (Ubuntu): All versions (No fix recorded)

## References (first 20 of 46)

- <https://git.kernel.org/stable/c/6a8e3c82122737529b25ef2a048fbcc569d8c055>
- <https://git.kernel.org/stable/c/a703933bcfa5cc76ca10e2048464600e74136099>
- <https://git.kernel.org/stable/c/abcd43ff579abd0a654bb4636086e78819dd5f4c>
- <https://git.kernel.org/stable/c/b670833749ffd8681361db2bb047c6f2e3075f3a>
- <https://git.kernel.org/stable/c/ab423e5892826202a660b5ac85d1125b0e8301a5>
- <https://git.kernel.org/stable/c/28cc13ca20431b127d42d84ba10898d03e2c8267>
- <https://git.kernel.org/stable/c/c29ff288a2d97a6f4640a498a367cf0eb91312eb>
- <https://git.kernel.org/stable/c/1cba4dcd795daf6d257122779fb6a349edf03914>
- <https://git.kernel.org/stable/c/8acffeef5ef720c35e513e322ab08e32683f32f2>
- <https://ubuntu.com/security/CVE-2026-31590>
- <https://www.cve.org/CVERecord?id=CVE-2026-31590>
- <https://git.kernel.org/linus/8acffeef5ef720c35e513e322ab08e32683f32f2>
- <https://ubuntu.com/security/notices/USN-8488-1>
- <https://ubuntu.com/security/notices/USN-8488-2>
- <https://ubuntu.com/security/notices/USN-8507-1>
- <https://ubuntu.com/security/notices/USN-8569-1>
- <https://ubuntu.com/security/notices/USN-8567-1>
- <https://ubuntu.com/security/notices/USN-8574-1>
- <https://ubuntu.com/security/notices/USN-8575-1>
- <https://ubuntu.com/security/notices/USN-8576-1>

---

Data as of 2026-12-05T14:09:51.734Z. The priority label is CveMate's own model from public evidence, not an official rating, and it knows nothing about your assets. How labels are decided: https://cvemate.com/faq#priority
