CVE-2026-99473 (GCVE-0-2026-99473)

Vulnerability from cvelistv5 – Published: 2026-11-19 14:43 – Updated: 2026-11-22 11:08
VLAI
Title
KVM: guest_memfd: Gracefully handle xarray errors when binding a memslot
Summary
In the Linux kernel, the following vulnerability has been resolved: KVM: guest_memfd: Gracefully handle xarray errors when binding a memslot If inserting a memslot into a guest_memfd's bindings xarray fails, propagate the error back to the caller, i.e. fail memslot creation as well. Signalling success and continuing on with memslot creation results in use-after-free, as the guest_memfd instance will remain reachable via the memslot after the file is freed (kvm_gmem_release() won't nullify the file pointer due to lack of a valid binding). Opportunistically WARN and reject binding if KVM_MEMSLOT_GMEM_ONLY is already set, partly to guard against goofs elsewhere, but mostly so that KVM doesn't need to worry about clobbering flags when unwinding on failure. Regarding the unwind, the slot must be fully prepared before inserting it into the bindings, at which point the slot becomes reachable. I.e. waiting to update the slot in order to avoid the ugly unwind isn't an option. And as part of the unwind, explicitly nullify the relevant bindings, as xarray can store a subset of entries when populating a range.
Impacted products
Vendor Product Version
Linux Linux Affected: a7800aa80ea4d5356b8474c2302812e9d4926fa6 , < 2cfc1ccf67ffe96811c816d27d44128c5d5833ec (git)
Affected: a7800aa80ea4d5356b8474c2302812e9d4926fa6 , < 1706461eb1af814366b6d0ab413edd0876bd8033 (git)
Affected: a7800aa80ea4d5356b8474c2302812e9d4926fa6 , < 2fa83c615f8dbb240b262265e788b120b6384e7b (git)
Affected: a7800aa80ea4d5356b8474c2302812e9d4926fa6 , < e6ecb88711d93b9e014532f17d3d29b57e80932c (git)
Create a notification for this product.
Linux Linux Affected: 6.8
Unaffected: 0 , < 6.8 (semver)
Unaffected: 6.12.117 , ≤ 6.12.* (semver)
Unaffected: 6.18.63 , ≤ 6.18.* (semver)
Unaffected: 7.3.2 , ≤ 7.3.* (semver)
Unaffected: 7.4-rc1 , ≤ * (original_commit_for_fix)
Create a notification for this product.
Show details on NVD website

{
  "containers": {
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "virt/kvm/guest_memfd.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "2cfc1ccf67ffe96811c816d27d44128c5d5833ec",
              "status": "affected",
              "version": "a7800aa80ea4d5356b8474c2302812e9d4926fa6",
              "versionType": "git"
            },
            {
              "lessThan": "1706461eb1af814366b6d0ab413edd0876bd8033",
              "status": "affected",
              "version": "a7800aa80ea4d5356b8474c2302812e9d4926fa6",
              "versionType": "git"
            },
            {
              "lessThan": "2fa83c615f8dbb240b262265e788b120b6384e7b",
              "status": "affected",
              "version": "a7800aa80ea4d5356b8474c2302812e9d4926fa6",
              "versionType": "git"
            },
            {
              "lessThan": "e6ecb88711d93b9e014532f17d3d29b57e80932c",
              "status": "affected",
              "version": "a7800aa80ea4d5356b8474c2302812e9d4926fa6",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "virt/kvm/guest_memfd.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "6.8"
            },
            {
              "lessThan": "6.8",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.12.*",
              "status": "unaffected",
              "version": "6.12.117",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.18.*",
              "status": "unaffected",
              "version": "6.18.63",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "7.3.*",
              "status": "unaffected",
              "version": "7.3.2",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "7.4-rc1",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.12.117",
                  "versionStartIncluding": "6.8",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.18.63",
                  "versionStartIncluding": "6.8",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "7.3.2",
                  "versionStartIncluding": "6.8",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "7.4-rc1",
                  "versionStartIncluding": "6.8",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nKVM: guest_memfd: Gracefully handle xarray errors when binding a memslot\n\nIf inserting a memslot into a guest_memfd\u0027s bindings xarray fails,\npropagate the error back to the caller, i.e. fail memslot creation as well.\nSignalling success and continuing on with memslot creation results in\nuse-after-free, as the guest_memfd instance will remain reachable via the\nmemslot after the file is freed (kvm_gmem_release() won\u0027t nullify the file\npointer due to lack of a valid binding).\n\nOpportunistically WARN and reject binding if KVM_MEMSLOT_GMEM_ONLY is\nalready set, partly to guard against goofs elsewhere, but mostly so that\nKVM doesn\u0027t need to worry about clobbering flags when unwinding on failure.\n\nRegarding the unwind, the slot must be fully prepared before inserting it\ninto the bindings, at which point the slot becomes reachable.  I.e. waiting\nto update the slot in order to avoid the ugly unwind isn\u0027t an option.  And\nas part of the unwind, explicitly nullify the relevant bindings, as xarray\ncan store a subset of entries when populating a range."
        }
      ],
      "metrics": [
        {
          "cvssV3_1": {
            "baseScore": 7,
            "baseSeverity": "HIGH",
            "vectorString": "CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H",
            "version": "3.1"
          },
          "scenarios": [
            {
              "lang": "en",
              "value": "AV:L - kvm_vm_ioctl() handles KVM_SET_USER_MEMORY_REGION2 by calling kvm_set_memory_region(), which calls kvm_gmem_bind() with the local guest_memfd fd. xa_store_range() fails on an internal GFP_KERNEL allocation, not on a field taken from a remote protocol message.\nAC:H - kvm_gmem_bind() ignores xa_store_range() on f-\u003ebindings. That returns -EINVAL only for an internal entry or last \u003c first; a kmalloc\u0027d slot and the KVM_MEM_MAX_NR_PAGES-capped range produce neither, leaving -ENOMEM. The xarray is xa_init()\u0027d without XA_FLAGS_ACCOUNT and radix_tree_node is not SLAB_ACCOUNT, so this GFP_KERNEL allocation fails only after global reclaim and OOM give up, which the caller cannot force on demand.\nPR:L - KVM_CREATE_VM, KVM_CREATE_GUEST_MEMFD, and KVM_SET_USER_MEMORY_REGION2 are ordinary ioctls on /dev/kvm and the VM fd. kvm_dev_ioctl() and kvm_vm_ioctl() contain no capable() check, so a local user who can open /dev/kvm reaches kvm_gmem_bind() without CAP_SYS_ADMIN.\nUI:N - The attacker opens /dev/kvm, creates the VM and guest_memfd, and issues KVM_SET_USER_MEMORY_REGION2 itself. Closing that fd is what makes kvm_gmem_release() free the file while slot-\u003egmem.file still points at it. No other user action is required.\nS:U - The use-after-free is the host process that owns the VM fd later hitting kvm_gmem_unbind() or kvm_gmem_get_pfn() on its own dangling slot-\u003egmem.file. A guest cannot issue KVM_SET_USER_MEMORY_REGION2, so this is host privilege escalation, not a guest-to-host scope change.\nC:H - kvm_gmem_release() nullifies slot-\u003egmem.file only for entries present in f-\u003ebindings. With the store dropped, close() frees the struct file and the gmem_file while the memslot keeps the pointer. kvm_gmem_get_file() then file_ref_get()s that address and __kvm_gmem_get_pfn() reads private_data from whatever file the attacker recycled into the slot.\nI:H - kvm_free_memslot() calls kvm_gmem_unbind(), which loads the dangling file, takes filemap_invalidate_lock() on f_mapping, and xa_store_range()s NULL through file-\u003eprivate_data treated as a gmem_file. Those writes land on a recycled struct file the attacker can reclaim by opening files, so the use-after-free is a kernel write, not only a crash.\nA:H - If the freed struct file or gmem_file is still poisoned, kvm_gmem_unbind()\u0027s dereference of f_mapping and private_data oopses, including on the kvm_free_memslots() path when the VM fd is released. A guest fault through kvm_gmem_get_pfn() hits the same dangling pointer."
            }
          ]
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-11-22T11:08:31.154Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/2cfc1ccf67ffe96811c816d27d44128c5d5833ec"
        },
        {
          "url": "https://git.kernel.org/stable/c/1706461eb1af814366b6d0ab413edd0876bd8033"
        },
        {
          "url": "https://git.kernel.org/stable/c/2fa83c615f8dbb240b262265e788b120b6384e7b"
        },
        {
          "url": "https://git.kernel.org/stable/c/e6ecb88711d93b9e014532f17d3d29b57e80932c"
        }
      ],
      "title": "KVM: guest_memfd: Gracefully handle xarray errors when binding a memslot",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2026-99473",
    "datePublished": "2026-11-19T14:43:02.008Z",
    "dateReserved": "2026-09-25T10:25:14.417Z",
    "dateUpdated": "2026-11-22T11:08:31.154Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.2",
  "vulnerability-lookup:meta": {
    "epss": {
      "cve": "CVE-2026-99473",
      "date": "2026-11-22",
      "epss": "0.00168",
      "percentile": "0.06233"
    },
    "microsoft_vex": {
      "current_release_date": "2026-11-23T01:06:27.000Z",
      "cve": "CVE-2026-99473",
      "id": "msrc_CVE-2026-99473",
      "initial_release_date": "2026-11-20T01:10:41.000Z",
      "product_status:under_investigation": "1",
      "source": "Microsoft CSAF VEX",
      "status": "final",
      "title": "KVM: guest_memfd: Gracefully handle xarray errors when binding a memslot",
      "url": "https://msrc.microsoft.com/csaf/vex/2026/msrc_cve-2026-99473.json",
      "version": "2"
    },
    "nvd": {
      "cve": {
        "affected": [
          {
            "affectedData": [
              {
                "defaultStatus": "unaffected",
                "product": "Linux",
                "programFiles": [
                  "virt/kvm/guest_memfd.c"
                ],
                "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                "vendor": "Linux",
                "versions": [
                  {
                    "lessThan": "2cfc1ccf67ffe96811c816d27d44128c5d5833ec",
                    "status": "affected",
                    "version": "a7800aa80ea4d5356b8474c2302812e9d4926fa6",
                    "versionType": "git"
                  },
                  {
                    "lessThan": "1706461eb1af814366b6d0ab413edd0876bd8033",
                    "status": "affected",
                    "version": "a7800aa80ea4d5356b8474c2302812e9d4926fa6",
                    "versionType": "git"
                  },
                  {
                    "lessThan": "2fa83c615f8dbb240b262265e788b120b6384e7b",
                    "status": "affected",
                    "version": "a7800aa80ea4d5356b8474c2302812e9d4926fa6",
                    "versionType": "git"
                  },
                  {
                    "lessThan": "e6ecb88711d93b9e014532f17d3d29b57e80932c",
                    "status": "affected",
                    "version": "a7800aa80ea4d5356b8474c2302812e9d4926fa6",
                    "versionType": "git"
                  }
                ]
              },
              {
                "defaultStatus": "affected",
                "product": "Linux",
                "programFiles": [
                  "virt/kvm/guest_memfd.c"
                ],
                "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                "vendor": "Linux",
                "versions": [
                  {
                    "status": "affected",
                    "version": "6.8"
                  },
                  {
                    "lessThan": "6.8",
                    "status": "unaffected",
                    "version": "0",
                    "versionType": "semver"
                  },
                  {
                    "lessThanOrEqual": "6.12.*",
                    "status": "unaffected",
                    "version": "6.12.117",
                    "versionType": "semver"
                  },
                  {
                    "lessThanOrEqual": "6.18.*",
                    "status": "unaffected",
                    "version": "6.18.63",
                    "versionType": "semver"
                  },
                  {
                    "lessThanOrEqual": "7.3.*",
                    "status": "unaffected",
                    "version": "7.3.2",
                    "versionType": "semver"
                  },
                  {
                    "lessThanOrEqual": "*",
                    "status": "unaffected",
                    "version": "7.4-rc1",
                    "versionType": "original_commit_for_fix"
                  }
                ]
              }
            ],
            "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67"
          }
        ],
        "cveTags": [],
        "descriptions": [
          {
            "lang": "en",
            "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nKVM: guest_memfd: Gracefully handle xarray errors when binding a memslot\n\nIf inserting a memslot into a guest_memfd\u0027s bindings xarray fails,\npropagate the error back to the caller, i.e. fail memslot creation as well.\nSignalling success and continuing on with memslot creation results in\nuse-after-free, as the guest_memfd instance will remain reachable via the\nmemslot after the file is freed (kvm_gmem_release() won\u0027t nullify the file\npointer due to lack of a valid binding).\n\nOpportunistically WARN and reject binding if KVM_MEMSLOT_GMEM_ONLY is\nalready set, partly to guard against goofs elsewhere, but mostly so that\nKVM doesn\u0027t need to worry about clobbering flags when unwinding on failure.\n\nRegarding the unwind, the slot must be fully prepared before inserting it\ninto the bindings, at which point the slot becomes reachable.  I.e. waiting\nto update the slot in order to avoid the ugly unwind isn\u0027t an option.  And\nas part of the unwind, explicitly nullify the relevant bindings, as xarray\ncan store a subset of entries when populating a range."
          }
        ],
        "id": "CVE-2026-99473",
        "lastModified": "2026-11-22T11:16:53.457",
        "metrics": {
          "cvssMetricV31": [
            {
              "cvssData": {
                "attackComplexity": "HIGH",
                "attackVector": "LOCAL",
                "availabilityImpact": "HIGH",
                "baseScore": 7.0,
                "baseSeverity": "HIGH",
                "confidentialityImpact": "HIGH",
                "integrityImpact": "HIGH",
                "privilegesRequired": "LOW",
                "scope": "UNCHANGED",
                "userInteraction": "NONE",
                "vectorString": "CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H",
                "version": "3.1"
              },
              "exploitabilityScore": 1.0,
              "impactScore": 5.9,
              "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
              "type": "Secondary"
            }
          ]
        },
        "published": "2026-11-19T15:18:01.753",
        "references": [
          {
            "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
            "url": "https://git.kernel.org/stable/c/1706461eb1af814366b6d0ab413edd0876bd8033"
          },
          {
            "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
            "url": "https://git.kernel.org/stable/c/2cfc1ccf67ffe96811c816d27d44128c5d5833ec"
          },
          {
            "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
            "url": "https://git.kernel.org/stable/c/2fa83c615f8dbb240b262265e788b120b6384e7b"
          },
          {
            "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
            "url": "https://git.kernel.org/stable/c/e6ecb88711d93b9e014532f17d3d29b57e80932c"
          }
        ],
        "sourceIdentifier": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "vulnStatus": "Received"
      }
    },
    "redhat_vex": {
      "aggregate_severity": "Important",
      "current_release_date": "2026-11-22T11:31:12+00:00",
      "cve": "CVE-2026-99473",
      "id": "CVE-2026-99473",
      "initial_release_date": "2026-11-19T14:43:02.008000+00:00",
      "product_status:known_not_affected": "204",
      "source": "Red Hat CSAF VEX",
      "status": "final",
      "title": "kernel: kernel: KVM: Use-after-free via guest memory slot binding failure",
      "url": "https://security.access.redhat.com/data/csaf/v2/vex/2026/cve-2026-99473.json",
      "version": "3"
    }
  }
}



Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Forecast uses a logistic model when the trend is rising, or an exponential decay model when the trend is falling. Fitted via linearized least squares.

Sightings

Author Source Type Date Other

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or observed by the user.
  • Confirmed: The vulnerability has been validated from an analyst's perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
  • Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
  • Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
  • Not confirmed: The user expressed doubt about the validity of the vulnerability.
  • Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.

Loading…

Loading…

Loading…

Related by attack behaviour

Vulnerabilities whose description is nearest to this one in the vector space of the CIRCL/vulnerability-attack-technique-biencoder model. This is a similarity search over the bi-encoder space (plain cosine), not a classification, and it has no measured accuracy.


Loading…